Search results

  1. E

    Problem with an IF Then Else in VBA

    the form with the issue is frmPatientNumberDialogBox - enter NHS number ie 10 digits and it works fine but not for the PatientNumber
  2. E

    Problem with an IF Then Else in VBA

    Front and back end attached Cheers
  3. E

    Problem with an IF Then Else in VBA

    That returned: Text27 isaw1907and the length of text 27 is6 in the immediate pane which seems correct although the correct record doesnt open just a blank record...
  4. E

    Problem with an IF Then Else in VBA

    Yes both are text fields PatientNumber in a six digit format could have 0 as its first digit but all other formats will not start with 0 and in my test version no numbers start with 0. NHSnumber is also a text field and will never start with 0 but will always be 10 digits long. Its set as text...
  5. E

    Problem with an IF Then Else in VBA

    it is possible for there to be a preceding zero in 6 digit numbers but all that is there in the test version is what Ive just posted in reply to CJ. Spaces in the numbers are not allowed
  6. E

    Problem with an IF Then Else in VBA

    Hi CJ thanks for your reply. The numbers are there in the table: PatientNumber 4380 4994 5004 506782 974633 AT4437 AW1907 AX1983 GK4088 the variants in length and construction (ie numeric/alphanumeric) being outside my control. The Table field is a text field of standard 50 character length...
  7. E

    Problem with an IF Then Else in VBA

    I have some code for a button on click event to open a form and select the record which corresponds to a value in an unbound text box. The code is: Private Sub Command25_Click() On Error GoTo Err_Command25_Click Dim stDocName As String Dim stLinkCriteria As String stDocName =...
  8. E

    Alter start position of popup form

    I have a number of forms where there are memo fields containing several paragraphs of text. I have set them up so that the on-update event triggers the MSOffice spellcheck box/dialog to open so the text can be corrected. All works fine but the box/dialog always opens in the middle of the...
  9. E

    wild card search in VBA

    Perfect works a treat as ever I cant see why I didn't think this through doh. I am most grateful.:)
  10. E

    wild card search in VBA

    Dear All Im confused again and need advice. I have a text box with vba in the on update event to populate a list box. The code is as follows: Private Sub TextSurname_AfterUpdate() If IsNumeric(Me.TextSurname) Then ListPts.RowSource = "Select [tbl-patient details].[Patient...
  11. E

    Alter position of Spellcheck box when it loads

    I have a number of forms where there are memo fields containing several paragraphs of text. I have set them up so that the on-update event triggers the MSOffice spellcheck box/dialog to open so the text can be corrected. All works fine but the box/dialog always opens in the middle of the...
  12. E

    Disable button until field fillled

    Thanks for your help have just tried a Bob Larson fix from another thread and it has sorted the problem: Me.[opening form pt details].Enabled = (Len(Me.TextSurname & "") <> 0) Obviously just didnt look hard enough and engage brain thoroughly ..... All the best for the New Year Eric
  13. E

    Disable button until field fillled

    I have a tab control on an unbound form and one of the tabs has a text box which populates a list box on the same tab with the patients having the surname I have typed in the text box. On this same tab I have a button which will open a form to enter a new patient. I want to disable this button...
  14. E

    Disable button until field fillled

    Thanks for the response The controls are on a tab control sitting on an unbound form with several of the tabs having subforms displaying various things. Putting the test code in onload/open/current of the unbound main form doesnt solve the problem and there doesnt seem to be an obvious event...
  15. E

    Disable button until field fillled

    Seasons Greetings All I have a minor niggle I am struggling to iron out. We have a database recording patient records and I am trying to stop people including me....!!! entering new records when the record already exists in the database.....it seems it is easily done after a hard day at the...
  16. E

    Right click popup menu

    Dear All Have solve problem - my subform container reference was incorrect ........ Doh
  17. E

    Right click popup menu

    Dear All I have a continuous form and have set up a right click popup menu on the record number control to allow me to print from a list of reports which works fine - it was set up using the Tools/Customize method. The reports are based on queries which ask for the parameter record_number. I...
  18. E

    Positioning a subform when visible

    Dear All Not sure if there is a solution to this but here go's I have two subforms on a main form linked by parent/child. The first subform is a table view listing records. The second subform is not visible until a control on the first subform is clicked whereupon it becomes visible showing...
  19. E

    Reference on subform from another

    Hi Doh failure to engage brain - you are correct I missed something Works great thank you both Cheers Eric
  20. E

    Reference on subform from another

    Hi I have this already but it only references a subform within a subform whereas what I am trying to do is find a way of referencing two subforms which both sit on a main form side by side. or have I missed something on what you posted? Cheers Eric
Back
Top Bottom