|
-
Jun 28th, 2004, 09:14 AM
#1
Thread Starter
Lively Member
DataReport Master...Help.
Hi I tried this code to change my DataReport Paper Orientation..
Printer.PaperSize = vbPRPSLegal '10x14
Printer.Orientation = vbPRORLandscape 'Landscape
But it doesn't work.. Everytime I show the DataReport, it doesn't change..
I try to use even Common Dialog box but it doesn't work.. Any idea even an API code?
Kindly help me what code should I do?
Have a nice day.
Shailesh & Rajani
-
Jun 28th, 2004, 09:42 AM
#2
Fanatic Member
This only works with Service pack 4 and onwards ( definatley aone of the latter service pack) download the lattest service pack from microsoft thats service pack 6
Useful Links
.Net
#Develop, GhostDoc, CodeKeep , be.PINVOKE, Good Code Snippet Site
Krypton Toolkit, XPCC / XP Common Controls, QSS Windows Forms Components
VB.COM
VB.Classic Help File, MB Controls, MZTools, ADO Stored Procedure Generator add-in,
-
Jul 1st, 2004, 06:37 AM
#3
Thread Starter
Lively Member
VB6.0 Data Report Master Plz Help
I already have Service pack 5 installed on machine and it is not solving my problem.
Have a nice day.
Shailesh & Rajani
-
Jul 1st, 2004, 07:01 AM
#4
Fanatic Member
It's not the Printer object you need to look at but the report object itself.
VB Code:
Option Explicit
Public Con As New Connection
Public Rec As Recordset
Private Sub Command1_Click()
Set Rec = New Recordset
Con.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Program Files\Microsoft Visual Studio\VB98\BIBLIO.MDB;Persist Security Info=False"
Rec.Open "select * from Authors", Con
With DataReport1
Set .DataSource = Rec
.Orientation = rptOrientLandscape 'Set the report orientation not the printer
.Show
.PrintReport
End With
End Sub
Hope this helps
Useful Links
.Net
#Develop, GhostDoc, CodeKeep , be.PINVOKE, Good Code Snippet Site
Krypton Toolkit, XPCC / XP Common Controls, QSS Windows Forms Components
VB.COM
VB.Classic Help File, MB Controls, MZTools, ADO Stored Procedure Generator add-in,
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
|