Click here to Skip to main content
13,559,658 members
Rate this:
Please Sign up or sign in to vote.
See more: , +
Hello to Everyone.
I have created MFC Ribbon Application in VS2010. I have attached avi with CMFCRibbonStatusBarPane with Autoplay mode. When I have started my application Click on Button For "Play Avi". Avi is running now.

If my Application is having character Set Settings: Multibyte Character Set
And Click on Button For "Opening 20 Documents" Avi is still running while opening documents.

But If My Application is having character set Settings: Unicode
And Click on Button For "Opening 20 Documents" Avi is automatically stopped while opening documents.

Details As Below:::
CStatusbarAnimate CPP: Create Code
	if (!CAnimateCtrl::Create( dwStyle, rect, pStatusBar, 0 ))
		return FALSE;

	m_nPane = nPane;
	return Open( nIDanimation );
MainFrame Header
	CStatusbarAnimate		*m_pAnimate;
	CMFCRibbonStatusBar		m_wndStatusBar;
	CMFCRibbonStatusBarPane		*m_wndStatusValue1;
MainFrame CPP: OnCreate Function
	m_wndStatusValue1 = new CMFCRibbonStatusBarPane(ID_STATUSBAR_PANE1, _T(""), TRUE);
	m_wndStatusBar.AddElement(m_wndStatusValue1, _T(""));
	m_wndStatusBar.AddExtendedElement(new CMFCRibbonStatusBarPane(ID_STATUSBAR_PANE2, strTitlePane2, TRUE), strTitlePane2);
MainFrame CPP: "Play Avi" Function (Button Click)
CRect rect;
	rect = m_wndStatusValue1->GetRect();
	m_pAnimate = new CStatusbarAnimate;
	m_pAnimate->Create(IDR_AVITEST, 1,rect);

AND "Open 20 Documents" (Button Click)
CRibbonStatusApplicationDoc *pDoc;
	for(int k = 0; k < 20; k++)
		pDoc = (CRibbonStatusApplicationDoc *)((CRibbonStatusApplicationApp *)AfxGetApp())->pDocTemplate->OpenDocumentFile(NULL,true);
Posted 20-Jan-13 20:12pm
Updated 20-Jan-13 20:34pm

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy | Cookies | Terms of Service
Web03-2016 | 2.8.180527.1 | Last Updated 21 Jan 2013
Copyright © CodeProject, 1999-2018
All Rights Reserved.
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100