Initial Workflow - Validation

Initial Workflow - Validation

Anonymous
Not applicable
972 Views
4 Replies
Message 1 of 5

Initial Workflow - Validation

Anonymous
Not applicable

Trying to setup Validation when an Item is Created.

 

We are checking if fields in the Item Classification section do not have specific values and prompting the user when creating an item. Attempting to do this with a validation script assigned to the workflow initial Transition which should be triggered when the item is created?

 

The validation script runs without issue in testing but seems to be ignored during item creation. Is this by design or is the issue that the classification fields do not have values until after the item is created?

 

BD

0 Likes
973 Views
4 Replies
Replies (4)
Message 2 of 5

Anonymous
Not applicable

just following up on this issue. I saw the other posts with similar questions but don't think they are answering my question.

 

In going over the other posts I get:

 

1. Validation is performed on Items Details for required fields

2. The On-Create Action Script cannot have validation or prompts for user input to correct the item record information as the action script is triggered after the item has been created.

 

So since the field I am trying to validate before an item is a classification field (pick list), by setting it to required you have to select a default value which causes it to have a value, so item 1 above won't be triggered.

 

So my question is can the initial workflow transition have validation scripts assigned, it would appear so as you can set the Validation script in the workflow editor -See attached Screen shot. Second can classification fields be used at that point in the workflow in the validation script?

 

BD

 

0 Likes
Message 3 of 5

Anonymous
Not applicable

The first transition is almost like an on-create script.  I have used this first transition to have an action script run.  I have never used it for validation and I'm not sure if can because it may be a timing thing.  It all depends when the values are written to the record.  If the values are written first and then the transition runs, I assume yes you will be able to validate.

 

Validation does work well on item details fields.  I'm not sure if it works well on classification fields.  I am interested in testing this out myself.  I'll let you know what I find. later.

0 Likes
Message 4 of 5

Anonymous
Not applicable
Leungicp, thank you for your response.
Those are the two questions I am trying to answer.
1. Do Validation scripts work on the initial workflow transition
2. Are classification field values available to the initial transition validation script
I plan on testing with standard item detail fields this week to see if the validation is trigger
I also will post the results
BD
Message 5 of 5

john.denner
Advocate
Advocate

These are excellent questions that I'm really interested in hearing the answers to. It seems that the initial transition from create behaves ever so slightly different from other transitions.

0 Likes