Upgrades Questions on upgrading to version 7.x.
Version 7.x > Upgrades > WorkflowManager compile error View modes: 
User avatar
Member
Member
Peter - 12/12/2012 4:14:57 PM
   
WorkflowManager compile error
Hi, we are upgrading our website to version 7.
In our custom library we use the workflow manager, howerver suddenly getting an error on compile.

Any suggestions?
Thanks,
Peter

Code:
UserInfo ui = UserInfoProvider.GetUserInfo(userName);
TreeProvider tree = new TreeProvider(ui);
WorkflowManager wm = new WorkflowManager(tree);

Error:
CMS.DocumentEngine.WorkflowManager.WorkflowManager(CMS.DocumentEngine.TreeProvider)' is inaccessible due to its protection level

User avatar
Member
Member
Peter - 12/12/2012 10:36:29 PM
   
RE:WorkflowManager compile error
Actually after replacing all reference libraries, now we are getting different error.

'CMS.DocumentEngine.WorkflowManager' does not contain a constructor that takes 1 arguments

User avatar
Kentico Support
Kentico Support
kentico_radekm - 12/17/2012 1:08:04 AM
   
RE:WorkflowManager compile error
Hello.

Could you please compare your code in this custom project with document below, dealing with API changes between KCMS 6.0 and KCMS 7.0 to be sure you use updated version of API? Also, you can check it in API reference file, if you search given class / method and see its current definition.

http://devnet.kentico.com/Blogs/Martin-Hejtmanek/September-2012/API-Changes-From-Kentico-CMS-6-to-7.aspx

Best Regards,
Radek Macalik

User avatar
Member
Member
Peter - 12/17/2012 3:39:11 PM
   
RE:WorkflowManager compile error
Thanks Radek,

I was referring to your documentation (Kentico CMS 7.0 Developer's Guide) and it seems to be different.

To get it working I used the following code.

WorkflowManager wm = WorkflowManager.GetInstance(tree);

Is that correct? If it is please update your documentation.

User avatar
Kentico Support
Kentico Support
kentico_radekm - 12/19/2012 3:02:24 AM
   
RE:WorkflowManager compile error
Hello.

You are correct. Our documentation is outdated in this. We are sorry for this inconvenience. We will update it as soon as possible.

Best Regards,
Radek Macalik