Search results

  1. A

    Solved Referring to a control on a subform from the parent form.

    So it turns out I'm an absolute numpty! After deleting the checklist subform and setting it up again and it still not working, I figured the issue could be to do with the parent form and it was. Allow Edits was set to 'No' on the parent form!! Changed it to 'Yes' and it works fine! I've no...
  2. A

    Solved Referring to a control on a subform from the parent form.

    There is no error, even when I disable error handling, the checkbox control in the subform just doesn't enable like it should. The subform control wasn't copied either as it's a separate checklist altogether with a separate table and subform and I have already checked that the name is correct...
  3. A

    Solved Referring to a control on a subform from the parent form.

    Hoping someone can help. I have a number of checklists in my database which I have built using the fab tutorials from Nifty Access. All my forms have the fields disabled until the user edits this record via the click of a command button. I've included this to prevent unintentional editing and...
  4. A

    Solved Run time error 31519 when trying to import CSV file

    Thanks @ebs17 It works perfectly since I added in the additional comma to represent the specification name! :)
  5. A

    Solved Run time error 31519 when trying to import CSV file

    Hi All, I am trying to add the facility for my users to import a CSV file via a button on a form. The code in the on click event of the button is: DoCmd.TransferText acImportDelim, "ImportTempT", _ "S:\IT\1 - Testing\CSVTestTwo.csv", True But I keep getting the run time error saying...
  6. A

    Query with multiple inner joins

    Thanks for your help. I did get it to save making the changes but then I had other criteria to add in and I couldn't get it to work. However, I've managed to figure out how to get the results I need using design view in Access. :)
  7. A

    Query with multiple inner joins

    Hi All, I have a mailing list form in my database were I need to filter organisations by 4 geographical areas. i.e. UK region, local authority, constituency and combined authority. Sometimes I will need to search for and send emails to all organisations for a certain region or local authority...
  8. A

    Solved Problems with code execution following email

    Thanks @Gasman and @adhoustonj that's much clearer and will help loads whilst I'm still testing after my code review. :)
  9. A

    Solved Problems with code execution following email

    It works!!!! Thanks so much! :D
  10. A

    Solved Problems with code execution following email

    I can see why it needs an exit sub as it still sends the authorisation email if the date is left blank. However, when I leave in the exit sub in both sections of code, it stops the rest of the code running even if the date is completed. Everything works perfectly without the Exit Sub except...
  11. A

    Solved Problems with code execution following email

    Thanks for the suggestion, I have managed to get it working after adding the variable. There was an error in there too so updating it has helped. I just wanted to ask about debugging too as I've never managed to get it to work. Does this only work with modules or should it work with the code...
  12. A

    Solved Problems with code execution following email

    Thanks all for your help and suggestions. So I have the SaveFirstAuth_Click() sub working now. It turns out that I used 'msg' twice for different variables. This was included in the error handling which is maybe why I think the error handling didn't trigger. I also updated this: If...
  13. A

    Solved Problems with code execution following email

    I have removed the .send from this code but it still doesn't work and still no error message :confused:
  14. A

    Solved Problems with code execution following email

    Yep, there's no error message at all with the error handling. I have been trying to make an error message pop up so it would help me debug but there's nothing! Thanks for the feedback too, that's so much cleaner. Interestingly, I have some similar code for the next part of the process which...
  15. A

    Solved Problems with code execution following email

    Hi I'm having problems with a section of code which previously worked but I can't see why it isn't fully executing now. Here's the code: Private Sub SaveFirstAuth_Click() Dim OrgURN As String Dim GrantURN As String On Error GoTo ErrorHandler OrgURN = "Org URN " & Me.OrganisationURN GrantURN...
  16. A

    Solved How to use ME in a public function

    Thanks for this. I can see the point about adding a With block to the code to close forms and that it doesn't really make sense to do that. @MajP thanks for the example of the good With block, there are loads of examples such as this that I can update and make it much more readable. :)...
  17. A

    Solved How to use ME in a public function

    Hi David Thanks for this, it works great! I note the comments about using a With block. How would I do this in this instance? There's definitely other areas in the code that I could use a With block rather than repeating lines of code. :)
  18. A

    Solved How to use ME in a public function

    Hi I have the following code in most of my forms when exiting. Private Sub ExitComms_Click() On Error GoTo ErrorHandler Dim ctl As Control 'If record is changed do you want to save changes If Me.Dirty Then If MsgBox("Do you want to save changes?", vbYesNo + vbQuestion, _...
  19. A

    Solved Auto email error needed if attachment file doesn't exist or is named incorrectly

    Hi, Hoping someone can help. I have the following code in my database which, when a payment is authorised, will send an automatic email to our finance team to say the payment needs to be made and will also attach the bank statement from a file directory. However, if the file doesn't exist/is...
Back
Top Bottom