Make var declared in User Code accessible to parameters?
Posted: Mon Aug 12, 2013 1:51 pm
I am trying to get an int variable declared within a user code action (not module) to be accessible for parameter binding so I can access that variable's value in another recording.
I was able to do this for a new code module by declaring the variable in the constructor, but since the user code actions use partial classes, I am not sure how I would be able to get a variable created within that user code action to be accessible by other recordings.
I have attempted to include the following in the partial class:
But when I try to bind it to a parameter, it doesn't show in the dropdown list of module variables.
Any way that I can achieve this?
I was able to do this for a new code module by declaring the variable in the constructor, but since the user code actions use partial classes, I am not sure how I would be able to get a variable created within that user code action to be accessible by other recordings.
I have attempted to include the following in the partial class:
Code: Select all
public partial class ChangeSortOrder
{
public int newSortOrder {
get { return newSortOrder; }
set{ newSortOrder = value; }
}
Any way that I can achieve this?