|
ForNow wrote: Then the follwing code is the on okay handler to this modal dialog box
void Cprogdialog::Process() So Process() is being called from OnOK() ? Why are you wanting to browse for a file when the "main" dialog is being dismissed?
ForNow wrote: dlg.m_ofn.lpstrFile = new char[50]; I do not see how this is going to work.
ForNow wrote: dlg.m_ofn.lpstrFilter = (LPCTSTR)"*.asm,*.cbl,*.c"; Have you read the docs for this member? It must be double null terminated.
"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"Show me a community that obeys the Ten Commandments and I'll show you a less crowded prison system." - Anonymous
|
|
|
|
|
Okay i'll re-read the docs
I have a modal dialog box open to gather info
1 of the pieces of info is a file name so......
as soon as the user hits "OK"
I look for the last piece of info which a file thus the need to invoke CFileDiaog from the OKHANLDER of the first dialog box
you right I'll re-read the doc
|
|
|
|
|
ForNow wrote: I have a modal dialog box open to gather info 1 of the pieces of info is a file name so...... as soon as the user hits "OK" When the user clicks the OK button, they are expecting to be done, not be presented with yet another dialog box. The OK button should not be available to click until all required information has been collected. It sounds like what you need is a Browse button to allow browsing for the file name.
"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"Show me a community that obeys the Ten Commandments and I'll show you a less crowded prison system." - Anonymous
|
|
|
|
|
I applogize
I have ON_COMMAND(IDC_PUSH,process)
In the message map
in the resource file I have DEFPUSHBUTTON IDC_PUSH
I haven't overriden CDialog::OnOk
I haven't defined a button with a ID of IDOK
maybe I should re-do the modal dialogbox as a modaal with DEFBUTTON of IDOK
since one the pieces of info i need is a file is omay in my OnOk overrride to invoke CFileDialog
to prompt the user for the file name?
Thanks
|
|
|
|
|
ForNow wrote: since one the pieces of info i need is a file is omay it okay in my OnOk overrride to invoke CFileDialog to prompt the user for the file name? I would disable the OK button until all required information has been provided.
"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"Show me a community that obeys the Ten Commandments and I'll show you a less crowded prison system." - Anonymous
|
|
|
|
|
|
For what? What does Hans' article have to do with the title of this thread?
"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"Show me a community that obeys the Ten Commandments and I'll show you a less crowded prison system." - Anonymous
|
|
|
|
|
Instead of opening a second modal dialog box I'll add my controls to CFileDialog
|
|
|
|
|
Creating a proper main dialog with a "browse" button that opened a CFileDialog would be way simpler.
"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"Show me a community that obeys the Ten Commandments and I'll show you a less crowded prison system." - Anonymous
|
|
|
|
|
What's the exception (specifics)?
"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"Show me a community that obeys the Ten Commandments and I'll show you a less crowded prison system." - Anonymous
|
|
|
|
|
Hi,
I just got to work now but just before I left I re-built the code with only
CFileDialog dlg(TRUE);
one paramter as everybody was telling me I have problems wih my parms
as soon as I try stepping over dlg.Domodal();
I get a break point "int 3" some system DLL then entering PF5 "GO" again I get an access exception
I have a related question since I am creating the modal dialog box inside a modal dialog OKHANDLER what is the parent window the first modal or the MainWindow
Thanks
|
|
|
|
|
ForNow wrote: one paramter as everybody was telling me I have problems wih my parms So why not take my advice, read the documentation, and fix the incorrect parameters? Unless and until you properly address the things that are obviously incorrect you are not going to make any progress finding the problem.
|
|
|
|
|
ForNow wrote: CFileDialog dlg(TRUE); one paramter as everybody was telling me I have problems wih my parms as soon as I try stepping over dlg.Domodal(); What about the OPENFILENAME structure?
ForNow wrote: as soon as I try stepping over dlg.Domodal(); Does the Open dialog display, or is the exception thrown first?
ForNow wrote: I have a related question since I am creating the modal dialog box inside a modal dialog OKHANDLER what is the parent window the first modal or the MainWindow What exactly are you talking about here?
"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"Show me a community that obeys the Ten Commandments and I'll show you a less crowded prison system." - Anonymous
|
|
|
|
|
The program takes the input of an initial key and an initial
vector, reads the plaintext or ciphertext from a file, conducts the encryption or
decryption, and writes the resulting ciphertext or plaintext into a second file.
test case is as follows: using a binary initialization vector of 10101010, a binary plaintext
of 00000001 00100011 encrypted with a binary key of 0111111101 should give a binary
ciphertext of 11110100 00001011. Decryption should work correspondingly.
|
|
|
|
|
Please do not post your homework questions here; no one is going to do your work for you.
|
|
|
|
|
When we are browsing for our library files which have extensions of .pal using CFileDialog we are also getting .palx displayed in the dialog.
This did not happen when we were using VC2003 but happened when we moved to VC2010.
Any ideas how to stop this behaviour as we generate the .palx files from our .pal libraries and we do not want users selecting the .palx
|
|
|
|
|
Check that your search filters are correct.
|
|
|
|
|
One of the constructors to the file dialog class permits you to specify a list of file extensions the dialog is permitted to show, check the documentation for more clarity, hope this helps.
The tears shed in vain
and the hatred and pain
will be nothing but dust
at the end of the day
|
|
|
|
|
Hi
We have implemented the functionality of "What's this" help button in our MFC code.
When select "What's this" help menu and press any control then help is displayed properly; but while click on the buttons of the toolbar, windows message
"Windows.hlp file is not found. Will you locate /specify the file by yourself" with Yes and No button appeared.
After some time message disappears automatically.
And We also do not found windows.hlp at our system.
We have facing this issue at windows 7 (KB917607 is applied) and at windows XP while trying to display the help message at same toolbar button help displayed successfully.
Thank You
Ashish Kumar verma
Software Engineer(VC++)
|
|
|
|
|
Software developer with 10 years experience in developing desktop applications using C/C++,VC++,Qt,OpenGL for CAD/CAM/CAE/CFD applications. Call Sujan @ +91-8420921887/+91-9163437906. skype: 'sujan.dasmahapatra' , email : 'appollosputnik@yahoo.com'
website : http://www.sujantechnologies.com/
|
|
|
|
|
hi,
I want to execute java exe by passing arguments in VC++ 2010.
I have tried shellExecute, but it is not working.
Can any one please help me.
Thanks in advance. 
|
|
|
|
|
IICTECH wrote: but it is not working. Please do not expect people to guess what is happening on your system. Show the relevant portion of your code and explain what happens when you run it.
|
|
|
|
|
I want to integrate java with c++. I already created java exe called
IKRYSignENC.exe .
I have to pass command line arguments to execute this exe.
For that,I have used shellExecute as follows
ShellExecute (NULL, "open", "D:\\IKRYSignENC.exe", "D:\\NSRM3443\\Test\\ch21\\ENC_ROOT\\IN121MTM.000" "C:\\CASM_IKRYPT_JAVA\\Support\\Inputs\\CellKeys.txt" "D:\\", NULL, SW_SHOW);
It is compiling with out any errors, but while running it is giving the error like
Loaded
Unloaded
Can any one please suggest me the correct usage of shellExecute. 
|
|
|
|
|
How did you create this .exe file? Java normally produces .class or .jar files.
|
|
|
|
|
I think there is a problem in the command line arguments you are passing to the executable in the ShellExecute Function. This should be one string something like:
"D:\\NSRM3443\\Test\\ch21\\ENC_ROOT\\IN121MTM.000 C:\\CASM_IKRYPT_JAVA\\Support\\Inputs\\CellKeys.txt D:\\"
You talk about Being HUMAN. I have it in my name
AnsHUMAN
|
|
|
|