Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
CommTools Vs. Crystal Reports
Message
De
15/08/1998 21:33:40
Shihchau Tai
Apic Systems Pte Ltd
Singapore, Singapour
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Produits tierce partie
Divers
Thread ID:
00127052
Message ID:
00127182
Vues:
41
First, I must apologize to VFP forum members for posting codes in VB. I am very much a VFP programmer but I have problem getting MSCOMM32 done in VFP.

2 questions:
1. How to get MSCOMM32 to work on VFP. I see a lot of OLE errors on the object property sheet.
2. With reference to the following codes, I get error = Port already open and Portopen and subsequent system just waits on doevents. Any hint?

Private Sub Form_Load()
CommCtrl.CommPort = 2
CommCtrl.Settings = "9600,n,8,1"
CommCtrl.InputLen = 0
On Error Resume Next
If CommCtrl.PortOpen = False Then CommCtrl.PortOpen = True
If Err Then
MsgBox "There was an error opening the port. Error = " & Error$
End If
If CommCtrl.PortOpen = False Then
MsgBox "PortOpen"
End If
CommCtrl.Output = "ATZ" + Chr(13)
Do
DoEvents
InString$ = InString$ & CommCtrl.Input
If InStr(InString$, "OK" & vbCrLf) Then Exit Do
Loop
Debug.Print InString$
If CommCtrl.PortOpen = False Then
CommCtrl.PortOpen = True
End If
End Sub


>Are you sure you can open the port? Are you sure you have the correct port setting? I can use the control in both VFP and VB.
>
>
>>>I have NT 4 SP3 and the MS COMM control works fine for me....
>>>
>>>>>>I meant CrystalComm. Can the MSCOMM control use KERMIT? I was told not.
>>>>>>Marcus.
>>>>>
>>>>>I don't know if MSCOMM supports kermit. For something more sophisticated, I would check out www.mabry.com.
>>>>
>>>>Does MSCOMM works on WinNT 4.0 SP3? I didn't manage to get it working the last time I tried. Did you have any success?
>>
>>
>>Do you have any idea why I can't open the port even when Port_open = False? I am using VB. Are you using VFP to call MSCOMM32?
>>
>>I test using:
>>If mscomm1.port_open = false then
>> mscomm1.port_open = true
>>endif
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform