|
-
Feb 9th, 2010, 03:58 AM
#1
Thread Starter
New Member
Crystal - Report - MS Access
Dear One,
I am using MS access and Crystal report in application. I have stored image in mm DB as path,
The DS as follows,
Regno - Text
Name - Text
Gender - Text
M1 - number
M2- Number
.
.
.
image path
Now, I have designed a mark sheet in crystal report, I am keeping it as marksheet.rpt
What is the procedure to load the image in the same report in the corner of the mark sheet for all the students?
Thank you
-
Feb 9th, 2010, 07:23 AM
#2
Re: Crystal - Report - MS Access
-
Feb 9th, 2010, 04:00 PM
#3
Re: Crystal - Report - MS Access
The way I do it, is:
The rpt is inside the project integrating Crystal Reports (is not an external .rpt file)
Use RDC
And in the desired Report Section's Format event, use code like the next :
(In this example I'm changeing a picture in every page header)
Code:
Private Sub PageHeaderSection1_Format(ByVal pFormattingInfo As Object)
Dim Pic1 As OLEObject
Dim I As Integer
For I = 1 To PageHeaderSection1.ReportObjects.Count
If PageHeaderSection1.ReportObjects(I).Kind = CRAXDRT.crOLEObject Then
Set Pic1 = PageHeaderSection1.ReportObjects(I)
On Error Resume Next 'Just in case that the jpg doesn't exist (Could use Dir)
Set Pic1.FormattedPicture = LoadPicture(App.Path & "\EasyLab.jpg")
On Error GoTo 0
Exit For
End If
Next I
End Sub
JG
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
|