Click here to Skip to main content
15,918,003 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: how to create new thread Pin
David Crow15-Apr-09 2:47
David Crow15-Apr-09 2:47 
AnswerRe: how to create new thread Pin
ThatsAlok14-Apr-09 20:19
ThatsAlok14-Apr-09 20:19 
QuestionTwo top most windows, one always above the other Pin
Member 449830414-Apr-09 3:38
Member 449830414-Apr-09 3:38 
AnswerRe: Two top most windows, one always above the other Pin
Iain Clarke, Warrior Programmer14-Apr-09 5:42
Iain Clarke, Warrior Programmer14-Apr-09 5:42 
GeneralRe: Two top most windows, one always above the other Pin
Member 449830414-Apr-09 7:13
Member 449830414-Apr-09 7:13 
GeneralRe: Two top most windows, one always above the other Pin
Iain Clarke, Warrior Programmer14-Apr-09 8:51
Iain Clarke, Warrior Programmer14-Apr-09 8:51 
GeneralRe: Two top most windows, one always above the other Pin
Member 449830414-Apr-09 9:01
Member 449830414-Apr-09 9:01 
Questionpower point automation. Pin
SRKSHOME14-Apr-09 2:49
SRKSHOME14-Apr-09 2:49 
Hi,
I have some powerpoint addins which are to be added to powerpoint programmatically.The problem in the below code is it always says power application object cannot be created while running the program. but powerpoint application object will create during debugging the program.
hence I am not able to figure out the problem. Could any one help me please?

void InstallPptAddins(LPCTSTR strAddinPath)
{
	CFileFind m_fileFind;
	CString strAddin;
	
	PowerPoint::_Application Ppt; //Powerpoint object
	PowerPoint::AddIns m_pptAddIns;
	PowerPoint::AddIn m_pptAddIn;

	if(!Ppt.CreateDispatch("PowerPoint.Application"))
	{
		Log("Error:fn::InstallPptAddins() Couldn't open Powerpoint Application\n");
		return;
	}

try
{

	if(Ppt.GetVersion()=="12.0")
	{
		PowerPoint::Presentations m_Sets(Ppt.GetPresentations());
		PowerPoint::_Presentation m_Set(m_Sets.Add(TRUE));
	
		strAddin = strAddinPath;
		strAddin += "DSAFO5PP.ppa";
	
	
		if(m_fileFind.FindFile(strAddin))
		{
			m_pptAddIns = Ppt.GetAddIns();
			m_pptAddIn = m_pptAddIns.Add(strAddin);
		
			//Revove first if it already installed
			m_pptAddIn.SetLoaded(FALSE);
			m_pptAddIn.SetAutoLoad(FALSE);
			m_pptAddIn.SetRegistered(FALSE);

			//Install the addins
			m_pptAddIn.SetLoaded(TRUE);
			m_pptAddIn.SetAutoLoad(TRUE);
			m_pptAddIn.SetRegistered(TRUE);

			Log("AFO Powerpoint add-in is added.\n");
			
		}
		else
		Log("Couldn't find Powerpoint add-in %s\n",strAddin);


 }
catch(...)
{
Log("Error::Couldn't install Powerpoint add-ins.Please add it manually\n\n");
}
	
	Ppt.Quit();
}

AnswerRe: power point automation. Pin
VC++Maniac14-Apr-09 2:55
VC++Maniac14-Apr-09 2:55 
GeneralRe: power point automation. Pin
SRKSHOME14-Apr-09 3:12
SRKSHOME14-Apr-09 3:12 
QuestionNo copy paste support in editbox [modified] Pin
VC++Maniac14-Apr-09 2:37
VC++Maniac14-Apr-09 2:37 
AnswerRe: No copy paste support in editbox Pin
Iain Clarke, Warrior Programmer14-Apr-09 3:10
Iain Clarke, Warrior Programmer14-Apr-09 3:10 
QuestionExternal Hard Disk Drive Temperature Pin
Abinash Mohanty14-Apr-09 1:59
Abinash Mohanty14-Apr-09 1:59 
QuestionRe: External Hard Disk Drive Temperature Pin
David Crow14-Apr-09 2:35
David Crow14-Apr-09 2:35 
AnswerRe: External Hard Disk Drive Temperature Pin
Michael Schubert14-Apr-09 6:49
Michael Schubert14-Apr-09 6:49 
GeneralRe: External Hard Disk Drive Temperature Pin
Abinash Mohanty15-Apr-09 18:17
Abinash Mohanty15-Apr-09 18:17 
QuestionAdd member variable taking forever... Pin
Rajesh R Subramanian14-Apr-09 1:41
professionalRajesh R Subramanian14-Apr-09 1:41 
AnswerRe: Add member variable taking forever... Pin
_AnsHUMAN_ 14-Apr-09 2:02
_AnsHUMAN_ 14-Apr-09 2:02 
GeneralRe: Add member variable taking forever... Pin
Rajesh R Subramanian14-Apr-09 2:51
professionalRajesh R Subramanian14-Apr-09 2:51 
GeneralRe: Add member variable taking forever... Pin
David Crow14-Apr-09 3:45
David Crow14-Apr-09 3:45 
GeneralRe: Add member variable taking forever... Pin
Rajesh R Subramanian14-Apr-09 4:22
professionalRajesh R Subramanian14-Apr-09 4:22 
AnswerRe: Add member variable taking forever... Pin
Iain Clarke, Warrior Programmer14-Apr-09 3:12
Iain Clarke, Warrior Programmer14-Apr-09 3:12 
GeneralRe: Add member variable taking forever... Pin
Rajesh R Subramanian14-Apr-09 4:25
professionalRajesh R Subramanian14-Apr-09 4:25 
GeneralRe: Add member variable taking forever... Pin
CPallini14-Apr-09 5:56
mveCPallini14-Apr-09 5:56 
AnswerRe: Add member variable taking forever... Pin
Eytukan14-Apr-09 8:28
Eytukan14-Apr-09 8:28 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.