• WSKlaus

    WSKlaus

    @wsklaus

    Viewing 2 replies - 16 through 17 (of 17 total)
    Author
    Replies
    • in reply to: Template from template loses code (Word 2000 SR1) #549909

      Fair enough, that’ll work. It’s just that this template will be shared with corporate users, that may have been (finally) trained to right-click and select “New”, or are selecting the template via Word’s File> New dialog, which includes the Workgroup Templates, where I store the template in question.

      Thanks for your reply.

      Klaus

    • in reply to: Unbound adp report problems (Access 2000 SR-1) #531352

      Charlotte,
      thanks for replying.

      For brevity, I didn’t include the mechanism for connecting to the SQL Server db in my post, but I use a global connection string, and a function, OpenConnection() As Boolean, that connects to the server when I open the adp as well as when I populate forms, combo boxes etc..

      Before executing any command on the server, I make sure I have a connection:

      fOK = OpenConnection()
      If not fOK then
      – reconnect
      else
      – here’s where I run the code you saw in my original post

      This works well for any forms (single and continuous), or to run any stored procedure, it just doesn’t work with my reports. If you want to, I can post some code, but I’m not sure what to include: just the code I use to open the report, or the modules to set up the connection?

      I also left a message on microsoft.public.access.adp.sqlserver, and Andy Baron replied that apparently you cannot use (unbound) reports in an unbound adp, or he wasn’t aware of a solution to my problem (“Access 2000 reports don’t have a recordset property the way forms do. In Access 2002, you can use a shaped recordset to create a report, but I haven’t tried it yet. In Access 2000, I think you’ll find that without connecting to SQL Server and setting a record source, you won’t get very far in building reports. You may want to look at 2002 if you need this, or use another tool for your reporting.”)

      The reason I keep my adp unbound is, it’s easier to keep the users away from the server objects.

      I was wondering, if there is a way to programmatically set up the connection to the server (i.e.,complete the steps in the File – Connection dialog using VBA which then should also display the server objects in the db window), run the report against a stored proc or view, then programmatically clear the connection dialog again. This way, I would have a bound adp just when opening the report, and an unbound adp using ADO for the remainder of the session.

      Any thoughts?

    Viewing 2 replies - 16 through 17 (of 17 total)