Search results

  1. Z

    Creating Word Doc from Relational Recordsets using VBA

    Thanks Arnel, you are right they are referred to as child tables, this I confirmed with the following code: Set tParent = objWordDoc.Tables(1) Set tDiscussions = tParent.Tables(1) Set tTasks = tParent.Tables(2) With tDiscussions.Borders .InsideLineStyle =...
  2. Z

    Creating Word Doc from Relational Recordsets using VBA

    How do I do that? I tried For Each tbl In objWordDoc.Tables Debug.Print tbl.Id Debug.Print tbl.Title For Each tblChild In tbl Debug.Print tblChild.Id Debug.Print tblChild.Title Next Next But that came back with object doesn't...
  3. Z

    Is the Me. syntax required in form vba when referring to controls?

    I prefer to use me for all the reasons above + what I always do is use mixed case in object names e.g. txtDiscussions, then when I am coding I always enter me.txtdiscussions and let intellisense capitalise it for me. If I have a bad day and type me.textdiscussions or me.txtdiscussion I...
  4. Z

    Creating Word Doc from Relational Recordsets using VBA

    I wish to create a word document containing field values for a parent recordset and child recordsets. I have created a word template that contains a table to control layout. In each cell I have created a bookmark to insert the recordset values. This works fine for all parent recordset fields...
  5. Z

    Invalid Use of Null Error when checking for Nulls with IsNull

    thanks for all the suggestions, will do some experimenting
  6. Z

    Invalid Use of Null Error when checking for Nulls with IsNull

    In truth, I don't know as I personally have never been able to recreate the error (which is why I am finding it hard to get to the bottom of), but it does happen for users because my error trapper routine sends me an email when a user gets an error. Your suggestion that Access can throw...
  7. Z

    Invalid Use of Null Error when checking for Nulls with IsNull

    Thanks for the tip to check for both empty strings and nulls, will give that a try. Generally I add option explicit at the top of each module, however I took the opportunity to check out all modules and on 3 out of 19 I had forgotten to. When I compiled it there was indeed one compile error...
  8. Z

    Invalid Use of Null Error when checking for Nulls with IsNull

    I am using the IsNull function to prevent passing Null values to another function, but the line with the IsNull check is itself throwing an Invalid Use of Null Error. I am a little confused and would appreciate any insight into what the problem may be. The Error is returning at line 20. Private...
  9. Z

    Controlling Unauthorized Distribution of Database

    You can make it hard for people. For example: Make FE/BE as someone has already suggested Make BE MS SQL if possible Make .accde One thing I do on my databases is have a table in BE SQL with a version number and a hard coded version number in the FE, if the FE version number < BE. It closes...
  10. Z

    Problem running passthrough recursive query as QDF in VBA

    Actually I think we were both right. I was actually creating passthrough queries in VBA, but because the two lines were in wrong order Access could not know that and was in fact trying to create an Access query with unrecogonisible SQL.
  11. Z

    Problem running passthrough recursive query as QDF in VBA

    SOLVED! I realised when I copied all the code I had my qdf.sql and qdf.connect the wrong way around. Thank you for all your help.
  12. Z

    Problem running passthrough recursive query as QDF in VBA

    That is my bad for not showing all the code I was trying to cut down on space by stopping at the error. The full code is: Dim db As Database Dim qdf As QueryDef Dim rst As Recordset Dim stServer As String Dim stDatabase As String Dim strServer As String: strServer =...
  13. Z

    Problem running passthrough recursive query as QDF in VBA

    I confess to being confused. I thought if I create a query then from design tab select passthrough, I then create the connection string to the SQL server, then write the query in TSQL as opposed to ACE/JET SQL and it appeared with a world globe (like shown below) and it ran OK I had created a...
  14. Z

    Problem running passthrough recursive query as QDF in VBA

    It works fine when I write it as a passthough query in Navigator so I would have expected it to work fine in VBA also:
  15. Z

    Problem running passthrough recursive query as QDF in VBA

    I have a SQL recursive query (below), which runs fine on SQL server and also runs fine when I create a QDF in in MS Access navigation window. But when I try to create it in VBA I get an error "Invalid SQL statement; expected 'DELETE', 'INSERT', 'PROCEDURE', 'SELECT', or 'UPDATE'." The query...
  16. Z

    Solved How to add a checkbox on a Continuous Form

    OK thanks, that is the one I didn't download and look at, so I will do so now.
  17. Z

    Solved How to add a checkbox on a Continuous Form

    Thank you for that arnelgp it provides good ideas for the future. One observation though, when I check number 13 it also checks 3 number 14 it also checks 4 etc. So four end up being highlighted, but when I filter it only filters for 13 & 14.
  18. Z

    Error -2147467259 Outlook doesn't recognize one or more names

    The user is on the same version of Access and Outlook that they have previously been on and previously it has worked. The database throughout the company generally runs on the latest version of ms Access Runtime.
  19. Z

    Error -2147467259 Outlook doesn't recognize one or more names

    Thank you for that, I will investigate that, the last of the three I can rule out but not the other two. How did you find that! I did quite a few googles and got nowhere!
  20. Z

    Error -2147467259 Outlook doesn't recognize one or more names

    I am not asking for debugging the database and function has been working fine for over 4 years. Just keen to know if anyone has experienced this error and can explain what causes it.
Back
Top Bottom