zirac was telling us:
zirac nous racontait que :
I did try the Part 1 but since I am not really familiar with VB I was
not able to get the values. I "copy and paste" the codes on a new
module then run the program and got a syntax error. Will you please
direct me to the correct direction or a more detailed step is
appreciated.
Open a blank document in Word,
Make sure the target printer is set as being the active one,
Create a VBA module and paste Jonathan's code from Part 1 in the article
series I refer you to,
Add this sub at the end of the code:
'_______________________________________
Sub GetPrinterBinInfo()
Dim i As Long
Dim arrNames() As Variant
Dim arrNumbers() As Integer
arrNames() = GetBinNames
arrNumbers() = GetBinNumbers
For i = 0 To UBound(GetBinNumbers)
Selection.TypeText "Bin #" & i + 1 & ": " & arrNames(i) _
& " - Number " & arrNumbers(i) & vbCrLf
Next
End Sub
'_______________________________________
Now run the Sub.
Your previously blank document should now list the paper bins (their names
and numbers) for the currently active printer.
Now go into your old code, change the bin numbers according to the ones you
want that code to use.
--
Salut!
_______________________________________
Jean-Guy Marcil - Word MVP
(e-mail address removed)
Word MVP site:
http://www.word.mvps.org