cancel
Showing results for 
Search instead for 
Did you mean: 

Issue on :SUP 2.1.2 Synchronize data from SUP server

Former Member
0 Kudos

Dear all,

Is there anybody has run the whole flow for the new version 2.1.2 for register the user and synchronize the data from the server?

Now I can register the device user from xcode side, and it worked correctly.

But I met a issue on synchronize the data from SUP Server.

Details as the following:

After register the device user and openConnection method,

[CRMDLW_CRM_V1_PRJDB openConnection];

The following method's return code always is 2 - Pending.

[CRMDLW_CRM_V1_PRJDB beginOnlineLogin:@"vincentAdmin"
password:@"Delaware"];

while([CRMDLW_CRM_V1_PRJDB getOnlineLoginStatus].status ==
SUPLoginPending)
{ NSLog(@"%d", [CRMDLW_CRM_V1_PRJDB getOnlineLoginStatus].status);

Could you provide me some idea for this problem, please?

Or I need not to use this method?

But if not, we could not get data by synchronization operation.

Is anyboay can provide me some help?

Thanks!

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Nobody answer me!

Ian_Thain
Developer Advocate
Developer Advocate
0 Kudos

Vincent

Its been a while since I last coded with iOS against SUP but my code looked like this (apologies it may be out of date)

while(!success)

    {

   @try {
   [iSurvey_ISurveyDB beginOnlineLogin:@"supAdmin" password:@"s3pAdmin"];
  
   // if we get here, login was successful
   success = YES;
   } @catch(NSException *e)
   {
   MBOLogError(@"*********** loginToSync failed, trying again ***********");
   }

    }

Former Member
0 Kudos

Hi Lan,

Thanks for your reply.

As you said :

[iSurvey_ISurveyDB beginOnlineLogin:@"supAdmin" password:@"s3pAdmin"];

success = YES;

But if there no statement to check the status whether sucess, you will always get the sucess = YES.

So I think the while will only do one time.

Do you synchronize the data from SUP server to device correctly?

Regards,

Vincent

Ian_Thain
Developer Advocate
Developer Advocate
0 Kudos

Vincent

I was indeed. Have you tried to use the MBODebuglogger to see any messages?

Ian

Ian_Thain
Developer Advocate
Developer Advocate
0 Kudos

Vincent

Have you tried this change anyway?

Ian

Former Member
0 Kudos

Hi Lan,

I did not use it.Could you tell me some details about MBODebuglogger, please?

Thanks

Regards,

Vincent

Ian_Thain
Developer Advocate
Developer Advocate
0 Kudos

I'm also thinking you have looked at the iOS tutorial at http://scn.sap.com/docs/DOC-8803

Ian

Former Member
0 Kudos

Lan,

Yes, I have tried as you mentioned.

Vincent

Former Member
0 Kudos

Lan,

I will look.

In additional, did the MBO created from SAP RFC FM or local database?

Thanks for your help!

Ian_Thain
Developer Advocate
Developer Advocate
0 Kudos

Just saw another thread... http://scn.sap.com/thread/2052067

That suggests a few things as well as ...

For better understanding whats causing the error, Comment the lines begining with #ifdef and #endif in MBODebugLogger.m of the Generated Code. And it prints the Log to the Console -Kiran

Ian

Ian_Thain
Developer Advocate
Developer Advocate
0 Kudos

Vincent

My DB was local and the MBO's  using message based sync

Ian

Former Member
0 Kudos

Lan,

Got it. Thanks for your hlep.

Regards,

Vincent

Ian_Thain
Developer Advocate
Developer Advocate
0 Kudos

You're most welcome

Ian

Answers (0)