簡體   English   中英

SUP 2.1.3-iOS本機應用程序-createCore中存在異常

[英]SUP 2.1.3 - iOS native application - exception is in createCore

我正在使用Sybase Unwired Platform 2.1 ESD 3開發iOS應用。在保存同步參數之前,我得到此錯誤:

Terminating app due to uncaught exception 'SUPPersistenceException', reason: 'exception is in createCore: Illegal key generator status: the key generator must be populated first.'

這是源代碼:

SUPConnectionProfile *sp = [SyncMBOFlowInboxSyncMBOFlowInboxDB getSynchronizationProfile];

[sp setAsyncReplay:NO];
[sp setUser:user];
[sp setPassword:pass];
[sp setServerName:server];


NSUserDefaults *usr = [NSUserDefaults standardUserDefaults];

SyncMBOFlowInboxFlowInboxSynchronizationParameters *pp = [SyncMBOFlowInboxFlowInbox getSynchronizationParameters];
[pp setS_USER_ID:[usr stringForKey:@"netUser"]];
[pp save]; <--The error appear after run this

[SyncMBOFlowInboxSyncMBOFlowInboxDB synchronize];

謝謝!!

每次啟動應用程序時(即使您處於脫機狀態且不是第一次同步),也需要在嘗試同步之前初始化SUP應用程序和相關的數據庫,否則會收到該錯誤。

我找到了解決方案。

如果使用SynchronizationParameters,則需要先使用[SyncMBOFlowInboxSyncMBOFlowInboxDB訂閱]。 並在我完成使用數據庫后退訂。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM