|
toothless boots wrote:
I was just wondering how I could get access to the command line arguments in MFC? I know in C it would have been the argv[] parameter in the main, but I don't know how to get that in MFC.
MAY BE THIS CLASS WILL HELP YOU class CCommandLineInfo
-----------------------------
"I Think It will Work"
-----------------------------
Alok Gupta
visit me at http://www.thisisalok.tk
|
|
|
|
|
toothless boots wrote:
I know in C it would have been the argv[] parameter in the main
You can still use __argc and __argv . From the application object, you have access to the m_lpCmdLine member.
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
My Q is for both VS 6.0 and .NET.
One of my projects has up to 50 classes. Is there some way to organize the classes like for e.g. the way I do with files and folders in windows explorer?
Thanks
_____________________________
...and justice for all
APe
|
|
|
|
|
Right-click the project, select New Folder. Name the folder. Start dropping classes into it.
In VS 6.0, the folder structure is stored entirely in the workspace .opt file (.vco if you're using eMbedded Visual C++).
Visual Studio .NET's folder structure exactly matches the on-disk structure. You can't create folders in Class View, but you can create folders in the Solution Explorer. The Class View can be organised by namespace; it represents the logical, not the physical, view of the code. Often it's a good idea to match namespaces and disk folders.
Stability. What an interesting concept. -- Chris Maunder
|
|
|
|
|
You mean the way you do with packages in Java?
Thanks
_____________________________
...and justice for all
APe
|
|
|
|
|
I have created a Pagesetup dialog object like this:
CPageSetupDialog psd( PSD_INTHOUSANDTHSOFINCHES | PSD_MARGINS |
PSD_ENABLEPAGEPAINTHOOK, this );
Normally In the Oriantation part in the Setup dialog,defaultly select Portrait checkbox.
But I want to select Landscape check box as a default,when Dialog box appearing.
please send me a reply ,if any one know that.....
thanks...
How to select Landscape button as a default in PageSetupDialog
|
|
|
|
|
how can i connect to usb?
|
|
|
|
|
Ehm, the USB connectors can usually be found at the backside of your computer. They're small rectangular connectors.
If your computer is not equipped with these, it's massively outdated. A remedy is a plugin PCI-USB controller.
If that's not the answer you've hoped for: be more specific when attempting to formulate a question.
What do you want to do by what means?
|
|
|
|
|
I mean how can i send data through usb using c++
|
|
|
|
|
If you are using winXP or 2000 you are going to have to use a kernal mode driver to do the middle man work. I suggest you get a Cypress EZ USB board to learn on.
/\ |_ E X E GG
|
|
|
|
|
how can we understand a process request a socket
is there any message and if there is wich messages
koosha
|
|
|
|
|
koosha qaffari wrote:
how can we understand a process request a socket
is there any message and if there is wich messages
REALLY I AM VERY SOORY I CAN'T UNDERSTAND WHAT YOU HAVE WRITTEN,IF YOU KNOW HINDI,PLS DESCRIBE ME IN HINDI MAY BE I KNOW ANSWER TO YOUR PROBLEM
-----------------------------
"I Think It will Work"
-----------------------------
Alok Gupta
visit me at http://www.thisisalok.tk
|
|
|
|
|
Have I got this scheme right for running a scripting batch file from my program.
The program that is associated with the batch file is CSL.EXE and the following procedure will run when the selected TreeView file is double clicked:-
void CScriptingDlg::OnNMDblclkTree1(NMHDR *pNMHDR, LRESULT *pResult)<br />
{<br />
BOOL bSuccess = FALSE;<br />
SHELLEXECUTEINFO sei;<br />
ZeroMemory(&sei,sizeof(sei));<br />
sei.cbSize = sizeof(sei);<br />
sei.hwnd = AfxGetMainWnd()->GetSafeHwnd();<br />
sei.nShow = SW_SHOW;<br />
sei.lpFile = m_strPath.GetBuffer(m_strPath.GetLength());<br />
sei.fMask = SEE_MASK_INVOKEIDLIST;<br />
bSuccess = ShellExecuteEx(&sei);<br />
m_strPath.ReleaseBuffer();<br />
}
m_strPath is the full path name of the batch file; e.g. C:\Work\ABC.CSL.
The reason for this post is, if I double click a CSL batch file (i.e. C:\Work\ABC.CSL) from Window Explorer the CSL program runs OK, but if I do the same from within my program a DOS Window appears for a second then closes. The batch files appears not to have run.
So is this the correct way to do this?
Sweep123
|
|
|
|
|
sweep123 wrote:
sei.fMask = SEE_MASK_INVOKEIDLIST;
Per MSDN:
The lpIDList member must point to an ITEMIDLIST structure.
sweep123 wrote:
bSuccess = ShellExecuteEx(&sei);
What is the value of bSuccess ? If it is FALSE , what does GetLastError() return?
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
The code was lifted from the FileTreeCtrl sample on the code project site.
http://www.codeproject.com/wtl/wtlfiletreectrl.asp
When I place a breakpoint at the statement:-
m_strPath.ReleaseBuffer();
The bool is 1 and last error is zero.
Both this sample and my version are able to run up Notepad when double-click on a txt file. An image editor will run up for bitmaps.
But neither runs the CSL program associated with the ABC.CSL file.
|
|
|
|
|
While I doubt it's related to the problem at all, the calls to GetBuffer() and ReleaseBuffer() are not necessary.
What value are you assigning to lpVerb ?
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
If I use
sei.lpVerb = "open";
then the files is opened with QuickView and that includes .txt and .log files.
The code does not generate any erros, just dont seem to be able to run the program CSL.EXE in the correct manner with this code.
As I said if I use Windows Explorer then the CSL.EXE runs OK with the selected file.
Any ideas?
Sweep
|
|
|
|
|
when i click on ListCtrl Itelm ,, its background colur is turned to blue ,
after that
when i click to an other control ... previusly Clicked ListCtrl Items background colour disaapear ,, and i not know at thia stage at which item i was clicked ,, i want to Highlight it ,, with any way ,, as in windows it change its colour to Grey,,,
any tip .. or way
thanx.
Actualy ,, it makes easy the user to see that he clicked on this item last time
thanx
|
|
|
|
|
Can you use the LVS_SHOWSELALWAYS style?
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
My question may seem a bit lame. But I always twist my mind when trying to start a new project; i always have projects as they try to help me learn more.
But it takes me some time to come up with one, itried seaching the net for sites which offer list of project titles as a start point for fellows like me who waste their time wondering what to do ??
So pls if u know a site of this kind or have a list of possible ideas tell me.
Now i am finished with the project i was developing
"Digital Power System Simulation" and now ready to another??????/
|
|
|
|
|
Here is Suggestion
make a project on SmartCard's
-----------------------------
"I Think It will Work"
-----------------------------
Alok Gupta
visit me at http://www.thisisalok.tk
|
|
|
|
|
Well when I want an idea of something to develop, I hit sites like download.com and other shareware sites and that usual gives me some inspiration. Of course there are places like http://www.rentacoder.com[^] which have hundreds of project ideas.
Michael
CP Blog [^]
|
|
|
|
|
|
Hi,
How to trap file reading and writing in Shared Folder over a Network for Workgroups in Windows? Further more, may I trap browsing event in Shared Folder?
Thanks.
|
|
|
|
|
Is this to run on a Windows For Workgroups machine? If so, you'll be needing a 16-bit solution.
Otherwise, if the machine is NT-based, check out ReadDirectoryChangesW() and FindFirstChangeNotification() .
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|