×

Discussion Board

Results 1 to 2 of 2
  1. #1
    Registered User
    Join Date
    Nov 2005
    Posts
    17

    Can't get Status Report Set

    I am modifing the sms example to try and get a status report and cannot get it to work. Please Help.


    Code:
    void CSMSExampleMtmsEngine::SendSMSL()
        {
        // Changes the entry on which later actions are performed to the entry with the 
    	// specified TMsvId. 
        iSmsMtm->SwitchCurrentEntryL(iSmsId);
    
        // Load the created message
        iSmsMtm->LoadMessageL();
    
        // Gets the current SMS service settings
        CSmsSettings& serviceSettings = iSmsMtm->ServiceSettings();
    
    	iSmsMtm->ServiceSettings().SetDeliveryReport(ETrue);
    	iSmsMtm->ServiceSettings().SetStatusReportHandling(CSmsSettings::EMoveReportToInboxVisible);
    
    	// Gets the number of service centre addresses stored in this object.
        const TInt numSCAddresses = serviceSettings.NumSCAddresses();
        
    	// There should always be a service center number
    	if (numSCAddresses > 0)
    		{
            CSmsNumber*	serviceCentreNumber = NULL;
    
            // get the service center number
            if ((serviceSettings.DefaultSC() >= 0)  &&  (serviceSettings.DefaultSC() < numSCAddresses))
                serviceCentreNumber = &(serviceSettings.SCAddress(serviceSettings.DefaultSC()));
            else
                serviceCentreNumber = &(serviceSettings.SCAddress(0));
    
            iSmsMtm->SmsHeader().SetServiceCenterAddressL(serviceCentreNumber->Address());
            }
    	else 
    		{
    		// Leave if there is no service center number
    		User::Leave(0);
    		}
    
        iSmsMtm->SaveMessageL();
    
        // Index entry must be Updated
        TMsvEntry indexEntry = iSmsMtm->Entry().Entry();
    	// Set in-preparation flag
        indexEntry.SetInPreparation(EFalse);
    	// Sets the sending state
        indexEntry.SetSendingState(KMsvSendStateWaiting);
        iSmsMtm->Entry().ChangeL(indexEntry);
    
        // Time to send the message
        Cancel(); // prepare iMsvOper for use
    	iEntrySelection->Reset();
    	iEntrySelection->AppendL(iSmsId);
    
        TBuf8<1> dummyParam;
    	// There is also InvokeSyncFunctionL which is synchronous.
    	iMsvOper = iSmsMtm->InvokeAsyncFunctionL(ESmsMtmCommandScheduleCopy, *iEntrySelection, dummyParam, iStatus);
        SetActive();
        }

  2. #2
    Registered User
    Join Date
    Nov 2005
    Posts
    17

    Re: Can't get Status Report Set

    Figured it out , just add line :

    iSmsMtm->SmsHeader().SetSmsSettingsL(iSmsMtm->ServiceSettings());

Similar Threads

  1. Status Report Problem
    By JoelParker27 in forum Mobile Java Networking & Messaging & Security
    Replies: 2
    Last Post: 2005-12-13, 05:50
  2. Getting started with Carbide.vs -- running the app
    By ET3D in forum Symbian Tools & SDKs
    Replies: 6
    Last Post: 2005-11-23, 17:45
  3. Questions on billing action triggerred by Status Report Server
    By bigrio in forum Digital Rights Management & Content Downloading
    Replies: 1
    Last Post: 2005-04-02, 20:23
  4. Status Report handling
    By keypad in forum General Messaging
    Replies: 2
    Last Post: 2004-02-19, 20:19
  5. Replies: 0
    Last Post: 2003-09-11, 15:53

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •