|
followait,
Do you get runtime error or error you assign values to m_pBuf and then push_back but i dont get any error?
can you show error,please?
whitesky
|
|
|
|
|
I have a MFC application compiled as "Static library". This exe works fine in machines with Visual Studio. But when moved to another PC without Visual Studio ..it doesn't work as supposed to be. No error is throwed.
MFC is compiled " Static Library"..
Pls help what else is missing
Suganya.
|
|
|
|
|
see previous post maybe it is some helpful to you
whitesky
|
|
|
|
|
Check whether there is any dependecies with any other DLL using dependency walker. it is available with Visual Studio.
SaRath
|
|
|
|
|
When you run the application in PC without Visual Studio .. what is the message you are getting.
Nice talking to you.
If you judge people, you have no time to love them. -- Mother Teresa
|
|
|
|
|
When i run the application in PC without Visual Studio,i am not getting any messages.
The Dependencies were verified on the developement pc.all the misssing dll's are moved but still it is not working.
|
|
|
|
|
Are all required DLLs present and registered correctly? Are you using any ActiveX controls?
"The largest fire starts but with the smallest spark." - David Crow
|
|
|
|
|
Hi Friends,
I have created an EXE File in VC++.The Exe Works fine since i am having VC++ installed in my machine.But i copied the Exe File to another machine where VC++ is not installed,there EXE doesnt work.
What is the reason for that,is there any possibility for it work.
Regards,
Ruban.
|
|
|
|
|
Try creating the exe in release mode..
If that too fail use Dependecny Walker in the other mechine to find the missing dlls
nave
|
|
|
|
|
k.n.ruban wrote: I have created an EXE File in VC++.The Exe Works fine since i am having VC++ installed in my machine.But i copied the Exe File to another machine where VC++ is not installed,there EXE doesnt work.
What is the reason for that,is there any possibility for it work.
Use Dependency Walker to find out what all dll's does your application depend on. When you take your app to new location you have to have these dependent dll's there too else the application won't work.
Nibu thomas
A Developer
Programming tips[^] My site[^]
|
|
|
|
|
I dont know your code also what is it?
sometimes you need to these files
mfc71d.dll msvcp71d.dll msvcr71d.dll
of course this is not always and it maybe depend to your code
whitesky
|
|
|
|
|
Hi Friend,
We tried by putting the missing dll files from the dependencies and we registered.But still it didnt work is there any other way.
Regards,
Ruban
|
|
|
|
|
whats type your application do you use from services in your program?
whitesky
|
|
|
|
|
Suggestion: ( May be it will work)
If your EXE is not dependent on any DLL after watching in "dependancy walker" , then i think you should build EXE in Release mode and build it using Statically Link Libraries.
Regards.
|
|
|
|
|
Hi Friend,
We tried the same way what u have mentioned but it still didnt work.
We got the dll from dependencies that are missing and pasted in the the machine where we tried Executing the Exe file but still it didnt work.
Is there any way.
Regards,
Ruban
|
|
|
|
|
Hello, everyone.
I'm currently working on a project for which I need to update some UI elements based on networık messages...
For the UI, for simplicity, I've chosen to use DHTML and for now most things are working as expected... Except for one: JavaScript calls!
Actually, all examples where you use a UI button for a JavaScript call work; but when a call is done without any button being pressed, there's an error!
One other project actually does a JavaScript call when window loading is complete. To simulate my problem, I downloaded the project from http://www.codeproject.com/dialog/web_gui/Reusing_DHTML_example.zip and in Dlg4.cpp changed the last method into
<br />
DWORD WINAPI CallJScriptLater( LPVOID lpParam )<br />
{<br />
CHtmlCtrl* a = (CHtmlCtrl*) lpParam;<br />
<br />
Sleep(5000);<br />
<br />
CStringArray strArray;<br />
<br />
<br />
strArray.Add("Picture@500");<br />
strArray.Add("Video Clip@200");<br />
strArray.Add("Some more@50");<br />
<br />
strArray.Add("File Document@1708@201");<br />
<br />
a->CallJScript2("SetParameters", strArray);<br />
<br />
return 0;<br />
}<br />
<br />
void CDlg4::_onDocumentComplete(){<br />
<br />
CHtmlDialog::_onDocumentComplete();<br />
<br />
CreateThread( NULL, 0, CallJScriptLater, &m_HtmlCtrl, 0, NULL);<br />
}<br />
So, instead of calling the JavaScript directly it calls it five seconds later...
When you launch it, five seconds later, you receive an error message; and the JavaScript doesn't work!
Would anyone have an explanation and / or a fix for this problem?
Thank you
S. Ali Tokmen
http://ali.tokmen.com
|
|
|
|
|
Hello
I've received a reply saying that the function is probably false.
Actually, if you replace
CreateThread( NULL, 0, CallJScriptLater, &m_HtmlCtrl, 0, NULL);
with
CallJScriptLater( &m_HtmlCtrl );
It just works perfectly back again!
So, calling JavaScript from a seperate thread is impossible
Can anyone help me about this issue?
Thank you
S. Ali Tokmen
http://ali.tokmen.com
-- modified at 16:10 Thursday 25th May, 2006
|
|
|
|
|
Hi,
I have to disable the menu.
For Example:my menu is like this..
File Insert Panel Help
like this..I have to choose two different functions in a dialog.If i choose A,the Panel menu should enable..If i choose B then pane lenu shuld get disabled.
Wat can i do for this.
|
|
|
|
|
you need to change menu?
whitesky
|
|
|
|
|
Anu_Bala wrote: I have to disable the menu.
For Example:my menu is like this..
File Insert Panel Help
like this..I have to choose two different functions in a dialog.If i choose A,the Panel menu should enable..If i choose B then pane lenu shuld get disabled.
Wat can i do for this.
You have to add an ON_UPDATE_COMMAND_UI handler for these menus and update these menus based on flags that holds the state for these menu items.
Nibu thomas
A Developer
Programming tips[^] My site[^]
|
|
|
|
|
as nibu said, u can do ths in ON_UPDATE_COMMAND_UI function.
First get the menu bar using GetMenuBar() function.
then select the Sub menu using the required index.
Disable menu item by EnableMenuItem function by setting MF_GRAYED and MF_DISABLED flags.
hope this helps.
SaRath
|
|
|
|
|
SaRath C wrote: EnableMenuItem function by setting MF_GRAYED and MF_DISABLED flags.
This won't work here. It will get overridden in the ON_UPDATE_COMMAND_UI handler. MFC does it in a different way.
Nibu thomas
A Developer
Programming tips[^] My site[^]
|
|
|
|
|
You can do like this
CMainFrame::OnUpdateYourFunction(CCmdUI *pCmdUI)<br />
{<br />
if(A)<br />
pCmdUI->Enable(TRUE);<br />
else<br />
pCmdUI->Enable(FALSE);<br />
}
Appu..
"If you judge people, you have no time to love them."
|
|
|
|
|
Hello everyone,
I usually link with .lib file and when program executes, it will look for .dll file to load real function implementations.
I heard that it is possible to link with .lib file and the program can run without .dll file (.dll file needs not be generated and not needed at all during program execution). Is that correct? If it is, could anyone introduce some online tutorials about this topic?
thanks in advance,
George
|
|
|
|
|
There are two types of Linking 1.Static 2.Dynamic
George_George wrote: heard that it is possible to link with .lib file and the program can run without .dll file (.dll file needs not be generated and not needed at all during program execution). Is that correct? If it is, could anyone introduce some online tutorials about this topic?
Check this article for more info,
http://www.codeproject.com/dll/XDllPt4.asp[^]
Appu..
"If you judge people, you have no time to love them."
|
|
|
|