Professional UI Solutions
Site Map   /  Register
 
 

Forum

Please Log In to post a new message or reply to an existing one. If you are not registered, please register.

NOTE: Some forums may be read-only if you are not currently subscribed to our technical support services.

Forums » Prof-UIS Tech Support » Multiple Document Type in RibbonBarMDI application Collapse All
Subject Author Date
Roongrit Charoensupkul Jan 8, 2008 - 11:53 PM

I’m trying to add new document type for my application. My first step is to create a new file using CMainFrame::CreateNewChild(...) instead. Follow on your RibbonBarMDI application, this sample application create a new tab using this function already. So, to begin using Doc/View classes, I add these code in RibbonBarMDI::InitInstance()

CMultiDocTemplate* pDocTemplate = new CMultiDocTemplate(IDR_RIBBON_BAR_MDI_TYPE,
RUNTIME_CLASS( CChildDoc ),
RUNTIME_CLASS( CChildFrame ),
RUNTIME_CLASS( CTestView ),
if (!pDocTemplate)
return FALSE;
AddDocTemplate( pDocTemplate );

CMainFrame* pFrame = new CMainFrame;
...

But when I choose "File>New" command, the sample application create new tab only. There is no View attach to that tab. I tried using this way with other normal application (not using RibbonBar) and it works.

Please let me know what’s the steps in order to make these codes work. So I can add a new document type.

Thanks

Technical Support Jan 9, 2008 - 9:58 AM

Could you reproduce this in our sample application and send it to us?