Братцы, помогите не выполняется команда Output. Руками через прогу RS232Pro все фурычит, а так нет Private Sub Command1_Click()'Attribute VB_Name = "Module1"Dim TimeStartPort$ = "COM1"With MSComm1.InBufferCount = 0 ' .Output = "a"TimeStart = TimeEnd WithEnd SubPrivate Sub Command2_Click()Port$ = "COM1"With MSComm1.Output = "q"End WithEnd SubPrivate Sub Form_Load()Call InitComPrint MSComm1.CommIDEnd SubPrivate Sub InitCom()' With MSComm1'On Error GoTo ErrInit.CommPort = 1 ' .Settings = "9600,N,8,1".InputLen = 1.PortOpen = True.DTREnable = True.RThreshold = 1.Handshaking = comRTS.RTSEnable = True'expBegin.Caption = .Settings'expBegin.Caption = .CommIDPrint .SettingsDebug.Print MSComm1.CommIDOn Error GoTo 0End WithEnd Sub
|