Read-only archive of the All About Symbian forum (2001–2013) · About this archive

Problems with acitveObject

2 replies · 1,249 views · Started 09 May 2005

Hello,
i have a litte problem with activeobject under symbian on my p800.

I have createt an activeobject, and when i call this activeobject with following code it works:
SetActive();
TRequestStatus* status=&(iStatus);
User::RequestComplete(status,1);
The RunL-Method will be invoked.

But if i run this activeaobject-call in a new thread it doesn't work 😮(

What must i do, to call an activeobject from an other thread.

The thread was created with:
m_connectionThread = new RThread();
res = m_connectionThread->Create(KThreadName,
DeviceCommunication::ReadData,
KDefaultStackSize*2,
NULL,
(TAny*)this,
EOwnerThread);

Thanks for helping, Michael

Have you installed an Active Scheduler in the new thread?

// Create and install the active scheduler
CActiveScheduler* exampleScheduler= new (ELeave) CActiveScheduler; CleanupStack::PushL(exampleScheduler);
CActiveScheduler::Install(exampleScheduler);

regards,
Nishant.
www.nishantkumar.net

yes, i have installed a active scheduler in the new thread but it does't works.
I can't send a RequestComplete in this thread 😮(

Michael