Hi,
The second code works only in *.app files, but not works in *.exe files:
_LIT(filen,"Calcsoft.app"😉;
const TUid KUidApplicationWillRun = {0x10005902};
const TUid KUidApplicationWasRun = {0x0DB454A8};
....
RApaLsSession ls;
User::LeaveIfError(ls.Connect());
CleanupClosePushL(ls);
TThreadId dummy;
TApaTaskList tasklist(CCoeEnv::Static()->WsSession());
TApaTask task(tasklist.FindApp(KUidApplicationWasRun)); // bad line!!!
if(task.Exists())User::LeaveIfError(ls.StartDocument(filen,KUidApplicationWillRun,dummy));
When i'm run this code which in exe file shown error: KERN_EXEC 3
How can resolve this problem, that it works in *.exe?
Thanks in advance!!!