winston
August 25th, 1999, 10:58 AM
I want to show windows standard dialog in my c++ Program,just like the "computer property tab dialog" or "add new device dialog".How to do it?
|
Click to See Complete Forum and Search --> : How to show windows standard dialog winston August 25th, 1999, 10:58 AM I want to show windows standard dialog in my c++ Program,just like the "computer property tab dialog" or "add new device dialog".How to do it? ravish August 25th, 1999, 12:02 PM The standard dialog you mean is the contro panel dialog, I think. The system properties and device properties are system dialog. The control panel application(refer to MSDN Control Panel Applications)are the dll which have .cpl extension. YOu have to execute those dlls to view your dialog. To execute those dll you can use rundll32.exe. The code looks something similar. ShellExecute(NULL,"open","rundll32.exe","shell32.dll,Control_RunDLL Desk.cp1,,0); // note the two comma, it is not a single comma. it is 2(,,) and no comma between Control_RunDLL and desk.cpl This will open the desktop properties window. The zero(0) after the two commas is the page you want to open. If you want to open the first page you give 0(zero)first page means 1 and so on. All the cpl files will be located in the winnt\system32 directory. some aer located in the winnt directory also. Instead of desk.cpl give any cpl and it will open appropiate "standard" window. Hopes it helps you Note: if you have problem in the arguments check the registry key. it contains the arguments. HKEY_CLASSES_ROOT\cplfile\shell\cplopen\command codeguru.com
Copyright Internet.com Inc., All Rights Reserved. |