Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Printing Reports
Message
Information générale
Forum:
Visual Basic
Catégorie:
Autre
Divers
Thread ID:
00465270
Message ID:
00466340
Vues:
10
>Thanks, Guy. I decided to use Crystal that same day since I had some experience with it in the VFP world (deadlines are a wonderful thing), but your answer intrigued me because I would really have preferred Access reports so the users could modify them. I am going to save your message, and if you could find the code for #3, that would be great. (That VB help file isn't very helpful--I couldn't find how to print a report from anywhere except the DataReport object, and even that was sketchy.)


This is the exact code for #3:
Const dbPathName = "c:\database.mdb"
Const strPassword = "PASSWORD"
Dim Acc As Object, db As Object

Set Acc = CreateObject("Access.Application")
Set db = Acc.Application.DBEngine.Workspaces(0).OpenDatabase(dbPathName, 0, False, ";pwd=" & strPassword)
Acc.OpenCurrentDatabase dbPathName, False
Set db = Nothing
Acc.DoCmd.OpenReport "ReportName", acPreview
Set Acc = Nothing
Éric Moreau, MCPD, Visual Developer - Visual Basic MVP
Conseiller Principal / Senior Consultant
Moer inc.
http://www.emoreau.com
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform