| |
   
Morovia.com Home | Fonts | Components | Labeling | Library | Order | Forum
  Active TopicsActive Topics  Display List of Forum MembersMemberlist  Search The ForumSearch  HelpHelp
  RegisterRegister  LoginLogin
Barcode ActiveX Control
 Community Forum : Barcode ActiveX Control
Subject Topic: BarCode Printing Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
atifmushtaq
Newbie
Newbie
Avatar

Joined: March 24 2008
Location: Pakistan
Posts: 11
Posted: March 29 2008 at 9:21pm | IP Logged Quote atifmushtaq

Sir,

I have use barcode in my application please tell  me that how can I print this and also tell me that is it possible that the Printing of barcode in Datareport in Visual Basic 6

 

Thanks

Back to Top View atifmushtaq's Profile Search for other posts by atifmushtaq
 
glitch
Admin Group
Admin Group
Avatar

Joined: January 25 2003
Location: Canada
Posts: 280
Posted: March 31 2008 at 10:27am | IP Logged Quote glitch

You can find the print code in the VB6 sample project. See code below:

Printer.ScaleMode = vbTwips    ' set the printer scalemode to Twips
'Coordinates for PaintPicture method must now be in Twips.
'1 inch has 1440 Twips.

XMargin = (Printer.Width - Printer.ScaleWidth) / 2
YMargin = (Printer.Height - Printer.ScaleHeight) / 2

X = 1 * 1440 '  X position in 1 Inch
Y = 1 * 1440 '  Y position in 1 Inch

X = X - XMargin ' adjust for margins
Y = Y - YMargin  ' adjust for margins
'Print the barcode directly to the printer, start at position X,Y
Printer.Print "Morovia Bar Code Activex Sample"
Printer.Print "Printing the barcode at X= 1 Inch, Y= 1 Inch"
Printer.PaintPicture MrvBarcode1.Picture, X, Y
'Eject the page...
Printer.EndDoc

Back to Top View glitch's Profile Search for other posts by glitch Visit glitch's Homepage
 
atifmushtaq
Newbie
Newbie
Avatar

Joined: March 24 2008
Location: Pakistan
Posts: 11
Posted: March 31 2008 at 1:46pm | IP Logged Quote atifmushtaq

Thank you but I Enter this code & when I order to print it say Variable not defiend

 

Please help me

Back to Top View atifmushtaq's Profile Search for other posts by atifmushtaq
 
glitch
Admin Group
Admin Group
Avatar

Joined: January 25 2003
Location: Canada
Posts: 280
Posted: March 31 2008 at 3:27pm | IP Logged Quote glitch

Find out which variable is undefined.

Back to Top View glitch's Profile Search for other posts by glitch Visit glitch's Homepage
 
atifmushtaq
Newbie
Newbie
Avatar

Joined: March 24 2008
Location: Pakistan
Posts: 11
Posted: April 01 2008 at 10:18pm | IP Logged Quote atifmushtaq

" XMargin = "

 

Sir,

Please tell me where i put this code , in button or................

 

Please help me as soon as possible

Back to Top View atifmushtaq's Profile Search for other posts by atifmushtaq
 
glitch
Admin Group
Admin Group
Avatar

Joined: January 25 2003
Location: Canada
Posts: 280
Posted: April 02 2008 at 10:54am | IP Logged Quote glitch

You can remove them, or define them as

Dim XMargin As Integer

Back to Top View glitch's Profile Search for other posts by glitch Visit glitch's Homepage
 
atifmushtaq
Newbie
Newbie
Avatar

Joined: March 24 2008
Location: Pakistan
Posts: 11
Posted: April 03 2008 at 10:00pm | IP Logged Quote atifmushtaq

Thank you now it will ok
Back to Top View atifmushtaq's Profile Search for other posts by atifmushtaq
 

If you wish to post a reply to this topic you must first login
If you are not already registered you must first register

  Post ReplyPost New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.3281 seconds.