Combo Box question
I'm trying to set up a workflow using a combo box to select a text string. How do I pass the text string to the next activity, such as a prompt? When using a text box as input, I simply select the variable name in the Output Arguments part of the form. When I try to do this with a combobox, I get an error that says something along the lines of invalid L value expression: reference expressions cannot end with conversion. I found one related discussion item on the forum, but it was talking about what I think is the code behind the workflow.
-
"I'm trying to set up a workflow using a combo box to select a text string. How do I pass the text string to the next activity, such as a prompt? When using a text box as input, I simply select the variable name in the Output Arguments part of the form ."
Try changing the type of variable from a string to an object. Then when you want to use it in the next step like a query - to convert it to a string:
"NAME= '" +name.ToString() + "' "
That might be the answer.
Sonia
0 -
I think that was the solution to the combobox problem. Now I'll work on the rest of them and see if I can get the whole workflow to complete.
Thanks!
Don
0 -
Don,
I got this error message too, when I copied a working workflow with combo box to another similar workflow using the 'save as' option. I added in a new variable of type string to replace the existing one, and this is where the problems started! I found the easiest way to get rid of the problem was to do a search and replace in a copy of the original xaml file that works. For some reason it gets hung up on adding new variables of type string to an existing workflow. All I did was to try to essentially remove the variable and replace with a name that made more sense. I tried renaming the variable and this did not work either - same error.
I tried the object type, and that threw another error in the query section - but Sonia's post would solve that one.... but I'm still confused as to why I'm getting the error to start with.
Not an answer to your problem - but thought I'd add my experiences to the post ; )
cheers
Gareth
0 -
Has anyone figured out a solution to this? I am CONSTANTLY getting this error when adding or modifying variables in the display form. It seems sometimes the red exclamation point goes away if I change the Direction Type of the variable from In/Out > In > In/Out. Other times I have used the simulator (if it isn't in the first step of the sequence.
"Invalid L-Value Expression: Reference Expressions cannot end with Conversions."
All of my other variables (as of right now) are ok, and are set up exactly the same way and and are all strings.
0 -
Another workaround. Exit out of your .xaml file and come back in. Error no longer there...
0
Du måste logga in om du vill lämna en kommentar.
Kommentarer
5 kommentarer