In Focus

Forums - C# Corner

Forum guidelines


  • 1.5k
  • 68
  • 36.3k

convert papersource.sourcename to papersource.kind

Dec 20 2012 8:23 AM
I have 2 types of data, in the namespace System.Drawing.Printing:

Papersource.sourceName and Papersource.Kind.

SourceName gets the name og the papertrays from a printer, like "tray 1"

Kind gets the int value from the printer so fx. tray 1 have a kind value of 258.

in my combobox i only want to show the sourcenames, but if i choose "tray 1" i want to get a messagebox where i get the kind value of the sourcename.

Does anyone understand and have a example :)

Answers (10)


Build smarter apps with Machine Learning, Bots, Cognitive Services - Start free.

Start Learning Now