Recent content by papic1972

  1. P

    structuring code

    Hi all, I am attempting to implement Twilio SMS into my Access 2013 application. I tried using the code below and I cannot get it to work at all. I've uncommented the Response line to see what is going on however I keep getting a compile error: Variable not declared So, I've tried inserting...
  2. P

    The OpenReport action was canceled

    Awesome stuff pbaldy, thanks heaps!
  3. P

    The OpenReport action was canceled

    Hi All, I use the following code in the On No Data event of a report: Private Sub Report_NoData(Cancel As Integer) MsgBox "No data exists for the date range entered.", vbInformation, "No Data Alert" Cancel = True End Sub This works fine to cancel the opening of the report however Ms...
  4. P

    Generate and send by email individual reports based on a query

    Thanks for that. I ended up re-writing the SQL query, it all works now....I just hope nothing goes wrong down the track.
  5. P

    Generate and send by email individual reports based on a query

    Yes, that is right. But no it didn't happen in the previous versions, that's why this has got me stumped. I tested the same code on an Access 2013 Frontend with Outlook 2003 and I don't get this error. I will deconstruct the query and rewrite it, maybe something got corrupted in the SQL. I'll...
  6. P

    Generate and send by email individual reports based on a query

    Good morning all, Office 2013 is driving me bananas!!! The following code worked perfectly in Access 2013 and Outlook 2003. I had to upgrade all of the workstations to Office 2013 yesterday & now I cannot get my code to work. The code halts at the red highlighted section below and I receive the...
  7. P

    Generate and send by email individual reports based on a query

    pbaldy, you provided me with some inspirational thinking and I can't thank you enough!!! :) I changed the strFilterEmail line from "*.pdf" to Lrs!OrderID & ".pdf" and the correct attachments now attach to each email. My full working for anyone else out there is: Dim strSql Dim db As Database...
  8. P

    Generate and send by email individual reports based on a query

    Oh ok, thanks for letting me know..... I just don't understand why I can't get it working for me, I'm using Exchange 2010. My attachment path is coded as .Attachments.Add strpath & strFile so isn't this essentially the same path as the saved path?
  9. P

    Generate and send by email individual reports based on a query

    I've altered my code now slightly. The recordset has 3 records....the code loops through and produces 3 emails to 3 separate email addresses HOWEVER it attaches the same PDF to all 3 emails. I cannot figure out why! Can anyone help? Dim strSql Dim db As Database Set db = CurrentDb() Dim rs As...
  10. P

    Generate and send by email individual reports based on a query

    OK.....I've now ditched the CDO method (because it just doesn't seem to work for me!) & now I'm trying something different (using Outlook). I've got the following code: Dim strSql Dim db As Database Set db = CurrentDb() Dim rs As Recordset Dim Lrs As DAO.Recordset Dim Outlook Dim rng Dim...
  11. P

    Generate and send by email individual reports based on a query

    Hi all, Can anyone verify if they have managed to successfully use the CDO method to send emails from Access using Exchange 2010 & Outlook 2010?
  12. P

    Generate and send by email individual reports based on a query

    No luck with this one!! I've tried the server name, the IP address.....the code keeps halting at .Send Is there anything else that I would need to check?
  13. P

    Generate and send by email individual reports based on a query

    OK, I've just tried to test this on a network with Exchange and I'm getting the same error: The SendUsing configuration is invalid. This is the configuration: Set iMsg = CreateObject("CDO.Message") Set iconf = CreateObject("CDO.Configuration") Set flds = iconf.Fields schema =...
  14. P

    Generate and send by email individual reports based on a query

    Haha nice one!! Thank you!!!
  15. P

    Generate and send by email individual reports based on a query

    Ok cool! Thanks soooooo much that worked!! As RevisionNo is text I wrote the code this way: DoCmd.OpenReport strRptName, acViewPreview, , "[OrderID]=" & ![OrderID] & "And" & "[RevisionNo]='" & ![RevisionNo] & "'"
Back
Top Bottom