|
HI,
Even I have overloadd the OnLButtonDown and checking for CrSel.cpMin and cpMax position as well.
It is working fine in Debugging mode, but when exected without debug mode it is giving problem.
Raghu
|
|
|
|
|
Raghu Panduranga wrote: It is working fine in Debugging mode, but when exected without debug mode it is giving problem
any error message by chance ?
|
|
|
|
|
If you're still struggling, I've used Eugene Pustovoyt[^]'s CPPDumpCtrl[^] in the past with great success. A nice little hex / ascii display / editor.
Though I think the article name needs work!
Iain.
Plz sir... CPallini CPallini abuz drugz, plz plz help urgent.
|
|
|
|
|
Hi,
Thank you for sharing infromation. Please let me know how can i use tool tip here?
Raghu
|
|
|
|
|
I have no idea, off the top of my head. When I display the hex data, anything I want to know about is on the screen already (address, hex value, and ascii value). As there is no additional information, I don't need tooltips for the control.
As it inherits from CWnd, I imagine you can use CWnd::EnableTooltip(s) (can't remember exactly). But when I use tooltips, I roll my own, as I like tips that vary depending on where I am in the control.
There are many articles on tooltips, and I would also recommend you look at CPopupText from MSDN magazine June 2001, written by Paul DiLascia. Back then I was learning [*], and his articles taught me a lot.
Iain.
[*] I still am - but I hope I have the easy stuff in my head now!
Plz sir... CPallini CPallini abuz drugz, plz plz help urgent.
|
|
|
|
|
Thank you for your sharing information i think it is helpful for me.
Raghu
|
|
|
|
|
increment operator is not executing when debug in release mode.
Ex
int i = 0;
the below two statement are not executing
i++;
++i;
But in Debug it is working fine.
|
|
|
|
|
How do you verify that ? Is the i variable used afterwards or not ? Could you post some code.
It is maybe due to optimization: if your variable is never used later, the compiler can detect and decide that it is not usefull to increment it (I guess).
|
|
|
|
|
Code below is only executing the first and second line and skiping the third line in bold
char *strCalcCode = strCalcCodesName;
strcpy_s( strCalcCode, CALC_CODES_LTH, CALC_CODE_STR[CC_ASTR] );
strCalcCode += strlen (CALC_CODE_STR [CC_ASTR]);
|
|
|
|
|
What are you doing with this strCalcCode variable later ? If you don't use it later, the compiler probably optimizes the code and decided that this line of code is unnecessary (which is the case because it doesn't do anything usefull in the case you don't use strCalcCode later on).
pallaka wrote: Code below is only executing the first and second line and skiping the third line in bold
Again, how are you verifying that ?
|
|
|
|
|
Edited: Cedric asked the question while I was reading the forum. Sorry!
------------------
I'll ask the same question again:
How are you verifying that?
Iain.
Plz sir... CPallini CPallini abuz drugz, plz plz help urgent.
|
|
|
|
|
I am doing debug in Release mode by keeping the break point on the statement and trying to execute one by one.It is simply skipping the statments and cursor is jumping to the next statement.This is how i tested that.
|
|
|
|
|
How did you detect that?
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
I am doing debug in Release mode by keeping the break point on the statement and trying to execute one by one.It is simply skipping the statements and cursor is jumping to the next statement.This is how i tested that.
ex:
Statement 1
int i = 0;
i++;
++i;
Cout << i;
Statement 2;
it will jump to Statement2;
|
|
|
|
|
pallaka wrote: int i = 0;
i++;
++i;
Maybe the compiler optimized the above lines to
int i=2;
What was the program output (i.e. did cout report the expected i value)?
BTW: 'statement jumping' may also heppen if debugger source browsing info is not updated (i.e. try to rebuild you project).
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
I tried keeping the optimization disabled in Project settings it work fine...
Thanks for all your support
|
|
|
|
|
How exactly do you debug in release mode? It shouldn't be possible to do that with the normal project settings. Do you change your project settings?
There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition.
Blaise Pascal
|
|
|
|
|
I tried keeping the optimization disabled in Project settings it work fine...
Thanks for all your support
|
|
|
|
|
I didn't understand that. When you say 'debug in release mode', do you mean that you run the project in release mode? If so, how can you trace? Release mode has debug symbols disabled.
There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition.
Blaise Pascal
|
|
|
|
|
While release mode also you can get the debugging information of the code.
In project settings you can set this option.
Debug information
|
|
|
|
|
pallaka wrote: While release mode also you can get the debugging information of the code.
I wish I knew of it before. There have been a couple of times when I had release-only bugs and this would have made my life a lot easier.
There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition.
Blaise Pascal
|
|
|
|
|
sashoalm wrote: I wish I knew of it before.
You should have asked!
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Hi,
I have to work on TFTP protocol for server.
I already have UDP server program.My question is If I am requesting a file from an TFTP client (Port no changed to 69),any of my UDP's call back functions such as OnConnect(), OnAccept(),Onreceive() function is called or not.
If it is not called what are the changes to be made for my UDP program to accept tftp commands.
Thanks in advance.
Regards,
Sunil Kumar
|
|
|
|
|
sunilkumar.d wrote: any of my UDP's call back functions such as OnConnect(), OnAccept()
OnReceive() should work but OnConnect and OnAccept are not used
with the UDP protocol.
sunilkumar.d wrote: what are the changes to be made for my UDP program to accept tftp commands
As with any protocol, you learn the protocol and implement it
in your code...
THE TFTP PROTOCOL (REVISION 2)[^]
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
I am trying to write a simple app to upload files via FTP. The first thing to do is call InterntOpen() to establish the connection. The description of the first argument is:
lpszAgent
Pointer to a null-terminated string that specifies the name of the application or entity calling the WinINet functions. This name is used as the user agent in the HTTP protocol.
What is this asking for? Should I use the name of the application I am writing? What is the string used for? In another place the descrption said:
lpszAgent Long pointer to a null-terminated string that contains the name of the application or entity calling the Internet functions (for example, Microsoft Internet Explorer). This name is used as the user agent in the HTTP protocol.
What am I supposed to enter here? Maybe "Microsoft Internet Explorer" That just does not seem right.
I found an example that used "InetURL/1.0" and it seems to compile, but a google search did not help. What is that and why should I use it?
Thanks for your time
|
|
|
|