Getkeywords Error

Getkeywords Error

js75CAD
Enthusiast Enthusiast
542 Views
1 Reply
Message 1 of 2

Getkeywords Error

js75CAD
Enthusiast
Enthusiast

Hi,

 

I was wondering if anyone knows why I can't seem to have two keyword options with the same starting character?

 

As an example:

 Dim pKeyOpts3 As PromptKeywordOptions = New PromptKeywordOptions("")
                    pKeyOpts3.Message = vbLf & "Select Asset Owner"
                    pKeyOpts3.Keywords.Add("Council")
                    pKeyOpts3.Keywords.Add("DTMR")
                    pKeyOpts3.Keywords.Add("Energex")
                    pKeyOpts3.Keywords.Add("Ergon")
                    pKeyOpts3.Keywords.Add("Private")
                    pKeyOpts3.Keywords.Add("Other")

 

This works fine, but no matter how many times I choose Ergon, it picks Energex. I can't seem to stop it. Aside from the same starting character nothing else matches so why does it do this?

 

Surely, someone has had this happen before but i cannot find any information on it. Any and all help would be appreciated.

0 Likes
Accepted solutions (1)
543 Views
1 Reply
Reply (1)
Message 2 of 2

norman.yuan
Mentor
Mentor
Accepted solution

Isn't it very obvious that these 2 keywords have the same capital character "E" that user is expected to enter to select the keyword?

 

In your case, you need to choose a different character in the work as the capital one, like:

"Energex" and "eRgon". Or you can use 2 capital characters for one of the keywords, like "Energex", "ERgon" (of course user need to enter 2 capital characters to select that keyword). The point is that the capital character(s) in the keywords matters.

 

Norman Yuan

Drive CAD With Code

EESignature