|
-
Apr 2nd, 2006, 11:18 AM
#1
Thread Starter
Addicted Member
Print access database
how do i print a access database ???? without showing the program access if possible
thanks in advance RedAngel
-
Apr 2nd, 2006, 11:26 AM
#2
Re: Print access database
What do you want to print? Report, Form, etc. Are you doijng this from within Access VBA or from VB6?
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Apr 2nd, 2006, 11:31 AM
#3
-
Apr 2nd, 2006, 11:50 AM
#4
Thread Starter
Addicted Member
Re: Print access database
all feilds in the database from vb6
-
Apr 2nd, 2006, 11:59 AM
#5
Re: Print access database
Create a Report in Access and then just DoCmd.OpenReport passing the report name and the hidden viewstate.
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Apr 2nd, 2006, 12:31 PM
#6
-
Apr 2nd, 2006, 03:18 PM
#7
Re: Print access database
You can use ADOX for that purpose: set references to regulatar ADO and ADO Ext. 2.x for DDL and Security and run the following code.
NOTE: you will have to provide fully qualified connection string for your database:
VB Code:
Private Sub Command3_Click()
'============================
Dim tbl As ADOX.Table
Dim cat As ADOX.Catalog
Dim con As ADODB.Connection
Dim i%
On Error Resume Next
Screen.MousePointer = vbHourglass
Set con = New ADODB.Connection
con.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & App.Path & "\biblio.mdb;"
Set cat = New ADOX.Catalog
Set cat.ActiveConnection = con
For Each tbl In cat.Tables
Debug.Print String(24, "-")
Debug.Print tbl.Name
Debug.Print String(24, "-")
For i = 0 To tbl.Columns.Count - 1
Debug.Print tbl.Columns(i).Name
Next i
Debug.Print vbNewLine
Next
Set cat = Nothing
con.Close
Set con = Nothing
Screen.MousePointer = vbDefault
End Sub
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|