|
Before sending the data or receiving it , Iam flushing the buffer using following method.
int nReturnValue = PurgeComm(handlePort_,PURGE_TXCLEAR | PURGE_RXCLEAR);
And the return value is non-zero, i.e flushing succeded.
I checked both, with and without PurgeComm(). But still its not working.i.e Output is same for both.
And the length received is coming as 0.
I didnt understand one thing, Iam sending the data only ones, but why its receiving it those many times and why data is not coming?
Thank You.
Ayesha
-- modified at 2:54 Tuesday 11th July, 2006
|
|
|
|
|
Flush the buffer after sending the data using FlushFileBuffers. This ensures that nothing gets stuck in a buffer waiting to send.
If you are sending the data only once but the remote end is receiving it many times, make sure you have your line enders right -- it could be that the remote end is getting confused. Try 13 10, just 10, and just 13 -- I can never remember which of those are the usual line enders.
earl
|
|
|
|
|
Ayesha wrote:
result = WriteFile(handlePort,parameterNCheckSumData,99,&length,NULL);
What is parameterNCheckSumData? Should'nt it be dataToSend.
Adios,
Cool Ju
Dream Ur Destiny
|
|
|
|
|
Yes , that is dataToSend its not parameterNCheckSumData. But thats just a char buffer name. I want to know why data is not being received properly.
Thanku You.
Ayesha
|
|
|
|
|
Hi,
What type of I/O are you performing Overlapped or Non-overlapped?
Have you set timeouts? If not, Try setting timeouts.
If possible post some code.
Adios,
Cool Ju
Dream Ur Destiny
|
|
|
|
|
Hello,
I added an ActiveX to my application but when I gave the program to other people the activeX isn't there...
How can I add/paste the ActiveX to my program so if i'll give it to another people it will work.
SnaidiS(Semion)
|
|
|
|
|
It has to be registered in others systems too,to whome u give,then it will work..
|
|
|
|
|
|
u must supply the activex alone with ur exe and Register that exe in the target mechine. Its good if u appoint a Installer for this purpose.
nave
|
|
|
|
|
How can I get the handle of object?
SnaidiS(Semion)
|
|
|
|
|
regsvr32 [path_to_your_activex_dll]
|
|
|
|
|
I wrote a code to register the activeX but when I'm giving the program to anither computer it can't find the activeX
SnaidiS(Semion)
|
|
|
|
|
try using IPropertyBag interface.
Regards
Abhishake Lahare
|
|
|
|
|
Sorry implement IPropertyBag for your control
Regards
Abhishake Lahare
|
|
|
|
|
Did you actually give them the .ocx file?
Why is common sense not common?
Never argue with an idiot. They will drag you down to their level where they are an expert.
|
|
|
|
|
Here I have a problem that specified port is working or not ie when we give a port number then it should give that port is running or not.plz anybody help to me
#sankar#
|
|
|
|
|
runing in the sense..do u mean already in use..?
|
|
|
|
|
thanque for ur reply
but i want display it is running or not.
for example if i give 8080 then program will give corresponding port is running or not.plz kindely help me
#sankar#
|
|
|
|
|
|
sankarRao wrote: ere I have a problem that specified port is working or not ie when we give a port number then it should give that port is running or not.plz anybody help to me
how many time do you need answer to same problem... have you checked answer to your previous question!.. search ofr key Port Scanner
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and You
|
|
|
|
|
same question and same ....!?
whitesky
|
|
|
|
|
WhiteSky wrote:
same question and same ....!?
what to do!
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and You
|
|
|
|
|
See Here[^] maybe it is some helpful to you
whitesky
|
|
|
|
|
sankarRao wrote: when we give a port number then it should give that port is running or not.
Ports do not run. They are monitored by applications. You can, instead, check whether a port is being monitored or not.
"The largest fire starts but with the smallest spark." - David Crow
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Hi all,
I have created a CEditBox dynamically, while i am entering some text it is accepting only with in the range of the CEditBox. i can't enter beyond the Range of the CEditBox.
But this is not with CEditBox of the ToolBar, because when we run the Application with CEditBox Choose statically from the ToolBar to CDialog. When you run the Application the CEditBox takes as many Charaters you want.
I used Set SetLimitText(...) to set the Length of the CEditControl but it is not taking, Please help me Out.
//==========================================================================
CEdit *ptr = new CEdit;
ptr->Create(WS_VISIBLE|WS_CHILD|WS_BORDER,CRect(point.x,point.y,point.x +100, point.y +20),this,NULL);
ptr->SetLimitText(100); //Not Working ---> it is not taking 100 Chars Why !
//==========================================================================
uday.
|
|
|
|