Recent content by Momma

  1. M

    Solved Invalid use of Null

    Thank you all for your suggestions. I certainly learned a few more things. I've decided to go with Cheekybuddha's suggestion and it worked as expected.
  2. M

    Solved Invalid use of Null

    Hi everyone! I have a form which I use to allocate the puppies we have to a certain buyer. At the bottom I show the invoice, which is created in the after update of the CurrentOwner(cboBuyer) combobox. The InvoiceID is linked to the OwnerID and also have a field for the DogID which is stored in...
  3. M

    Solved Object variable or With block variable not set Error

    Sorry for the late reply. I end up using your 2nd suggestion and it worked. The first one gives a run-time error, although it compiled. Dim rs As DAO.Recordset Dim db As DAO.Database Set db = CurrentDb Set rs = db.OpenRecordset("SELECT...
  4. M

    Solved Object variable or With block variable not set Error

    Sorry, I declare it as follows: Dim Filename1 As String Filename1 = "SaleGuarantee-" & Contact & ".pdf" Dim Contact As String Contact = Forms!frmContactgrouplistbox!ContactList.Column(2, i) Dim rs As DAO.Recordset Set rs = db.OpenRecordset("SELECT Count([pkFilename])...
  5. M

    Solved Object variable or With block variable not set Error

    I get an "Object variable or With block not set" error on the following code. I did a Debug Compile and it compiled without any errors. What could be the problem? Dim rs As DAO.Recordset Set rs = db.OpenRecordset("SELECT Count([pkFilename]) AS RecCount FROM TblDocument...
  6. M

    Solved Openargs value in select statement

    Thank you, Gasman!
  7. M

    Solved Openargs value in select statement

    Thanks for your reply, Gasman. Could you explain how to use TempVar(), please?
  8. M

    Solved Openargs value in select statement

    Thank you for your reply ebs17. I'm getting an error on the Select Statement. Not sure how to correct it? Dim sSQL As String If Not IsNull(Me.OpenArgs) Then sSQL = "SELECT qryDogs3.DogID, qryDogs3.[Puppy Name], qryDogs3.BirthDate, qryDogs3.Mother, qryDogs3.PuppyNumber, " _...
  9. M

    Solved Openargs value in select statement

    Hi everyone I want to open a form a subform based on a value assigned to openargs. The new form have a listbox with a select statement to filter the records based on the openargs value. The field value to pass is BirthDdate. SELECT qryDogs3.DogID, qryDogs3.[Puppy Name], qryDogs3.BirthDate...
  10. M

    Hyperlink in Email

    Hi there I'm including a hyperlink in an email. How can I get it to show as a hyperlink once the email is generated? Thank you in advance! strBody = "Dear " & Forms!frmContactEmails!ContactList.Column(1, i) & "<br><br>" _ & "Please follow the link below" & "<br><br>" _ &...
  11. M

    Solved Dlookup null value

    Your plan worked, Josef. Thank you so much!
  12. M

    Solved Dlookup null value

    I'm sorry, the zero at the end should be CurrentDogID, but my syntex is wrong. The invoice should have both the CurrentContactID and the CurrentDogID. There could be another invoice for the same ContactID with a different Dogid. CurrentInvoiceID = DLookup("InvoiceID", "tblInvoices"...
  13. M

    Solved Dlookup null value

    I'm still getting a Type Mismatch on the last line.
  14. M

    Solved Dlookup null value

    Hi there I have a Dlookup to get the value of the CurrentInvoiceID but it returns with a Type Mismatch error. All the fields are numeric and CurrentInvoiceID and CurrentContactID have been declared as long. I also need to add NZ() for null values. Any help is highly appreciated. Thanks...
  15. M

    Solved Runtime Error with CurrentDB.Execute Update

    It is exactly that, Arnelgp. Thank you for your help!
Top Bottom