|
Cheers, i wasn't entirely clear on whether the Mutex would self release after a Process exits from a catastrophic failure.
-------------------------------
Carrier Bags - 21st Century Tumbleweed.
|
|
|
|
|
If nobody owns up for a mutex (orphaned), the OS immediately closes it. Also, locked file idea suggested in the docs may not be very helpful if you want your application to be truly one-instance (across logins). But, in such a case, only a kernel object (like Mutex) can help you.
It is a crappy thing, but it's life -^ Carlo Pallini
|
|
|
|
|
hi, i created a custom MFC dialog box, and I need to call it in a function in a dll file, but when i call it it keeps saying IDD_BOX undeclared identifier, even though i've included the dialog box's header file. how do i call a dialog box in a dll file?
|
|
|
|
|
Are you sure that IDD_BOX is really defined?
You need to google first, if you have "It's urgent please" mentioned in your question.
_AnShUmAn_
|
|
|
|
|
yes because the dialog box app compiles and runs by itself without any errors? so its defined there and working
[edit] ok its compiling now, all I did was repalce the #include ...filedlg.h with #include ....filedlg.cpp, and am not getting the erorr anymore. will see if its running properly once I create a test file using that dll. thanks for the help for now _AnsHUMAN_. if you have anything to add regarding this, please do so that I may know what you had in mind [/edit]
modified on Thursday, July 16, 2009 7:41 AM
|
|
|
|
|
Hello,
When I run my program in debug mode that is by pressing F5 the program runs properly and the text or windows which are to be seen are seen on the view but when I press Ctrl F5 and execute the program the text or windows are not seen on the view.
What must be the problem ?
pritha
|
|
|
|
|
read this : Surviving the Release Version[^]
and go back to your source-code, re-check everything and come back when you have more precise information and/or small source code extract that shows the problem.
This signature was proudly tested on animals.
|
|
|
|
|
Well, in my computer it's a reverse situation, I use VS2005.
Ctrl+F5 means execute without debuging, and text or windows could be seen.
F5 means debug, and press it text or windows couldn't be seen.
|
|
|
|
|
It's quite possible that the working directory is different for the F5 and Ctrl-F5 run.
If you are opening any files be sure those files exst - best way is to supply a complete path name to your open routines, not just the filename.
Hope that helps.
Karl - WK5M
PP-ASEL-IA (N43CS)
PGP Key: 0xDB02E193
PGP Key Fingerprint: 8F06 5A2E 2735 892B 821C 871A 0411 94EA DB02 E193
|
|
|
|
|
|
Hi all!
I want to design and implement an e-voting(electronic voting) system with two computers(one as server and the other as client) under windows;
What technology or programming model do you suggest me for this purpose?
I'm not familiar with network programming models in windows and need help of experience people!
One guy have suggested me to create an ActiveX on client and communicate with server through COM, what do you think about it?
Please help me!!!
Best Regards.
|
|
|
|
|
Personally, I'd probably approach it by exposing a web-service[^] interface on the server that the client could use.
I wouldn't use COM because I've heard too many painful things about configuring COM to work across multiple machines. But that's just my prejudices
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
i have created a dialog and the dialog font size is different with my friend (all the setting in a property page is totally the same). Have anyone face this problem before?
|
|
|
|
|
He might be using different Font (DPI) settings.
|
|
|
|
|
Thank for the reply.
I make mistake in here. I din mention that the font i use is all in capital latter. that why mine font is biggest than my friend..sorry..
|
|
|
|
|
Hello,
is it possible to create an object with the CRuntimeClass-pointer and call a specific constructor during the creation, similar to the function new?
Maybe I can combine the CRuntimeClass-pointer with the funktion new?
CRuntimeClass* pRTC
CObject* pOb = pRTC->CreateObject();
CObject* pTestObj = new CTesObj( 5 )
|
|
|
|
|
If CTesObj is derived from CObject, then "CObject* pTestObj = new CTesObj( 5 )" is what you want.
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
Thank you for your answer, but my problem is another one:
CTestObj ist derived from CObject.
So I can create the objekt with new, like
"CObject* pTestObj = new CTestObj( 5 )"
But I will create the object with the runtimeclass-pointer (CRuntimeClass* pRTC).
This pointer knows the type of the class and I can create the object with the
CreateObject-function.
CObject* pObj = pRTC->CreateObject();
The CreateObject-function calls the standard-constructor.
Can I call another constructor during creation with runtimeclass-pointer?
The next line did not compile but maybe you can modify it:
CObject* pMyObj = new pRTC( 5 );
At the time of creation, I only know the runtimeclass-pointer and the transfer
parameter (5).
In my program the transfer parameter is a big class. So I will save time during creation.
Do you have an idea?
|
|
|
|
|
Good morning ,
got a question to the following code piece which converts ansi text to UTF8.
void SynthesizerSvox::ANSI2UTF8( char* text, int size, char*& result )
{
const int SIZE = 10240;
if( result )
{
delete [] result;
}
result = new char[SIZE];
WCHAR w[SIZE]={0};
int erg=0;
erg=MultiByteToWideChar(CP_ACP, 0, text, -1, w, SIZE / sizeof(WCHAR));
erg=WideCharToMultiByte(CP_UTF8, 0, w, -1, result, SIZE, 0, 0);
}
I found the code somewhere on the net (thanks!) and it works nicely. Only I´d like to work with dynamic memory allocation (don´t like to limit it) and can´t seem to get it done. The number of bytes used per character vary in UTF8 character set.
Is there a solution to this?
Souldrift
|
|
|
|
|
Souldrift wrote: nd can´t seem to get it done.
Why?
Souldrift wrote: The number of bytes used per character vary in UTF8 character set.
Yes, but WideCharToMultiByte is able to tell you how many bytes are required (MSDN [^]):
cbMultiByte [in]
Size, in bytes, of the buffer indicated by lpMultiByteStr. If this parameter is set to 0, the function returns the required buffer size for lpMultiByteStr and makes no use of the output parameter itself.
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]
|
|
|
|
|
Hm, good point. Thanks for reminding me of my ability to read ... it worked .
Cheers
Souldrift
|
|
|
|
|
Hi,
I am using VC++ . I want to access remote machine and then peroform functions like
1- View the applications of remote machines by clicking on the start of local machine
2- Select any application such as MS word of the remote machine by using mouse
3- Close the application by using mouse.
I guess technically I have to access the remote machine explorer.exe at my local machine.
How this stuff can be acomoplished in VC++? any idea
I would appreciate the guidance.
|
|
|
|
|
Ahmad99 wrote: Hi,
I am using VC++ . I want to access remote machine and then peroform functions like
1- View the applications of remote machines by clicking on the start of local machine
2- Select any application such as MS word of the remote machine by using mouse
3- Close the application by using mouse.
I guess technically I have to access the remote machine explorer.exe at my local machine.
How this stuff can be acomoplished in VC++? any idea
The free edition of RealVNC[^] is open source. I was forced to hazard a guess of what you're trying to achieve, but I also think that you've not had a chance to read the guidelines[^] in your 7+ years here?
Also, a there is a comparison of remote desktop software[^] (you may see what is open source, and what might suit your needs)
It is a crappy thing, but it's life -^ Carlo Pallini
|
|
|
|
|
|
Madhu_Rani wrote: thanks
That's what I see here now, but what I received in the email notification was entirely different! You've changed it immediately after posting to appear innocent.
If you don't have the nerve to make a comment publicly, you might as well hide under that same hole where you were. You want to know what I think? I think that you are a complete idiot. You are clearly in no position to assess anybody's contributions here.
It is a crappy thing, but it's life -^ Carlo Pallini
|
|
|
|