|
it is a mfc extension dll and the dialog is located in this dll.
|
|
|
|
|
Frank Conrad wrote:
it is a mfc extension dll and the dialog is located in this dll.
For dialogs in extension dlls, you either need to make sure your dialog IDs don't overlap with the executeable programs resource IDs (which keeps you from reusing your extension dll), or keep track of the dll instance handle, explicitely load your dialog from the dll, and use CreateIndirect to create your dialog. Have you done either?
Nathan Holt
|
|
|
|
|
You call FreeLibrary immediately after calling the dll function. If the modeless dialog is still shown you have just snatched away its comfort blanket!
The opinions expressed in this communication do not necessarily represent those of the author (especially if you find them impolite, discourteous or inflammatory).
|
|
|
|
|
in the dll i have a dialog which is non-modal:
extern "C" __declspec(dllexport) __cdecl Test (int tst) {
Dlg_Test* dlg;
dlg->Create();
}
but the dialog calling crashed.
the dialog pointer is not valid before ur calling create function on the pointer. That should be done hopefully the following way
Dlg_Test* dlg;
dlg = new Dlg_Test();
dlg->Create();
Hope the above works.... otherwise problem would be with the actaul dialog resource.
Gudluck
Adi
|
|
|
|
|
i want to know how to use vbcrlf function in vc++.
How to get New line message in vc++.
I want to new line in Editbox.
|
|
|
|
|
Hi,
Enable multiline and vertical scroll property in the normal edit controls properties window. To go to next line use CTRL+ENTER
Sujan
|
|
|
|
|
and to actually display text with a crlf, use "\r\n" within your string. For example:
in VB you would enter the following:
"FirstName" + vbcrlf + "LastName"
to get
FirstName
LastName
In C++:
"FirstName\r\nLastName"
for same results
[insert witty comment here]
bdiamond
|
|
|
|
|
hi all,
I want to Compile the Samples of the SDK "RTC Client APIv 1.2".I have tried several times according to the readme file..But it would not succeed YET.How do I do that?..So please any one know about Real time Communication(RTC) SDK and samples,please send me a reply.
Thanks in advance..
|
|
|
|
|
Hi,
I am developing a Audio Codec. To check the performance of my program i need to know the Machine Cycles consumed by each functions in my program.
Is there any tools/settings in MSVC++ to know the "Machine Cycle" of all functions in my program ?
Thanks in advance.
Regards,
-Victor.A
|
|
|
|
|
Well not sure I completely understand what you want but you might try using the QueryPerformanceCounter and QueryPerformanceFrequency API's.
¡El diablo está en mis pantalones! ¡Mire, mire!
Real Mentats use only 100% pure, unfooled around with Sapho Juice(tm)!
SELECT * FROM User WHERE Clue > 0
0 rows returned
|
|
|
|
|
No, I am actually looking for some settings in the project or profiler kind of tool.
|
|
|
|
|
I use mouse wheel in my application to alter the size of a square in my view. I use ON_WM_MOUSEWHEEL() to catch the wheel messages.
Everythin worked just fine, untill I upgraded to XP. Now I get ON_WM_VSCROLL() messages instead, and never see the wheel messages when the scrollbar is on.
I want to find a way to bypass the scrolling and have wheel messages instead, how?
Thanks
Jesper
|
|
|
|
|
Hello, I have made a php script that uploads a file to your server, then I made this feature available from a c program by tricking the php into believing that the upload button has been pressed with the use of a text encoded with mime. I have apache installed on my comp with php php 4.4 and on my comp this works but on this server of a friend:
FreeBSD Apache/1.3.31 (Unix) mod_ssl/2.8.18 OpenSSL/0.9.7d FrontPage/5.0.2.2635 PHP/4.3.6 mod_throttle/3.1.2
note php 4.3.6
it doesn't anyone know why
I could provide source code if needed.
|
|
|
|
|
I created a simple application that contains a text field (member variable CString m_Data)and OK button
When user clicks OK button the file text.txt is read.
text.txt contains
LINE 0
LINE2
LINE3
LINE4
How can I skip the first line and display the second line in the text field ? (e.g LINE1)
Is there a better way?
Idealy what I want is to load second line then user clicks next and the third line is loaded and so on
I tried this but it does not skip first line
///////////////////////////
CFile cf;
if(cf.Open("text.txt",CFile::modeRead))
{
int nFileSize = cf.GetLength();
char * lpBuffer = new char [nFileSize+1];
cf.Read(lpBuffer,nFileSize);
m_Data = lpBuffer;
delete []lpBuffer;
}
else
{
MessageBox ("not loaded","Can not open file", MB_OK);
}
}
Any help will be greatly appreciated
|
|
|
|
|
Hi,
Check for netline(return) char and get the text and display it.
Sujan
|
|
|
|
|
Use the CStdioFile MFC class. It is derived from CFile and it handles individual text lines, automatically handling newline and return feeds.
I think it only has the ReadLine() and WriteLine() functions.
I Dream of Absolute Zero
|
|
|
|
|
Hi all MFC Gurus,
I read Article " MSLU: Develop Unicode Applications for Windows 9x Platforms with the Microsoft Layer for Unicode". It helped me to create an Unicode application for 9x platform. But I have one problem when I use MFC.
The problem is as follows:
I have created an MFC application that links to MFC as shared DLL. The application is UNICODE application. I have configured the application as per the specifications given by microsoft. I have ported "Unicows.dll" also. But it does not work on 98. It displays a runtime error. If the same application is configured to link with MFC dll statically, then it works on 98. The only error occurs if the application is configured to link mfc as shared dll. I am not able to solve the problem.
I found only couple of articles on this issue but still after following steps given unicows.dll was not loaded in the MFC application and it is ending with Runtime error.
In case of same application compiled in debug mode, it was causing ASSERT in auxdata.cpp line 41, 45..
These are loading of WAIT_CURSORS statements. May be some resource conflicts and application can not start properly.
I hope some of you must have this problem and please share your views and workarounds on this issue.
Waiting for reply
Regards
Prithvi
Prithvi
|
|
|
|
|
hi i am trying to instert several menu items that are popup and the corresponding popup menus i can add a menu item but the MF_POPUP flag doesnt seem to do the trick can anyone give me some pointers on how to do this?
thanks
|
|
|
|
|
|
In my project, there is a Static text where I put a Timer on it.
And I want to set the color of this Static Text is TRANS_BACK.
But I don't know how to do.
Please help me.
Thanks.
King of Merit
|
|
|
|
|
Hi,
Can do it by adding the OnCtlColor. Have a look @ the msdn for OnCtlColor. They do provide a sample code too.
Sujan
|
|
|
|
|
|
Hi Friends,
I am working with a multithreaded application. The problem which i am facing is sometimes the application shutdown is not proper (seems that the application is in waiting state). I am using CriticalSection also for data sync. Is there any tool which shows the current thread status..etc.
Sujan
Note: i do have the process explorer from sysinternals.com. In the process viewer it is showing that the application is waiting on the ntdelayexecution thread.
|
|
|
|
|
Are you using WaitForX (Single Object, MultipleObjects) or MsgWaitForX (same thing) at all? More than one critical section, leading to a deadlock situation?.
Otherwise, your applciaiton wants to exit, but one or more of your threads are still blocked waiting for a mutex, event, etc. You should design your threads to wait for MORE than one object, typically the processing object, and an event object you can 'set' from the main thread when the program is about to exit. Then when progrma is about to exit, it signals event for thread(s) to exit, waits for thread(s) to exit, and then the main program's thread can exit.
How do you detect that a thread has exited? The thread can set an event the main thread is waiting on, the thread can clear/set a variable the main thread can check, or main thread can wait for thread handle to be signaled. see documentaiton for _beginthreadex
|
|
|
|
|
Hi,
Here is the scenario:
I have an app which uses CFileDialog to select a file.
All i am really doing with the file is getting the name, its path and extension.
I have an executable (call it myexec)in the directory my app is in, which must be run from that directory as it uses dlls which are there too.
I take the file name (full path) i select and build a command string like "myexec filename-with-full-path" and run it using the system() routine.
It works fine if i choose a file from the home directory of my app but if i chose one from another directory, it fails because it cannot find the executable "myexec".
I am presuming the changing of directories in the CFileDialog control has altered the working directory of my app and if this is so i do not know how to reset it without another call to CFileDialog and returnng to the home directory from within that.
I hope this is not too confusing...I tried to explain it as best as i could...confusing me a little too...
Thanks,
Sean
Firefly, Stargate, Farscape: in that order
|
|
|
|