Skills | Crystal Report
A friend in Mail asked, by the way.
vb+ Crystal Report 9, this is still very simple, with events
Private Sub crviewer91_nextpagebuttonclicked (Usedefault as Boolean)
Call MsgBox ("change page back")
End Sub
Private Sub crviewer91_lastpagebuttonclicked (Usedefault as Boolean)
Call MsgBox ("last Page")
End Sub
Private Sub crviewer91_firstpagebuttonclicked (Usedefault as Boolean)
Call MsgBox ("first page")
End Sub
Private Sub crviewer91_prevpagebuttonclicked (Usedefault as Boolean)
Call MsgBox ("forward one page")
End Sub
Vs.net2003, as if there were no direct events,
But to make the most of what you can get,
Define two global variables first
Public Lastpagenum as Int16 ' previous page number
Public nowpagenum as Int16 ' page number of current page
Get page change events using the following event tips
Private Sub crystalreportviewer1_navigate (ByVal source as Object, ByVal e As CrystalDecisions.Windows.Forms.NavigateEventArgs) Handles Crystalreportviewer1.navigate
' Get the current page number
Nowpagenum = Crystalreportviewer1.getcurrentpagenumber
' If this is the first load, exit
If nowpagenum =-1 Then
Exit Sub
End If
' If it's a page change
If lastpagenum <> nowpagenum Then
Call MsgBox ("page changed")
End If
' Replace the value of the variable
Lastpagenum = Nowpagenum
End Sub
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service