locked
Early advice starting a project re-hosting Workflow to generate script code RRS feed

  • Question

  • The company I work for writes a tremendous amount of scripting code which gets called from specialized applications to parse messages, perform tasks etc. Most of it is in VBScript or another custom scripting language. And though this code is written by hand for each installation, there is a large amount of boiler-plate code and tasks that get repeated over again. Eg. field checking, database lookups, email alerts. Often times this code is modified by people with very little programming experience.

    I was hoping to write a program that would allow a non-programmer to graphically generate these scripts, and was thinking re-hosting Workflow Foundation would provide the perfect user interface for this. I figure creating actions for the loops, conditionals, lookups, alerts. And was planning on creating a number of expression editors for the various situations. 

    But I have little experience with WF and am worried I might be headed down a path where I get seriously stuck. Any advice on the feasibility of this or any help with my questions would help more than you know.

    Is the only way I can get to the created workflow will be via reading the xaml file it creates? Or can/should I create code behind the actions that creates the target script. Will this even work for closing statements (Eg. End If)? Will I be able to create multiple expression editors context sensitive for the different actions? Can I customize the user interface much, eg can I replace the variables and imports tabs at the bottom or float/dock the properties and activities windows?

    I have found a few basic guides for re-hosting the control (1, 2, 3, 4). But would appreciate any advice, links, example projects you would be willing to offer.

    Many thanks in advance,
    Matthew.

    Thursday, January 12, 2012 10:12 PM

Answers

  • Hi,

    ->Is the only way I can get to the created workflow will be via reading the xaml file it creates?

    You can also create workflow declaratively in code

    http://msdn.microsoft.com/en-us/library/dd744848.aspx

    ->Or can/should I create code behind the actions that creates the target script. Will this even work for closing statements (Eg. End If)? Will I be able to create multiple expression editors context sensitive for the different actions? Can I customize the user interface much, eg can I replace the variables and imports tabs at the bottom or float/dock the properties and activities windows?

    In this case, you'll need to create custom activity and custom activity designer to fit your requirement.

    http://msdn.microsoft.com/en-us/library/dd759030.aspx

    Hope this helps, thanks.


    Leo Tang [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    • Marked as answer by LeoTang Saturday, January 21, 2012 11:24 AM
    Monday, January 16, 2012 7:45 AM