Code/Resource
Windows Develop
Linux-Unix program
Internet-Socket-Network
Web Server
Browser Client
Ftp Server
Ftp Client
Browser Plugins
Proxy Server
Email Server
Email Client
WEB Mail
Firewall-Security
Telnet Server
Telnet Client
ICQ-IM-Chat
Search Engine
Sniffer Package capture
Remote Control
xml-soap-webservice
P2P
WEB(ASP,PHP,...)
TCP/IP Stack
SNMP
Grid Computing
SilverLight
DNS
Cluster Service
Network Security
Communication-Mobile
Game Program
Editor
Multimedia program
Graph program
Compiler program
Compress-Decompress algrithms
Crypt_Decrypt algrithms
Mathimatics-Numerical algorithms
MultiLanguage
Disk/Storage
Java Develop
assembly language
Applications
Other systems
Database system
Embeded-SCM Develop
FlashMX/Flex
source in ebook
Delphi VCL
OS Develop
MiddleWare
MPI
MacOS develop
LabView
ELanguage
Software/Tools
E-Books
Artical/Document
pgsvefil.cpp
Package: shell.rar [view]
Upload User: xhy777
Upload Date: 2007-02-14
Package Size: 24088k
Code Size: 2k
Category:
Windows Kernel
Development Platform:
Visual C++
- #include "pch.hxx" // pch
- #pragma hdrstop
- #include "resource.h"
- #include "pgSveFil.h"
- CSaveToFilePg::CSaveToFilePg(
- LPPROPSHEETPAGE ppsp
- ) : WizardPage(ppsp, IDS_WIZSAVETOFILETITLE, IDS_WIZSAVETOFILESUBTITLE)
- {
- m_dwPageId = IDD_WIZSAVETOFILE;
- ppsp->pszTemplate = MAKEINTRESOURCE(m_dwPageId);
- }
- CSaveToFilePg::~CSaveToFilePg(
- VOID
- )
- {
- }
- LRESULT
- CSaveToFilePg::OnInitDialog(
- HWND hwnd,
- WPARAM wParam,
- LPARAM lParam
- )
- {
- UpdateControls();
- return 1;
- }
- void CSaveToFilePg::UpdateControls()
- {
- // No options
- }
- LRESULT
- CSaveToFilePg::OnCommand(
- HWND hwnd,
- WPARAM wParam,
- LPARAM lParam
- )
- {
- LRESULT lResult = 1;
- WORD wNotifyCode = HIWORD(wParam);
- WORD wCtlID = LOWORD(wParam);
- HWND hwndCtl = (HWND)lParam;
- switch(wCtlID)
- {
- case IDC_BTNBROWSE:
- {
- // These commands require us to re-enable/disable the appropriate controls
- TCHAR szBuf[_MAX_PATH];
- TCHAR szBuf2[_MAX_PATH];
- memset(szBuf, 0, ARRAYSIZE(szBuf));
- memset(szBuf2, 0, ARRAYSIZE(szBuf));
- wsprintf(szBuf, __TEXT("test.exe"));
- OPENFILENAME ofn;
- memset(&ofn, 0, sizeof(ofn));
- ofn.lStructSize = sizeof(ofn);
- ofn.hwndOwner = m_hwnd;
- ofn.hInstance = g_hInstDll;
- ofn.lpstrFilter = NULL;
- ofn.lpstrCustomFilter = NULL;
- ofn.nMaxCustFilter = 0;
- ofn.nFilterIndex = 0;
- ofn.lpstrFile = szBuf;
- ofn.nMaxFile = _MAX_PATH;
- ofn.lpstrFileTitle = szBuf2;
- ofn.nMaxFileTitle = _MAX_PATH;
- ofn.lpstrInitialDir = NULL;
- ofn.lpstrTitle = NULL;
- ofn.Flags = OFN_OVERWRITEPROMPT | OFN_PATHMUSTEXIST;
- ofn.nFileOffset = 0;
- ofn.nFileExtension = 0;
- ofn.lpstrDefExt = NULL;
- ofn.lCustData = NULL;
- ofn.lpfnHook = NULL;
- ofn.lpTemplateName = NULL;
- BOOL bOk = GetSaveFileName(&ofn);
- UpdateControls();
- lResult = 0;
- }
- break;
- default:
- break;
- }
- return lResult;
- }