{
myApp = new TOcaf_Application();
SampleName = "OCAF"; //for about dialog
- SetSamplePath ("..\\..\\06_Ocaf");
+ SetSamplePath (L"..\\..\\06_Ocaf");
try
{
}
catch (Standard_Failure)
{
- AfxMessageBox("Fatal Error in units initialisation");
+ AfxMessageBox (L"Fatal Error in units initialisation");
}
}
void COcafApp::OnFileOpen()
{
CFileDialog aDlg(TRUE, NULL, NULL, OFN_FILEMUSTEXIST|OFN_HIDEREADONLY,
- "OCAFSample(STD) (*.std)|*.std|OCAFSample(XML) (*.xml)|*.xml|OCAFSample(Binary) (*.cbf)|*.cbf||");
+ L"OCAFSample(STD) (*.std)|*.std|OCAFSample(XML) (*.xml)|*.xml|OCAFSample(Binary) (*.cbf)|*.cbf||");
if (aDlg.DoModal() != IDOK)
return;
-
- int strLength = aDlg.GetPathName().GetLength()+1;
- LPTSTR lpszFileName = new TCHAR[strLength];
- strcpy_s(lpszFileName, strLength, aDlg.GetPathName() );
-
- OpenDocumentFile(lpszFileName);
+ OpenDocumentFile (aDlg.GetPathName());
}