Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Impression d'un rapport Access
Message
 
À
Tous
Information générale
Forum:
Visual Basic
Catégorie:
Codage, syntaxe et commandes
Titre:
Impression d'un rapport Access
Divers
Thread ID:
00135165
Message ID:
00135165
Vues:
54
I have to print a report created in MS-Access 97 from a VB application.

I have tried the following code:

Private Sub cmdRapport_Click()
Dim objAccess As Access.Application

Set objAccess = New Access.Application

With objAccess
.OpenCurrentDatabase "C:\toto.mdb"
.DoCmd.OpenReport "Rapport1"
.Quit acQuitSaveNone
End With

Set objAccess = Nothing
End Sub

Now, I have my report printed BUT my database is protected by a password. When I execute the OpenCurrentDatabase method, a dialog box ask the password to the user.

How can I pass the password using this method OR how can I print a report from a database object?
Éric Moreau, MCPD, Visual Developer - Visual Basic MVP
Conseiller Principal / Senior Consultant
Moer inc.
http://www.emoreau.com
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform