Solved

Printing a graph

Posted on 2000-05-11
6
245 Views
Last Modified: 2008-02-26
I am using Pinnacle-BPS Graph Control. In the properties, I can either Copy, Print or Write. The Copy and Write actions work fine - but it does not print. The screen gives a quick flick as though something is happening, but does not print.

I know I can print using FormPrint, but I should be able to get better resoultion using the control (as they say) and it should work!  Any suggestions?
0
Comment
Question by:Wicksy
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 28

Expert Comment

by:Ark
ID: 2802559
Hi
Haven't this control, so some common advices:
Try to initialize printer before printing:
Printer.Print ""
Which parameters do you pass to Print method?
Cheers
0
 

Author Comment

by:Wicksy
ID: 2809395
Printer.Print "" has made no difference. To make the graph print, one sets the DRAWMODE=5 and that's it. To copy to the clipboard, DRAWMODE is set to 4 (and this works fine).
0
 

Expert Comment

by:leveller225
ID: 2827911
hello

i've used the Pinnacle-BPS Graph Control and never recall having had any problems.  this code seemed to work ok.

' set paper orientation
Printer.Orientation = vbPRORLandscape
printer.FontTransparent = False
Printer.Font = ""
Printer.Print
Printer.ScaleMode = Twips
' print info for control
frmFTMain.graphFractures.PrintInfo(1) = Printer.hDC
frmFTMain.graphFractures.PrintInfo(6) = Printer.ScaleLeft
frmFTMain.graphFractures.PrintInfo(7) = Printer.ScaleTop
frmFTMain.graphFractures.PrintInfo(8) = Printer.ScaleWidth
frmFTMain.graphFractures.PrintInfo(9) = Printer.ScaleHeight
frmFTMain.graphFractures.PrintInfo(2) = 1.25 * 1440             ' x coord top left of graph
frmFTMain.graphFractures.PrintInfo(3) = 1.75 * 1440             ' y coord top left of graph
frmFTMain.graphFractures.PrintInfo(4) = 8 * 1440                ' graph width
frmFTMain.graphFractures.PrintInfo(5) = 6 * 1440                ' graph height
' print mode
If gColorPrintMode = False Then
frmFTMain.graphFractures.PrintStyle = G_MONO                 ' 0
    Else
frmFTMain.graphFractures.PrintStyle = G_COLOR                ' 1
End If
' setup fonts
frmFTMain.graphFractures.FontUse = 0
frmFTMain.graphFractures.FontSize = 75
frmFTMain.graphFractures.FontUse = 1
frmFTMain.graphFractures.FontSize = 50
frmFTMain.graphFractures.FontUse = 2
frmFTMain.graphFractures.FontSize = 50
frmFTMain.graphFractures.FontUse = 3
frmFTMain.graphFractures.FontSize = 50
' send graph
frmFTMain.graphFractures.DrawMode = G_PRINT                     ' 5
Printer.EndDoc

good luck
0
Salesforce Made Easy to Use

On-screen guidance at the moment of need enables you & your employees to focus on the core, you can now boost your adoption rates swiftly and simply with one easy tool.

 
LVL 1

Accepted Solution

by:
csameer1 earned 100 total points
ID: 2843576
i have not used that control before.

For charting may i suggest teechart control from www.teemach.com,you dont need to code for print preview,print,save,recall etc

Another method i have used before (mscharts if i remember right)is copying the chart onto the clipboard and PaintPicture it onto the printer or image/pic controls to printer.
0
 

Author Comment

by:Wicksy
ID: 2857313
Answer accepted
0
 

Author Comment

by:Wicksy
ID: 2857314
Thanks for your help everyone, I think the problem was in the control. I managed to get an upgrade and this fixed the problem ....!
0

Featured Post

Revamp Your Training Process

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Suggested Courses
Course of the Month6 days, 8 hours left to enroll

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question