leer puerto com

Upload: oscarrivera

Post on 07-Jul-2018

212 views

Category:

Documents


0 download

TRANSCRIPT

  • 8/18/2019 Leer Puerto Com

    1/1

    Private Sub LeerPuerto()  Try  'StrLeer = CInt(Mid(Puerto.ReadExisting, 1, 7)) 'Este captura peso de 5 digitos mayor a cero  StrLeer = Puerto.ReadExisting()  If (LblLeerPuerto.Text StrLeer) And StrLeer Nothing Then  If StrLeer > 0 Then  LblLeerPuerto.Text = StrLeer  Else  LblLeerPuerto.Text = Format(StrLeer, "00")  End If  End If  Catch ex As Exception  StrLeer = Mid(Puerto.ReadExisting(), 2, 3) 'Este captura peso de 5 digitos mayor a cero

      If (LblLeerPuerto.Text StrLeer) And StrLeer Nothing Then  LblLeerPuerto.Text = Format(StrLeer, "00")  End If  End Try

      End Sub