Workflow Soluiton

 View Only
  • 1.  Altiris Workflow generate a sequence Form Number

    Posted May 09, 2013 12:17 PM
    Hi all, I want to generate a Form number automatic and this number is unique and sequenced. The number format IT/0001. How can I do this ??


  • 2.  RE: Altiris Workflow generate a sequence Form Number
    Best Answer

    Posted May 09, 2013 01:10 PM

    I'm assuming you mean numbering of tasks here

    If you have Reporting turned on in your WF project (check Add Process Component on the Reporting tab of Project Properties), you can specify a prefix (in your case it's be IT) and a Pad Length (in your case I believe it would be 4). However, the slash character will be a hyphen: IT-0001.

    To do this just on the stream, you'd just use some String Handling components to build the number:

    Add New Data Element component to add a string "IT\"

    Add New Data Element component to add your integer counter... starting at 1

    Pad Text component to pad with 0's

    Merge Text component to merge your prefix with your padded counter.

    Hope that makes sense.



  • 3.  RE: Altiris Workflow generate a sequence Form Number

    Posted May 10, 2013 02:26 AM

    For the Add New Data Element component to add a string "IT\" and Add New Data Element component to add your integer counter, what data tpye should I select ?

     

     



  • 4.  RE: Altiris Workflow generate a sequence Form Number

    Posted May 13, 2013 01:19 PM

    To create a unique sequential value like this it's best to use a database. You need someplace to store the last used value.

    Is this a workflow project? If so why not use the process reporting id like recardo suggested?

    Otherwise, it depends on what you're trying to accomplish. Are you already saving any database records? If you have an identity column (auto number) you can pad that ID with 0's and add the IT\ to the front.

    Another option could be to use stored procedure generator to create a component that calls SP_GenerateNextReportID stored procedure in Process Manager database. Use value for 'type' parameter that won't interfere with other workflows, like a random guid. This will return the next # for a given 'type' passed in. Then you can pad that identity value it returns with 0's and add the IT\ to the front.



  • 5.  RE: Altiris Workflow generate a sequence Form Number

    Posted May 15, 2013 03:50 AM

    Hi rahmner,

    It is a workflow project , in the project property  I have click  Add Process Component, but I dont know how to get the number and show in my web form.Would you mind give  me more information  about this, thanks.