Visual Studio Development Bookmark and Share   
 index > Visual Studio Guidance Automation Toolkit > updating receipe arguments in a "ForEach" action
 

updating receipe arguments in a "ForEach" action

hi,
i'm using the SFT ForEach functionality to loop as set of actions. The problem i have is that the actions all use a receipe argument "ClassName", what i want to do is update this argument value at the beginning of each loop. (Each loop is basically a new database table, and ClassName=TableName) .

When I've tried to do this in an action within the loop it tells me the Dictionary service is readonly?

anyone got any ideas??

regards.
mickdelaney  Monday, July 16, 2007 3:27 PM

Hi Mick,

you have to specify in each action the following attributes:

ForEach, which have the IEnumerable instance.

CurrentInputName, which will have the current object in the iteration.

and the IterationGroup, in case that you want togroup the iteration.

regarding your question, you should specify the CurrentInputName wich will have the name of the action input property where the value that will be set.

maybe you have to modify your IEnumerable argument to do that.

hth.

jose.

Jose Escrich  Monday, July 23, 2007 2:26 PM

Hi Mick,

you have to specify in each action the following attributes:

ForEach, which have the IEnumerable instance.

CurrentInputName, which will have the current object in the iteration.

and the IterationGroup, in case that you want togroup the iteration.

regarding your question, you should specify the CurrentInputName wich will have the name of the action input property where the value that will be set.

maybe you have to modify your IEnumerable argument to do that.

hth.

jose.

Jose Escrich  Monday, July 23, 2007 2:26 PM

hi jose,

i've been using the ForEach's successfully with a group of actions each using the same ienumerable & currentinput name, what i wanted to do was have a group of actions in a foreach with the first action in the loop updating a bunch of receipe arguments that the rest of the actions then use. but i got the readonly issue when i tried to update the receipe arguments. i've since changed my design around so the actions dont have to update the receipe arguments, but it would have made for a simpler solution.

regards.

mickdelaney  Tuesday, July 24, 2007 7:56 AM
Hi!

Could you please post a code example of the foreach usage?
There isn“t much information on how to use it.

Thank you.
jrebelo  Thursday, August 21, 2008 12:13 AM

You can use google to search for other answers

Custom Search

More Threads

• Linking the Smart Client Software Factory with GuidanceAutomationExtensions
• Adding a recipe to a GAT package to create a view/presenter as in SCSF
• Programatically moving Projects within a Solution
• How to make item templates appear in "sub categories" in VS 2008
• The following arguments are required and don't have values
• Schema Discovery component
• will GATGAX work in VS 2008 beta2
• new to GAT
• Wizard - Field with optional value
• Custom Guidance Package Deployment