|
Once again thanks.
I'll do that, relay nothing else to try.
|
|
|
|
|
OK.
I've tried opening new project (dialog based) and put progress ctrl on dialog with smooth property and still nothing. I've did some surfing on net and found similar questions, they suggested (over at MSDN) to change windows theme to classic. After doing so, my progress ctrl did work with smooth style applied but come on that can't be solution!?
I don't wont to do that!
|
|
|
|
|
hello all. I am reading some data from xml file. I memcpy it to a BITMAP structure variable. Now I need to convert this to HBITMAP. how do I do this?
|
|
|
|
|
By using CreateBitmapIndirect...
|
|
|
|
|
|
Welcome... Don't forget to call DeleteObject to delete it when it is no longer needed.
|
|
|
|
|
Hi,
I have an UI developed using VC++. This UI identifies the com port in the system, upon selecting the com port and clicking OK button, the main application opens where commands is sent using com for communication with target. A usb to serial RS232 convertor for COM is being used. This UI is woking fine in some XP system.
When this UI executed in newly installed XP machine, it identified the com port but on cliking OK the application is getting closed.Before clicking OK button the com port would be opened and connected using another button. Is any dll is missing?
Thanks
|
|
|
|
|
Did you get an error message? If yes, please give details.
BTW try also to insert some debugging info (for instance logs) in your application.
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]
|
|
|
|
|
No i didn't get any error message.
|
|
|
|
|
Since you cannot possibly use the debugger on the failing machine, provide some trace info in you application.
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]
|
|
|
|
|
Hi All,
I am creating a client server project .
My server is multithreaded, One thread is created for each request
from client.
Now my problem is:
As i send the 10 reuests at a time to the server Some of the receive
gets fail even after successful accepting, and give the 10038 error
number.
I have set the 15 sec time out for rece on client and server side.
But my server returns the error with in a second.
kindly help
|
|
|
|
|
Would help if you were to show some of your code too.
10038 is. btw, WSAENOTSOCK, so you specified something that's not a socket to a call which takes a valid socket. At the first run, without knowing much of what your code does, i'd say this is a thread synch problem.
> The problem with computers is that they do what you tell them to do and not what you want them to do. <
|
|
|
|
|
Anyone know if it's possible to create a shell extension that will change the text shown in the file type column in the same way as the IExtractIcon shell extension allows you to display a custom icon according to file content?
|
|
|
|
|
Does anybody know any tool that can be used to identify data types used in files?
I need to search and list out all the data types (primitive, MFC, STL data types) used as class members, function parameters, etc., in a large volume of c++ files (need to consider the header files only).
modified on Friday, December 12, 2008 4:47 AM
|
|
|
|
|
my initial thought would be along the lines of find a parser & grammar for c++, generate a parse-tree and walk that looking for the declarations you need ...
[edit] its not an easy thing you ask .. this is one way http://www.devincook.com/goldparser/[^]
alternatively, I guess you can do a brute force match against an array of key-words representing what you'd like to identify, eg {"map","vector","int","string"...} there was an article about this on cp somewhere
It depends on context/what/how you will use the info
'g'
|
|
|
|
|
Thank you... I have some time constraint too...
|
|
|
|
|
I have a global variable defined as "char toAscii[255]" in some MyFile.c
I declared another variable as "extern char *toAscii" in some other file YourFile.c of same console application.
In YourFile.c, I accessed toAscii as "toAscii[0] = 1;"
No linking error. Linker generate mangaled name same for both as "int * toAscii" (?toAscii@@3PAHA)
but at runtime "toAscii[0] = 1" is causing crash because it point to a NULL while debugger showing a valid address.
If I change "extern char *toAscii" to ""extern char *toAscii[]", every thing works fine.
I just want to know why in first case it toAscii points to NULL at runtime while we have same mangaled name for both. I am using VC2005.
Manish Agarwal
manish.k.agarwal @ gmail DOT com
|
|
|
|
|
There are difference in the code generated for "toAscii[0] = 1;" when toAscii is declared as "extern char *toAscii" and "extern char toAscii[]".
1. When toAscii is defined as "extern char *toAscii"
toAscii[0] = 1;
00401DED mov eax,[toAscii (004167c0)]
00401DF2 mov byte ptr [eax],1
2. When toAscii is defined as "extern char toAscii[]"
toAscii[0] = 1;
00401DED mov byte ptr [toAscii (004167c0)],1
I hope you understood.
|
|
|
|
|
yes, but you don't think that linker should be able to report such errors. Why it resolve "extern char *toAscii" to char "char toAscii[255]"
Manish Agarwal
manish.k.agarwal @ gmail DOT com
|
|
|
|
|
Manish K. Agarwal wrote: but you don't think that linker should be able to report such errors
Yes, as you mentioned if the mangle name where different, this wouldn't have happened. Try reporting it in http://connect.microsoft.com/[^]
|
|
|
|
|
Hi,
IIRC the correct way to handle this is:
- have a single .c file (say file1.c) that declares the variable (either char toAscii[256] or char* toAscii)
- have all other interested .c files refer to it using extern char* toAscii
the best way to do that is to include it in a .h file
- best is to have file1.c also include that header, so the compiler checks both are compatible.
Doing it that way the variable gets allocated only once, and the declarations are correct and available everywhere.
|
|
|
|
|
How to write the program to solve the formula 2n*(2n-1)............1 in c++
neha
modified on Friday, December 12, 2008 4:17 AM
|
|
|
|
|
There are (at least) two ways:
- use a loop.
- use recursion.
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]
|
|
|
|
|
long result = 1;
for (int i = 2 * n; i > 1; --i) {
result = result * i;
}
Manish Agarwal
manish.k.agarwal @ gmail DOT com
|
|
|
|
|
Please do not do peoples homework for them.
If you want to be helpful then it would be better to send them some links to searches at google so that the OP can find the answer for themself.
I would but I never ever answer "urgent" questions.
|
|
|
|