キャンセル
次の結果を表示 
次の代わりに検索 
もしかして: 

Inserting 2D array to a 3D array

解決済み
解決策を見る

HI

I have a 3d string array 2x2x2 and I need to add another page to that array.

This new page is 2x3.

I am using "Insert into array" function and result is a 3D array 3x2x2, but it should be 3x2x3.

I mean, last inserted page was inserted but cut to 2x2

How can I do it ?

Regards

0 件の賞賛
メッセージ1/3
1,425件の閲覧回数
解決策
トピック作成者EDGAR_PLATRONICSが受理

Hi Edgar,

 


@EDGAR_PLATRONICS wrote:

I have a 3d string array 2x2x2 and I need to add another page to that array.

This new page is 2x3.

I am using "Insert into array" function and result is a 3D array 3x2x2, but it should be 3x2x3.

I mean, last inserted page was inserted but cut to 2x2


Did you read the LabVIEW help for InsertIntoArray? Especially the last paragraph on "Details"? That sentence about "changing only one dimension"?

 


@EDGAR_PLATRONICS wrote:

How can I do it ?


First change the size of the existing "pages" in your 3D array, then insert the new "page" array…

 

But: most often it is recommended to use BuildArray instead of InsertIntoArray - as is also in your case!

Replace InsertIntoArray by BuildArray to append your 3rd "page" and magically the 2D array is appended correctly to your existing 3D array…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 件の賞賛
メッセージ2/3
1,414件の閲覧回数

Thank you very much for your help

0 件の賞賛
メッセージ3/3
1,388件の閲覧回数