Dialog Options Array Splits Choices

Discuss all problems you have with Servoy here. It might help to mention the Servoy version and Operating System version you are using

Dialog Options Array Splits Choices

Postby john1598360627 » Sat Jul 15, 2023 12:14 am

ISSUE
https://wiki.servoy.com/display/DOCS/di ... ptionArray)

Using the Servoy dialog plugin I noticed a problem. For whatever reason, whenever a ',' character appears the option is split. This applies to any category of the dialog. Now, when making the buttons (ok vs cancel) it's not that big of a deal I guess.

However, it's also being applied to options within an Array.

EXAMPLE
Code: Select all
   
function ini_dialog(){
      title = 'NEW PI'
      
      message = 'Add a new PI to the fund. Enter Name:'
      
      response = plugins.dialogs.showSelectDialog( title, message , arr_pi )
   }


The arr_pi is an array filled with first and last names split with commas.

ie

arr_pi[0] = Elizabeth, Sarah
arr_pi[1] = Hunter, Smith
(etc...)

However, the commas within each array item cause it to split apart.

So within the selector dialogue options it looks like;
Elizabeth
Sarah
Hunter
Smith


When it SHOULD look like this;
Elizabeth, Sarah
Hunter, Smith



As for why this is happening, when I application.output the array I noticed that it looks like this;
Code: Select all
arr_pi[Elizabeth, Sarah,Hunter, Smith]

Maybe that's why it's automatically splitting the options once it sees a comma? Cus it can't interpret the actual columns? Just a guess.


HELP

Is there any way to disable this behavior? I'm not really sure what the purpose of it is anyways. I just want one index per dialog selection. No automatic splitting whenever a comma appears.
john1598360627
 
Posts: 175
Joined: Tue Aug 25, 2020 3:03 pm

Re: Dialog Options Array Splits Choices

Postby sean » Fri Aug 11, 2023 7:01 pm

Hi John,

Please file a case at Servoy Support.

I believe this method takes an array or strings directly in the arguments object they strings in the array are being split on the comma.

Best,
Sean
Software Engineer
Servoy USA
sean
 
Posts: 370
Joined: Mon May 21, 2007 6:26 pm
Location: USA

Re: Dialog Options Array Splits Choices

Postby kwpsd » Mon Aug 14, 2023 12:13 am

Created Support Ticket: SVY-18482
Kim W. Premuda
San Diego, CA USA
User avatar
kwpsd
 
Posts: 687
Joined: Sat Jul 28, 2007 6:59 pm
Location: San Diego, CA USA

Re: Dialog Options Array Splits Choices

Postby john1598360627 » Thu Nov 23, 2023 12:00 am

I finally updated to the new release that apparently fixed it.

Double checked to see and it did seem to be fixed. Thank you!

I'll be on the lookout if I notice any other issues with the plugin and make sure to report them if necessary.
john1598360627
 
Posts: 175
Joined: Tue Aug 25, 2020 3:03 pm


Return to Discuss possible Issues and Bugs

Who is online

Users browsing this forum: Google [Bot] and 24 guests

cron