access report displayed in a visio window?

B

bernie_s

hi,

i have a visio diagram (visio professional 2003) that has shapes that are
controlled from an access database (access 2003). most of the data for the
database is imported into access from an sql backend via a brio query and
export.

the interaction between the visio diagram and the access database is driven
by vba code.

there are a couple of reports that the access database provides that i would
like to appear in the visio window, however i am having trouble achieving
this.

curently i can call the report from visio, with the access database active
using the following:

'code from visio module
'
Sub more_testing()

Dim MyAC As Access.Application 'AccessObject
Dim strsql As String

Set MyAC = GetObject("drive\blah\bms-testing.mdb")

MyAC.Run ("show_summary_report")

Set MyAC = Nothing ' Release reference to the database.

End Sub


'code from access module
'
Sub show_summary_report()

DoCmd.OpenReport "Summary Table", acViewPreview, "App Id", ,_
acWindowNormal

End Sub


i have not been able to find a way to include the access module code in the
visio code.

is this possible?

thanks

bernie
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top