MultiArray XS

This forum is meant for anything you would like to share with other visitors
Post Reply
Frank Müßner
Posts: 280
Joined: Sat Dec 12, 2015 2:22 pm
Location: Germany

MultiArray XS

Post by Frank Müßner »

Hello,

when create a Array with String i write:

Code: Select all

Local wert as String[]
    wert:=<String>{"Value1","Value2"}
How to do with MultiArray´s?
I have Problems with this code:

Code: Select all

 Local multiwert as String[2,2]
    multiwert:=<String>{{ "one", "two" }, { "three", "four" }}

Code: Select all

XS9002	Parser: unexpected input '2' expecting {RBRKT, COMMA}		
where is my mistake?
Frank
User avatar
wriedmann
Posts: 3755
Joined: Mon Nov 02, 2015 5:07 pm
Location: Italy

MultiArray XS

Post by wriedmann »

Hi Frank,
some times ago it does not worked, and it was a known issue. I don't know if this was fixed.
Wolfgang
Wolfgang Riedmann
Meran, South Tyrol, Italy
wolfgang@riedmann.it
https://www.riedmann.it - https://docs.xsharp.it
User avatar
SHirsch
Posts: 286
Joined: Tue Jan 30, 2018 8:23 am
Location: Germany

MultiArray XS

Post by SHirsch »

Hi Frank,

maybe this is what you need.

Code: Select all

    LOCAL multiwert AS STRING[][]
    multiwert:=<STRING[]>{ <STRING>{"one", "two"}, <STRING>{"three","four"} }
Stefan
User avatar
robert
Posts: 4520
Joined: Fri Aug 21, 2015 10:57 am
Location: Netherlands

MultiArray XS

Post by robert »

Frankj,
Initializing multi dimensional typed arrays is not supported yet.

Robert
XSharp Development Team
The Netherlands
robert@xsharp.eu
Frank Müßner
Posts: 280
Joined: Sat Dec 12, 2015 2:22 pm
Location: Germany

MultiArray XS

Post by Frank Müßner »

Hi to all,

thank you for the Information.

@Stefan, i will try your code Sample.

Thanks.
Post Reply