The CreatorCon Call for Content is officially open! Get started here.

what is new SNC.PlannedTaskAPI();

moulik1
Kilo Guru

Hi,

Can anyone explain what is "new SNC.PlannedTaskAPI();". I could not find it in script includes. Please help

Thanks

9 REPLIES 9

Unfortunately you can't get the properties of SNC.PlannedTaskAPI like that.


Those methods in Java layer don't come as methods in JavaScript object. There is some Rhino magic which routes the calls to java layer, when it gets a call in JavaScript layer.



I think it would be nice if we give you an API doc exposing the methods which developers can call. I will work with doc team and put this in documentation.


Hey Arun,



Did you every get the documentation for the PlannedTaskAPI?



The only reason I ask it I'm doing stuff programmatic with the new project module, and I'll like to be able to copy a sub section of the project (either a task, a task with sub tasks, or a sub project with all of the above!) into another project.



Is there a copyTask function the same as there is a copyProject function?



If you could get me the API docs that would be super helpful.



Thanks,



James


Arun and maybe ctomasi, kalai and others



Could you advocate internally for documentation of these SNC java API? and maybe having a verbose mode on logs.


For example, I have a customer would made a mistake by trying to deactivate all validation/automation, so now I'm trying to reenable what is necessary but because "SNC.PlannedTaskAPI" doesn't tell me which validations failed, it's actually rather difficult to guess.



My concrete example is "validateChangeParent" tells me "BR - Validate Change Parent - status -> Unable to change parent" which is great but the reason why it failed could be rather useful



Thanks


Hi, I'm having the same problem; in validateChangeParent method I throw an error but it's impossible to understand the cause... There is any update about the documentation?

Thank you very much,

Stefano

I never heard anything 😞