API Questions on Kentico API.
Version 6.x > API > Upgrade some Mehtods from 5.5R2 to 6.0 View modes: 
User avatar
Member
Member
charles.lam-evn - 1/7/2013 9:44:17 AM
   
Upgrade some Mehtods from 5.5R2 to 6.0
Hello,

i have a question, iam just upgrading from 5.5R2 to 6.0 (and later higher). And in the custom Code ich have some Methods, that are hard to Migrate, due that the EXCEL with the Changed Methods, show the Methods, but dont really explain, what the new parameters should do.

i my case it is the Methode:
5.5 R2
ExportProvider.GetExportData(SiteExportSettings settings, string where, string objectType, bool childData, TranslationHelper th)
=>
6.0
ExportProvider.GetExportData(SiteExportSettings settings, QueryDataParameters parameters, string where, string objectType,string parentObjectType, bool childData, bool selectionOnly, TranslationHelper th)

Now i am not sure what should be the default Values, or which values i should enter for the new parameters, like : QueryDataParameters parameters, string parentObjectType and selectionOnly.

Can someone help me out?

Thanks in advance

Charles

User avatar
Member
Member
charles.lam-evn - 1/8/2013 12:14:34 AM
   
Anex to:Upgrade some Mehtods from 5.5R2 to 6.0
The same goes for the not documented change in the Methode
CMS.CMSImportExport.ImportExportHelper.GetDocumentsDataWhereCondition,

Where the Parameters string sourceColumn and SelectCondition cond were added.

THANKS in advance.

Charles

User avatar
Kentico Support
Kentico Support
kentico_jurajo - 1/8/2013 3:47:39 AM
   
RE:Anex to:Upgrade some Mehtods from 5.5R2 to 6.0
Hi,

1. You can use the other overload of the method:
 GetExportData(SiteExportSettings settings, string objectType, string parentObjectType, bool siteObjects, bool childData, bool selectionOnly, TranslationHelper th)

and use e.g. null for the parentObjectType. Otherwise you ened to use the object type of the parent object - in the same way as you are getting the objectType of some object.

2. SourceColumn - usualy the ID column of given object. Where condition - the where condition part you want to add to it. You can use null again.

Best regards,
Juraj Ondrus

User avatar
Member
Member
charles.lam-evn - 1/9/2013 3:17:32 AM
   
RE:Anex to:Upgrade some Mehtods from 5.5R2 to 6.0
Thanks for the fast Reply, sounds good, compiles, now i just have to the it thoroughly. :)

Best Regards

Charles