[Question] Cannot choose"C+E Security IS" in a button in FormFlow?
System Information
- SDK Language: .Net
- SDK Version: 3.8.1.0
- Development Environment: webchat
Bot Info
- Bot name: Gaia
- Bot handle: kustobot
- App ID:
- Connected channels:
Issue Description
We compose buttons out of text in our but, in FormFlow. When the button contains "C+E Security IS" it's impossible to click it. We get "“C+E Security IS” is not an existing account name option." Then we specify "2" as the button it the first one, and it chooses a different button. Then we go back and specify 1 and it finally works. But we cannot click the "C+E Security IS".
Can you please fix?

Using quotes also doesn't work

This is not a question, it's an issue. Also any update on this?
Can you please share your code, we do not have enough info to help you without it.
@radennis Please upgrade your bot to v 3.9 and let us know if your issue is resolved. There was a problem with FormFlow fields defined with a Describe attribute, but no Terms: fixed by this PR https://github.com/Microsoft/BotBuilder/pull/2990 (and a few subsequent PRs)
Also, please show how you are defining this form in code, so we are able to reproduce the problem.
Thank you.
Thanks, I'll upgrade my bot and see if it helps.
Here's a code snippet of how I'm doing it:
private static Task<bool> DefineExistingPcCode(OnBoardForm state, Field<OnBoardForm> field)
{
foreach (var account in GetExistingPcCodes(state))
{
field
.AddDescription(account, account)
.AddTerms(account, account);
}
var newAccountChoice = "I have a different Pc Code";
field
.AddDescription(c_newPcCodeRequest, newAccountChoice)
.AddTerms(c_newPcCodeRequest, newAccountChoice);
field.SetType(null);
field.SetActive(IsExistingAccountChosen);
return Task.FromResult(true);
}
The issue seems to happen when the accout name starts with "C+.."
Hi, just wanted to update back that I tried upgrading to 3.9.0.0 and still get the same error.

Please let us know what can be done.
Thanks for the update, we are actively looking into this.
@radennis we are unable to repro the same behavior with the code given. Are you able to share your whole project? If not can you at least share the code for your form and what is the IsExistingAccountChosen code?
I've sent you the project code separately as we rather not publish it on the web. Here's the snippet you asked for:
public string GetAccountName()
{
return IsExistingAccountChosen(this)
? ExistingAccountName
: NewAccountName;
}
public static bool IsExistingAccountChosen(KustoOnBoardForm state)
{
var newAccountCondition = string.IsNullOrEmpty(state.ExistingAccountName) ||
state.ExistingAccountName.Equals(c_newAccountRequest, StringComparison.InvariantCulture);
return !newAccountCondition;
}
Thank you, I am waiting on approval to view the source.
Hi any update on this?
We were still not able to reproduce, I am awaiting approval in RAM to view the source to try to repro.
@radennis I was able to reproduce, It seems the '+' char in combination with spaces is the issue here. I'm still trying to pin down the exact cause, but if as a workaround, for now, can you try using the work "and" rather than '+' and see if that fixes the problem for you? another option is to use "C+E" rather than "C + E"
Thanks @JasonSowers for looking into this. Unfortunatelly I cannot change the content of the button since it is generated by getting the account name. Therefore when the account name if "C + E" I need to show the exact same string to the user...
I am still looking into this as a bug, I will update you when I know more.
Thanks for the update
You need to regex escape your string. The terms we match on our regex and the + is interpreted as a regex.