tridion - CurrentWorkItem.ID is correct or not in workflow script editor? -


I am using Tridion 2011 SP1, and I'm creating a workflow like-- - & gt; Create - & gt; Review - & gt; Publish - Pause

I created and registered class library, and called the C # method using VBscript (script Editor of the WF tab) as given below.

  Options clear clear workflowholder set workflowholder = Create object ("coreconmintworkflow. Workflowdaler") If not, then the workflowholder is nothing, call workflowtholder. PublishComponent (Cstr (CurrentWorkItem.ID)) Finnish Activities "Publish in WIP" End if set workflowholder = nothing   

Is the above code correct? I'm sure I'm able to create an object using the bottom line. Workflowholder = Create Object ("CoreComponentWorkflow.WorkflowHandler")

And currently I am using the current item only using the C # code, C Calling the # function below.

  call workflowthalander PublishComponent (Cstr (CurrentWorkItem.ID))   

After publishing the item, I'm ending the activity using below.

  Finnish activity "published in WIP"   

I have been working the code above directly with hard coding of the current operating system to the server Was there. But when I put the same code in the vbscript editor, the item has not been published.

Can anyone suggest this?

When you can add hardcoded TCM ID directly then it is working properly, which means That is not the right API call to receive the CurrentWorkItem.ID component ID. See Igor's comment below to get the TCM ID

Comments