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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VB6 -Printing

Status
Not open for further replies.

MAVTCR

Programmer
Feb 23, 2021
28
IN
I have made a software where there is printing option.When we view the printable report, It is OK.It displays as I wish.Since there is no printer connected with my computer,I saved the report in a file.Then when I open this file(it is in text format) the alignment is different from what was in original. So I think If I could convert the report in to PDF format,the report will be unchanged as I wish.Is there any way to convert the VB6 report to PDF format through the programme itself. Please help.
 
this file(it is in text format)" - so you create a text file and that is your 'report'?
"When we view the printable report, It is OK.It displays as I wish" - how do you 'view' this report? What do you use to view it?
"when I open this file" - in what? Notepad? Word? Excel?

---- Andy

"Hmm...they have the internet on computers now"--Homer Simpson
 
I created report using data environment and data report.When I view this report it is OK.Since I have no printer attached I have to save this report in a separate folder, and I have to save it in .txt,.html etc format.Then I saved in .txt format.Here the problem arises.
 
When you open your txt 'report', what do you use to open it? Notepad?
If so, what Font do you use in your Notepad?
If the text in your txt 'report' does not align, try setting it to a fixed length font, like Courier or Courier New

---- Andy

"Hmm...they have the internet on computers now"--Homer Simpson
 
On Woindows 10 you should have Microsofdt's Print to PDF feature (thisn pretends to be a printer, but outputs PDFs). So just select 'Microsoft Print to PDF' as ypur printer. If it is not available then you can reenable it via [tt]Turn Windows features on or off[/tt]


feqatures_zwjrum.png
 
Mine is windows 7 ,where there is no Microsoft print to PDF
 
Again regarding the above printing report:I could not solve the above problem. At the same time I met with another problem.My software otherwise(report alignment mistake)works well in VB6 environment.
But when made a set up package and tried in another computer having no VB6.It works except the report.When I click for print report the following error message is displayed
"Runtime error-713
Application-defined or object defined error"
and the programme is quitting .

Can Any body help me
 
I presume you are using the included VB6 packager rather than a 3rd party tool. There's a bug - it doesn't have any dependencies for the necessary Data Report runtime DLL. it's a known bug, and one that Microsoft used to have a knowledgebase article about, but have retired since VB6 is no longer under any form of support. Fortunately there are those on the internet who keep some of these things alive, so I suggest you have a look at
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top