[求助]怎样制作程序的启动界面?
怎样制作程序的启动界面?<BR>我用Splash screen控件做,但是不知道用什么方法得到autocad的CWnd对象....<BR> K030.arx.plus.all\samples\ARXDBG一个自带的sample
////////////////////////////////
CWnd*<BR>ArxDbgApp::startSplashScreen()<BR>{<BR> CString bmpFileName = appPath();<BR> bmpFileName += _T("support\\ArxDbgSplash.bmp"); // TBD: make this better later!
// make sure file is there (either in a main directory, which is<BR> // where someone would install it, or for developers, go out of <BR> // "Debug" directory and up to the main directory.<BR> CFileStatus status;<BR> BOOL success = CFile::GetStatus(bmpFileName, status);<BR> if (success == FALSE) {<BR> bmpFileName = appPath();<BR> bmpFileName += _T("..\\support\\ArxDbgSplash.bmp"); // TBD: make this better later!
success = CFile::GetStatus(bmpFileName, status);<BR> }
if (success) {<BR> ArxDbgUiDlgSplash* dbox = new ArxDbgUiDlgSplash(bmpFileName);<BR> dbox->setTextStrings(appName(), versionStr(), _T(""), _T(""));
// TBD: have to do this manually right now, although it should<BR> // have worked to pass up resource handle through the constructor!<BR> acDocManager->pushResourceHandle(dllInstance());<BR> dbox->Create(acedGetAcadDwgView());<BR> acDocManager->popResourceHandle();
dbox->ShowWindow(SW_SHOW);<BR> dbox->UpdateWindow();
return dbox;<BR> }<BR> else { // intended a splash screen but could not find it!<BR> acutPrintf(_T("\nCould not find splash box image: \"%s\""), bmpFileName);<BR> return NULL;<BR> }<BR>}
调用的时候:
在AcRx::AppRetCode ArxDbgApp::initApp()里面这么写:
CWnd* splashScreen = startSplashScreen(); 你的这段代码截的太高了!让我们干眼馋就是用不了,缺好多东西!!
有这段源吗的朋友给上传一个,多谢!!
回复
参考:<A href="dispbbs.asp?boardid=14&star=4&replyid=67959&id=22734&skin=0&page=1" target="_blank" >dispbbs.asp?boardid=14&star=4&replyid=67959&id=22734&skin=0&page=1</A>
第35楼 多谢,那页我看过,好象和以上的不是一回事!
页:
[1]