Select Printer From A List Follow

0
Avatar
Legacy Poster

Hi,

i'm trying to use ActiveX from C# code and i'm unable to find a method for retrieving the list of printers installed.

I haven't find any topic about that in forums...

 

Thanks!

 

Marco

3 comments

0
Avatar
Michael Toupin (mtoupin
Comment actions Permalink

BarTender doesn't have functionality to enumerate the printers from Windows, what you'll do is use the PrinterSettings.InstalledPrinters property from Windows to be able to get the printers list.
0
Avatar
Legacy Poster
Comment actions Permalink

Thank you Mike!

 

I have another question but it's not related to the topic.

Is there a way to generate the image file (.jpg) of a format print preview?

I am able to show the preview dialog but i need to show the preview into a picture box.

 

Thank you again!

0
Avatar
Domingo Rodriguez
Moderator
Comment actions Permalink

You have several ways of doing this:

 

  • Use the Format.ExportToClipboard() method.
  • Use the Format.ExportToFile() method.
  • Use the Format.ExportPrintPreviewToImage(method) --> only available in Enterprise Automation Edition of BarTender.

 

For further reference, please take a look BarTender's Help (press F1 key within BT), and now at the "Automating BarTender > Automation with ActiveX" topic.

Please sign in to leave a comment.