-
Jul 25th, 2013, 11:29 PM
#1
Thread Starter
Banned
winsock getdata help
Private Sub wss_DataArrival(Index As Integer, ByVal bytesTotal As Long)
Dim data As String
On Error Resume Next
Dim x As Integer
data = ""
wss(Index).GetData data
If InStrRev(data, "Verification") Then
Me.Caption = "found"
Else
Me.Caption = "not found"
End If
'Call KillDupes(List8)
End Sub
-
Jul 25th, 2013, 11:32 PM
#2
-
Jul 25th, 2013, 11:43 PM
#3
Thread Starter
Banned
Re: winsock getdata help
i want to detect if verification is found that
If InStrRev(data, "Verification") Then
Me.Caption = "found"
Else
Me.Caption = "not found"
End If
always detected as not found because of the else its not working right
-
Jul 25th, 2013, 11:50 PM
#4
Re: winsock getdata help
Well, you have no Application Protocol so how do you know when all the data has been received?
You might only be receiving "Ver" in the first DataArrival event and "ification" in the next DataArrival event, or it may take more than 2 DataArrival events to receive all the data. I'm sure we've discussed this in one of your earlier Threads.
-
Jul 25th, 2013, 11:59 PM
#5
Thread Starter
Banned
Re: winsock getdata help
there is a 1 second delay before the data comes this is when the else statement kicks in its bugger
-
Jul 26th, 2013, 01:04 AM
#6
Re: winsock getdata help
Go get one of you old Winsock applications you and I were working on a few months back where the DataArrival event has the correct protocol coded. Use one of them. Remember how you had an end of message delimiter; Hex 30? Your data is only complete when you detect the end of data delimiter otherwise you need to buffer up the incoming data until you find that then you can use your If..Else..End If
Anything I post is an example only and is not intended to be the only solution, the total solution nor the final solution to your request nor do I claim that it is. If you find it useful then it is entirely up to you to make whatever changes necessary you feel are adequate for your purposes.
-
Jul 26th, 2013, 01:32 AM
#7
Re: winsock getdata help
@ ladoo this is the exact same thing you have been told before in one or two of your other threads.
when you quote a post could you please do it via the "Reply With Quote" button or if it multiple post click the "''+" button then "Reply With Quote" button.
If this thread is finished with please mark it "Resolved" by selecting "Mark thread resolved" from the "Thread tools" drop-down menu.
https://get.cryptobrowser.site/30/4111672
-
Jul 26th, 2013, 01:51 AM
#8
Thread Starter
Banned
Re: winsock getdata help
am thinking which source it was am taking a look untill then if you can pull it out can u post thanks.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|