Search results

  1. C

    Combo Box, Not In List event, Access 2010

    Now I am wondering, maybe I don't event need to save the record straight away? Maybe it is better to pass the The values "First Name" and "Last Name" I've entered from the combobox to the Text Fields "First Name" and "Last name" and only then press the save button to save record? The thing is...
  2. C

    Combo Box, Not In List event, Access 2010

    By the way can I use Queries instead of the table in the combo box RowSource? Because I assume it would be easier to save the two values(Last name and first name) If I would make the query which would contain "Patient Name" field with BOTH first and last name?
  3. C

    Combo Box, Not In List event, Access 2010

    Hello colleagues, I'm struggling with Combo Box and Not In List event. I want to be able to "add new record of First Name and Last Name if it is not in the list. Here is the picture of how my form looks: I have two tables: "Patients" and "Visit" - these are related as one to many(one patient...
  4. C

    Trim with space two values

    Im Sorry, everything works fine! Thank YOU!!!! I forgot to change Right to Mid Me.LastName = Left(OpenArgs, InStr(OpenArgs, " ") - 1) Me.FirstName = Mid(OpenArgs, InStr(OpenArgs, " ") + 1)
  5. C

    Trim with space two values

    Ok I managed to fix that: code now: Me.LastName = Left(OpenArgs, InStr(OpenArgs, " ") - 1) Me.FirstName = Right(OpenArgs, InStr(OpenArgs, " ") + 1) No error message, but Now Last Name representing ok no matter how long it will be. But First Name now ruins ups. Example: I type in...
  6. C

    Trim with space two values

    Hey, thank You for reply! When I use your code: Me.LastName = Left(OpenArgs, InStr(OpenArgs, " " - 1)) Me.FirstName = Mid(OpenArgs, InStr(OpenArgs, " " + 1)) I got Runtime error 13 Type Mismatch Any Ideas?
  7. C

    Trim with space two values

    Can Someone fix this code please? Highlighted in RED. Basically it just gets the values from the ComboBox.. The thing is, it "gets" the values of First And Last Name correctly only when the Name ANd Last Name are equal lenght for instance: if the name is John Elli, everything is OK. If the Last...
  8. C

    NotInList and 2 values ComboBox

    Ok, thank you for explanation:) Lets say I will tweak your code provided somehow. NotInListEvent works. Last problem(I hope so.. :) ): how to get back the values again to the ComboBox? For example I enter "John Elly" to the ComboBox. The notinlist event occurs, and dialog form pops up. I fill...
  9. C

    NotInList and 2 values ComboBox

    Sorry I confused you! The NotInList event is now working properly, but I can get back the record value on the combo box as you can see in the LAST PICTURE, after I click on Save And Close Button --------------------------------------- The code I changed If Not IsNull(OpenArgs) Then...
  10. C

    NotInList and 2 values ComboBox

    And here is the new code for my NotInList: Private Sub PatientLook_NotInList(NewData As String, Response As Integer) On Error GoTo Err_PatientLook_NotInList Dim intAnswer As Integer intAnswer = MsgBox("Would you like to add this value to the list?", vbYesNo, vbQuestion) If intAnswer =...
  11. C

    NotInList and 2 values ComboBox

    Ok it is actually very helpful, thank you for your attachment. But what is not clear At The Moment is : 1. The code provided by John - If Not IsNull(OpenArgs) Then DoCmd.GoToRecord acDataForm, "Patients", acNewRec Me.LastName = Left(OpenArgs, Len(OpenArgs) - (InStr(OpenArgs, "...
  12. C

    EVE-Online

    Very addictive, same as WOW lol :) But good, I like the atmosphere:)
  13. C

    Normal form

    Try use different host:)
  14. C

    NotInList and 2 values ComboBox

    Thank You ! One problem, I only see "tblAccounts" in your DB. Maybe because im using Access 2010 ? If its the case, could you please copy the code of not in list event ? It would be very helpful! I kind of near to finish the coding, but as Im quite new in it, I found alot of NotInList...
  15. C

    NotInList and 2 values ComboBox

    I know It is Sunday :) Anyway big Sorry for my impatience, I just need to finish somehow by today, so it is a big headache at the moment if u know what I mean..
  16. C

    NotInList and 2 values ComboBox

    Who can answer my question ?
  17. C

    NotInList and 2 values ComboBox

    Ok than You very much! It kind of worked! Now I have codes NotInList: Private Sub PatientLook_NotInList(NewData As String, Response As Integer) On Error GoTo Err_PatientLook_NotInList Dim intAnswer As Integer Dim strsql Dim NewFirst As String Dim NewLast As String Dim SpacePosition As...
  18. C

    NotInList and 2 values ComboBox

    Ohh crap...Im using 2010, and unfortunately I cannot save compatible to older versons :( Ok here is a brief explanation on hows everything arranged: Basically There are two Tables - one Patients and other PatientInfo. There are also two forms: Patients and PatientInfo. Tables Patients and...
  19. C

    NotInList and 2 values ComboBox

    Thanks for answer again! Yeah I just read about OpenArgs and got some idea If You have a few seconds could You please look at my DB I attached. There are 1 combobox which have two values FirstName and LastName Im abit confused where and how to separate this String of value ? There is a space...
  20. C

    NotInList and 2 values ComboBox

    Thank You very much for your reply! Ok, I looked at yours code but it is not very clear for me as Im quite new in MS Access coding. So what I did now in trying to solve my problem was: I put this code on "On Load" event of Patients form: Private Sub Form_Load() Me!FirstName =...
Back
Top Bottom