|
In this one, it has do dynamic_cast several times correctly, but encounter a runtime error at this one.
|
|
|
|
|
followait wrote: ...it report runtime error, when using dynamic_cast...
How are you verifying this?
"Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Just run it in VC6 debug mode.
Not only dynamic_cast , typeid also has such a problem
|
|
|
|
|
A number of companies offer code signing certificates, for prices from $100-200. I'm wondering if some are better than others, or perhaps the tools some provide make them worth the extra expense.
Anyone have any thoughts on who is the best to go with?
Patrick
|
|
|
|
|
I doubt anyone has a "best of" list... We use a VeriSign code signing certificate, and are happy with it. It works.
I am not sure what else can be said about it.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~<br />
Peter Weyzen<br />
Staff Engineer<br />
<a href="http://www.soonr.com">SoonR Inc -- PC Power delivered to your phone</a>
|
|
|
|
|
Whichever authority is recognized automagically by the browser/OS is best.
Otherwise, you may as well make your own certs (which works fine too).
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
we just got one from Comodo, this weekend. the process was pretty easy (after a couple of rounds of verification).
they didn't provide any tools, since the things you need (basically just SIGNTOOL.EXE) are all part of MS's SDKs.
|
|
|
|
|
FWIW - I second Comodo. I have a CS cert from them as well and am very happy with it.
Peace!
-=- James Please rate this message - let me know if I helped or not!<hr></hr> If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong! Remember that Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road! See DeleteFXPFiles
|
|
|
|
|
Hi,
I'm presently coding a driver for Windows XP and I'm having an issue: how to detect the keyboard layout?
Actually I need to detect if my driver is running on a computer with an azerty or qwerty keyboard. The best would be to be able to detect the keyboard layout for the current process. I know the GetKeyboardLayoutName API, but I have no idea what would be the equivalent in kernel mode if there is one...
Does someone know how to do that?
Regards
|
|
|
|
|
i never used, a little search on msdn gives,
Manthis wrote: The best would be to be able to detect the keyboard layout for the current process.
HKL GetKeyboardLayout( DWORD idThread
); per thread, its more granular than current process.
Manthis wrote: I have no idea what would be the equivalent in kernel mode
and in wince it has corresponding MDD driver function
typedef HKL (*PFN_LAYOUT_MGR_GET_KEYBOARD_LAYOUT)(
DWORD idThread
);
i think there should be something similar in windows also
modified on Tuesday, February 19, 2008 11:28 PM
|
|
|
|
|
Well I knew these two functions but I'm pretty new to driver developpement, and I'm can't find their equivalent for windows kernel developpement.
I might I've found a hint with this request: IOCTL_KEYBOARD_QUERY_ATTRIBUTES, but I'm really not sure.
Can someone confirm?
|
|
|
|
|
|
Hi,
I have some function that get void* param.
And i want to send CString object.
So - this is my code - and i don't see any reason that my CString would not work when i doing casting back from void* to CString.
<br />
CString sStr("SomeString")<br />
Foo(void*(&sStr) );
<br />
void Foo(void* p)<br />
{<br />
CString __sStr = *(CString*)p;
}<br />
Thanks for any help.
|
|
|
|
|
Actually your code, though not beautyful, works.
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
|
|
|
|
|
Yanshof wrote: CString sStr("SomeString")
may be the objects life time is not in the scope.
Yanshof wrote: void Foo(void* p)
{
CString __sStr = *(CString*)p;
string is copied to __sStr, is for this purpose u troubled urself to pass as pointer. instead u can pass by value;
personally i prefer reference in this situation.
void Foo(CString &str);
|
|
|
|
|
Rajkumar R wrote: personally i prefer reference in this situation.
void Foo(CString &str);
Actually the recommended way is to pass as a LPCTSTR and return as a CString, see here[^]
Peter
"Until the invention of the computer, the machine gun was the device that enabled humans to make the most mistakes in the smallest amount of time."
|
|
|
|
|
good link dude but when i just opened my eyes looks this,
"If a string is an input to a function, in most cases it is best to declare the string function parameter as LPCTSTR. Convert to a CString object as necessary within the function using constructors and assignment operators. If the string contents are to be changed by a function, declare the parameter as a nonconstant CString reference (CString&)."
that if u want to modify a CString, CString &.
LPCTSTR is for const readonly object. And i don't see it is the recommended way, it is one of the way.
when i want to pass the readonly object to a MFC C++ function, i prefer "const CString &" than LPCTSTR as it requires to call constructor and destructor additionally to get a CString Object and i try to avoid it.
offcource, if i want to pass to a C function, that is not aware of CString, then LPCTSTR or LPTSTR is the fit.
|
|
|
|
|
Yanshof wrote: CString sStr("SomeString")
Maybe it's the missing semicolon.
Yanshof wrote: Foo(void*(&sStr) ); //call the function
Or the missing parenthesis.
Other than that, your code works fine in VC6.
"Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Hi experts,
I have retrived all files and folders from RecycleBin. How can I make a path so that I can open handle for Recycle Bin files.
|
|
|
|
|
The recycle bin isn't a *real* folder, so therefore the "files" in it are not real - so no handle to read from them.
They're *deleted*...
That said, I'm sure there's some undelete shell method, but it may only put them back in their original location with original permissions. I'd suspect any other way would be a security hole. You put "sandras secrit diary" onto FAT32 memory stick, and be able to read all about her affair with Brad. And that would be BAD.
If you haven't already discovered it, the following article may be of some use to you.
http://www.codeproject.com/KB/shell/recyclebin.aspx[^]
That said, I haven't yet found an "undelete" interface with a quick google.
Have a look at:
http://answers.yahoo.com/question/index?qid=20070722094025AAk7DJ3[^]
It gives a load of information that could be handy for you.
Iain.
Iain Clarke appearing in spite of being begged not to by CPallini.
|
|
|
|
|
Hello All
I am developing Activex Application in which i want to use shockwave flash control.
I can use it in simple dialog based application.
i can successfuly display a dialog box in activex control, But when i add shockwave flash control to my dialogbox it is not displying even dialog and doesen't give any error
So is there anybody who can solve my problem?
Any help would be highly appriceated.
Thanks
Manish Patel.
B.E. - Information Technology.
|
|
|
|
|
These links may help you:
Tutorial at BytesCount[^]
Flash Gui[^]
Nobody can give you wiser advice than yourself. - Cicero
.·´¯`·->Rajesh<-·´¯`·.
Codeproject.com: Visual C++ MVP
|
|
|
|
|
Thanks for your reply.
As above article shows, i can also diplay swf in dialog based application
But the problem is with avtivex control.
I am giving my steps to add sockwave flash cntrol
1 -> i have created MFC ActiveX control application
2 -> Then i have added one dialog to it.
3 -> Added Class for that dialog
4 -> In OnCreate method of activex control i had make onject of the dialog class and call DoModel()
method of it.
5 -> When i run only this code it will display a Dialog box to me.
6 -> Now if i add shockwave flash object to this dialog box from tool box and run it, it will not
Diplaying dialog box to me. Right now i have not provided swf to shockwave flash control.
Now hope so You will understand my problem.
Is there any solution for me?
Thanks in advance
Manish Patel.
B.E. - Information Technology.
|
|
|
|
|
add AfxEnableControlContainer() to the constructor of your dialog
|
|
|
|
|
I would appreciate anyone help me out here.. I have 2 tools that are supposed to open a file called RSC0000.RSB, this file keeps all the text in a game for the client to use..
1 tool is outdated, the other one is designed for this version (Ressurection) and for some reason, it errors out when you set the password to RESSURECTION and try to open the RSB
If anyone can help me out, please, let me know
Shissar@gmail.com
http://www.mediafire.com/?11e2emujwnh[^]
There is the download link to the files & tools, please check it out, I'd appreciate any help fixing the tools.. they dont work...
|
|
|
|