/ Published in: C++

Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
// Browse for OCX and then execute Regsvr32 // http://www.functionx.com/visualc/controls/filedialog.htm CFileDialog fileDlg( true, // open NULL, NULL, OFN_FILEMUSTEXIST, "OCX Files (*.ocx)|*.ocx|All Files (*.*)|*.*||", this ); bool bOk = fileDlg.DoModal() == IDOK ; if ( bOk ) { CString pathName = fileDlg.GetPathName(); ShellExecute( // WinExec is obsolete. this->m_hWnd, // hwnd "open", // operation/verb. "regsvr32.exe", // executable. pathName, // parameters. NULL, // directory SW_SHOW ); // how to be displayed }
Comments
