function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion

Publishing of Articles -- problem with KB methods

In summer release salesforce provide api for knowledge :


when i using these methods i getting error as "Invalid method or signature doesn't exsists".


This is code which im using in systemlog.


KnowledgeArticle  s= new KnowledgeArticle ();
s=[select id from KnowledgeArticle where id='kA6V0000000001d'];




Can you please give me the link to the summer release with the knowledge api?


The error you are getting might be because of a typo- like KbManagement.Publishinervice.publishArticle(s), where Publishinervice seems to be incorrect . Check the code again and use copy/paste for method names.


Also take a look at this link: . Shouldn't you be using <Article Type>__ka instead of KnowledgeArticle?





The right way to publish an article using Summer'12 is as follow:


String articleId = 'Insert article ID';
KbManagement.PublishingService.publishArticle(articleId, true);


Where articleid is the KnowledgeArticleID