Declaring the integer array with some fixed length

studio

#1

how to declare the integer array with some fixed length. I am getting the out of range exception.


#2

Hi,

Check this link,


#3

iam getting the error for this .


#4

Are you splitting some date string and putting it in the array string, what is the actual code you are looking for.


#5

ya iam spliting the string and putting it to one array


#6

can you place the split string and the assign activity value part here


#7

now can you tell me what is the problem .

for integer i declared array_string = new integer(10){}
and string array as splitstring = {“a”} as default value


#8

Alter your code like this and try,

from_date.Split({"/"},System.StringSplitOptions.None)


#9

in assign part iam getting the nullpointerexception


#10

what is your increment variable, where it is initialized.


#11


is my decalration is correct


#12

For string array you can have like this,

New String(10){}


#13

I am not clear on your whole process,

Step1: you are splitting a date String to a string array
Step2: you are converting those string array values to integer array.

Step3: ??

If you want to do something with the date string, then you can post that directly to get clear and flexible solution.


#14

SplitStringAssign.xaml (13.2 KB)

cn you see this what is the probelm


#15

Change your “from_date” variable data type to string from Generic Value.


#16

from_date is variable from read cell so it is generic value . i change to .tostring while splitting but it is getting null reference exception


#17

ya got it sarathi . thank you :slight_smile: