Click here to Skip to main content
15,890,579 members
Home / Discussions / Visual Basic
   

Visual Basic

 
AnswerRe: how do i remove "database login" from my crystal report?? Pin
Wendelius8-Nov-08 3:50
mentorWendelius8-Nov-08 3:50 
GeneralRe: how do i remove "database login" from my crystal report?? Pin
graced888-Nov-08 16:30
graced888-Nov-08 16:30 
GeneralRe: how do i remove "database login" from my crystal report?? Pin
Wendelius8-Nov-08 21:12
mentorWendelius8-Nov-08 21:12 
GeneralRe: how do i remove "database login" from my crystal report?? Pin
graced889-Nov-08 15:07
graced889-Nov-08 15:07 
GeneralRe: how do i remove "database login" from my crystal report?? Pin
Wendelius9-Nov-08 18:09
mentorWendelius9-Nov-08 18:09 
QuestionSave PrintDocument to image Pin
Richard Sauceda7-Nov-08 11:45
Richard Sauceda7-Nov-08 11:45 
AnswerRe: Save PrintDocument to image Pin
Dave Kreskowiak7-Nov-08 15:52
mveDave Kreskowiak7-Nov-08 15:52 
AnswerRe: Save PrintDocument to image Pin
Richard Sauceda12-Nov-08 4:35
Richard Sauceda12-Nov-08 4:35 
I found that the code I tried to use earlier for my project didn't work for me (link). So, I found code that did what I needed, and that I could understand. This is the code that I used.

<pre>
Option Strict Off
Public Class Form1

Dim pdoc As New Printing.PrintDocument()
Friend WithEvents ppc As New Printing.PreviewPrintController()


Private Sub Button1_Click(ByVal sender As System.Object, _
ByVal e As System.EventArgs) Handles Button1.Click

pdoc.PrintController = ppc

AddHandler pdoc.PrintPage, AddressOf pdoc_PrintPage
AddHandler pdoc.EndPrint, AddressOf xxx

' This shows nothing on the screen. It ends
' up calling the 'xxx' sub which saves the
' printpage images to files

pdoc.Print()

' This will show a regular print preview

pdoc.PrintController = New Printing.StandardPrintController
Dim ppd As New PrintPreviewDialog
ppd.Document = pdoc
ppd.ShowDialog()

End Sub

Private Sub pdoc_PrintPage(ByVal sender As Object, _
ByVal e As Printing.PrintPageEventArgs)
Static z As Integer = 0
If z = 0 Then
e.Graphics.DrawString("Page pg1", New Font("Arial", 48), _
Brushes.Black, New PointF(100, 100))
z += 1
e.HasMorePages = True
ElseIf z = 1 Then
e.Graphics.DrawString("Page pg2", New Font("Arial", 48), _
Brushes.Black, New PointF(100, 100))
z += 1
e.HasMorePages = True
Else
e.Graphics.DrawString("Page pg3", New Font("Arial", 48), _
Brushes.Black, New PointF(100, 100))
e.HasMorePages = False
z = 0
End If

End Sub

Private Sub xxx(ByVal sender As Object, _
ByVal e As System.Drawing.Printing.PrintEventArgs)

Dim ppi() As Printing.PreviewPageInfo = ppc.GetPreviewPageInfo()
For x As Integer = 0 To ppi.Length - 1
ppi(x).Image.Save("c:\look" &amp; x.ToString &amp; ".jpg")
Next

End Sub

End Class
</pre>

Hope this comes in handy for someone else Cool | :cool:
Question[VB.NET] - need advice on a data container Pin
Member 38675217-Nov-08 6:11
Member 38675217-Nov-08 6:11 
AnswerRe: [VB.NET] - need advice on a data container Pin
Dave Kreskowiak7-Nov-08 7:17
mveDave Kreskowiak7-Nov-08 7:17 
QuestionI need a pdf SDK Pin
Cory Kimble7-Nov-08 6:09
Cory Kimble7-Nov-08 6:09 
AnswerRe: I need a pdf SDK Pin
Dave Kreskowiak7-Nov-08 7:11
mveDave Kreskowiak7-Nov-08 7:11 
AnswerRe: I need a pdf SDK Pin
Wendelius7-Nov-08 7:14
mentorWendelius7-Nov-08 7:14 
QuestionAdd references dynamically Pin
thesum7-Nov-08 5:09
thesum7-Nov-08 5:09 
AnswerRe: Add references dynamically Pin
Dave Kreskowiak7-Nov-08 7:09
mveDave Kreskowiak7-Nov-08 7:09 
QuestionFind time Discrepancy Pin
Sinchan Nikam7-Nov-08 3:19
Sinchan Nikam7-Nov-08 3:19 
AnswerRe: Find time Discrepancy Pin
Dave Kreskowiak7-Nov-08 4:01
mveDave Kreskowiak7-Nov-08 4:01 
AnswerRe: Find time Discrepancy Pin
jzonthemtn7-Nov-08 6:29
jzonthemtn7-Nov-08 6:29 
AnswerRe: Find time Discrepancy Pin
sph3rex8-Nov-08 4:51
sph3rex8-Nov-08 4:51 
QuestionConnecting Pin
Michelle Shoniwa7-Nov-08 0:55
Michelle Shoniwa7-Nov-08 0:55 
AnswerRe: Connecting Pin
Vimalsoft(Pty) Ltd7-Nov-08 1:23
professionalVimalsoft(Pty) Ltd7-Nov-08 1:23 
AnswerRe: Connecting Pin
Ashfield7-Nov-08 1:24
Ashfield7-Nov-08 1:24 
QuestionHow can I use a VB.NET function in a crystal reports "Details" section? Pin
MAP Tiger6-Nov-08 23:13
MAP Tiger6-Nov-08 23:13 
AnswerRe: How can I use a VB.NET function in a crystal reports "Details" section? Pin
Rupesh Kumar Swami7-Nov-08 1:16
Rupesh Kumar Swami7-Nov-08 1:16 
AnswerRe: How can I use a VB.NET function in a crystal reports "Details" section? Pin
Nanda_MR7-Nov-08 22:21
Nanda_MR7-Nov-08 22:21 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.