PRINTER.PRINT DUVIDAS
. Fala galera primeiramente feliz ano a todos e todas, bom o meu probleminha é o seguinte estou querendo alinhar valores a direita mas estou com problemas por ex:
Printer.Print "Saldo Anterior R$ "; Tab(40); Format$(Format$(txtsaldoanterior.Text, "###,###,##0.00"), "@@@@@@@@")
O que posso esta fazendo de errado neste código ele sai centralizado, desde já obrigado...
Printer.Print "Saldo Anterior R$ "; Tab(40); Format$(Format$(txtsaldoanterior.Text, "###,###,##0.00"), "@@@@@@@@")
O que posso esta fazendo de errado neste código ele sai centralizado, desde já obrigado...
mcurrenty = printer.currenty
Printer.Print "Saldo Anterior R$ "
printer.currenty = mcurrenty
printer.currentx = printer.scalewidth - printer.textwidht (Format$(Format$(txtsaldoanterior.Text, "###,###,##0.00"), "@@@@@@@@") )
printer.print Format$(Format$(txtsaldoanterior.Text, "###,###,##0.00"), "@@@@@@@@")
blz?
Printer.Print "Saldo Anterior R$ "
printer.currenty = mcurrenty
printer.currentx = printer.scalewidth - printer.textwidht (Format$(Format$(txtsaldoanterior.Text, "###,###,##0.00"), "@@@@@@@@") )
printer.print Format$(Format$(txtsaldoanterior.Text, "###,###,##0.00"), "@@@@@@@@")
blz?
Caju blz é isso ai só tem mais uma coisinha se tiver mais valores na mesma linha por ex:
Printer.Print lstlista.SelectedItem; Tab(20); ValorEmpresa; Tab(40); Format$(Format$(lstlista.SelectedItem.SubItems(2), "###,###,##0.00"), "@@@@@@@@"); Tab(60); Format$(Format$(lstlista.SelectedItem.SubItems(3), "###,###,##0.00"), "@@@@@@@@"); Tab(80); Format$(Format$(lstlista.SelectedItem.SubItems(4), "###,###,##0.00"), "@@@@@@@@"); Tab(100); Format$(Format$(lstlista.SelectedItem.SubItems(5), "###,###,##0.00"), "@@@@@@@@")
como seria a linha de código?
[S50]
Printer.Print lstlista.SelectedItem; Tab(20); ValorEmpresa; Tab(40); Format$(Format$(lstlista.SelectedItem.SubItems(2), "###,###,##0.00"), "@@@@@@@@"); Tab(60); Format$(Format$(lstlista.SelectedItem.SubItems(3), "###,###,##0.00"), "@@@@@@@@"); Tab(80); Format$(Format$(lstlista.SelectedItem.SubItems(4), "###,###,##0.00"), "@@@@@@@@"); Tab(100); Format$(Format$(lstlista.SelectedItem.SubItems(5), "###,###,##0.00"), "@@@@@@@@")
como seria a linha de código?
[S50]
tente
Private Sub Command1_Click()
ImprimeAlinhadoDireita "Teste1"
ImprimeAlinhadoDireita "Teste2"
ImprimeAlinhadoDireita "Teste3" & "Teste 4", 1000
End Sub
Sub ImprimeAlinhadoDireita(Texto As String, Optional PosicaoY)
If Not IsMissing(PosicaoY) Then
Printer.CurrentY = PosicaoY
End If
Printer.CurrentX = Printer.ScaleWidth - Printer.TextWidth(Texto)
Printer.Print Texto
End Sub
Valeu Guru....
Tópico encerrado , respostas não são mais permitidas