分类: C/C++
2009-06-29 15:33:59
void StartOtherApp()
{
TUid appUid(TUid::Uid(0x02af1382));
User::LeaveIfError( ras.Connect() );
CleanupClosePushL( ras );
TApaAppInfo appInfo;
ras.GetAppInfo( appInfo, appUid ); //appUid是要启动程序的UID
CApaCommandLine *cmd = CApaCommandLine::NewLC();
cmd->SetLibraryNameL( appInfo.iFullName );
cmd->SetCommandL( EApaCommandRun );
CleanupStack::PopAndDestroy( cmd );
CleanupStack::Pop();
ras.Close();
}