TCP File transfer and program execution ?

BlitzPlus Forums/BlitzPlus Programming/TCP File transfer and program execution ?

Filax(Posted 2005) [#1]
hi :)

I'm trying to tranfer a file between a b+ app to another but there is a
problem.

I send the data with a little timer like this :

If BCF_TimeOut (AppRefreshTimer) And MyClient<>0 Then
AppRefreshTimer=BCF_SetTimer(AppRefreshRate)

WriteLine MyClient," This is a test"
InsertGadgetItem AppList01,-0,"Send..."
EndIf

But when the server receive the data with a stuff like this :

If strStream Then
While Not Eof(strStream )
MyData$=ReadLine$(strStream)
InsertGadgetItem AppList01,-0,MyData$
Wend
EndIf

The server program block all GUI event (very slow) ? while receiving
data ?? is there a way to remove this ?


Filax(Posted 2005) [#2]
I have find (Admin you can remove this post) sorry


Andres(Posted 2005) [#3]
For those who have the same problem:

He hsould had used If ReadAvail(strStream) there too because function ReadLine will wait for the data to be received if there is no line in the buffer already.


Sonari Eclipsi Onimari(Posted 2005) [#4]
This sounds like a virus...... What exactly is the purpose of your prog? Not being objective or anything....


Filax(Posted 2005) [#5]
What ??

How do you see a virus in a TCP file transfert :) ????


Sonari Eclipsi Onimari(Posted 2006) [#6]
Same principal. Open tcp stream, send virus, run virus, close tcp stream.. .It sounded like it to begin with. SORRY!!!