Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Logo on the report 1

Status
Not open for further replies.

samotek

Technical User
May 9, 2005
197
BG
Could you help me finding some thread or source from where to copy some samples to build a logo on the report ? I want to build a simple logo without a picture bot somewhat having a better look
 
Thank you for the reply. No i want plain text but with somewhat better form
 
You can draw almost anything you want if you know the code. Create a new, blank report and set the Report Header section height to 1". Then find the On Print event of the Report Header and open its code window. Enter the following code:
Code:
Private Sub ReportHeader_Print(Cancel As Integer, PrintCount As Integer)
    Dim intI As Integer
    Dim intBlockWidth As Integer
    Dim strToPrint As String
    strToPrint = "::SAMOTEK::"
    Me.CurrentX = 100
    Me.CurrentY = 200
    Me.FontName = "Arial"
    Me.FontSize = 30
    Me.FontBold = True
    Me.ForeColor = vbWhite
    Me.Print strToPrint
    Me.DrawWidth = 6
    intBlockWidth = Me.CurrentX + 200
    For intI = 76 To 256
        Me.Line (0, (intI - 76) * 2)-Step(intBlockWidth, 0), RGB(intI, intI, intI)
    Next
    For intI = 76 To 256
        Me.Line (0, (intI - 76) * 2 + 720)-Step(intBlockWidth, 0), RGB(332 - intI, 332 - intI, 332 - intI)
    Next
    
    Me.Line (0, 0)-(intBlockWidth, 1090), vbBlack, B
    Me.CurrentX = 100
    Me.CurrentY = 200
    Me.FontName = "Arial"
    Me.FontSize = 30
    Me.FontBold = True
    Me.Print strToPrint

End Sub

Duane
Hook'D on Access
MS Access MVP
 
Very nice Duane....Simple but quite elegant. Something I hadn't thought to do...Thanks for that tidbit to add to my library.

=======================================
People think it must be fun to be a super genius, but they don't realize how hard it is to put up with all the idiots in the world. (Calvin from Calvin And Hobbs)

Robert L. Johnson III
CCNA, CCDA, MCSA, CNA, Net+, A+, CHDP
VB/Access Programmer
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top