Google Gruppi non supporta più i nuovi post o le nuove iscrizioni Usenet. I contenuti storici continuano a essere visibili.

Ne-number on activeprinter

62 visualizzazioni
Passa al primo messaggio da leggere

Lars Thomsen Nielsen

da leggere,
15 nov 2002, 17:49:1015/11/02
a
Excel2000: I have had the same problem as many other with the
Ne-number in the end of the active printer. The problem is that
the number changes from time to time and on the different PC's. I
have however found a solution to the problem, that I hope some of
you can use. It's a bit ugly, but it works ;-)

Best regard

Lars Thomsen Nielsen


Sub NeNumber()
Dim Tal As String
Printer = "\\NETWORK\TESTPRINTER"
On Error Resume Next
For i = 1 To 99
If i < 10 Then
Tal = "0" & i
Else
Tal = i
End If
Err.Number = 0
Application.ActivePrinter = Printer & " on Ne" & Tal & ":"
If Err.Number = 0 Then
MsgBox "Printer installed: " & Printer & " on Ne" & Tal & ":"
Exit For
End If
Next
End Sub

********************************************************
This emails is made by 100% recycled electrons
********************************************************

0 nuovi messaggi