10-12-2006 01:52 PM
10-12-2006 01:58 PM - edited 10-12-2006 01:58 PM
Message Edited by Day on 10-12-2006 02:59 PM
10-12-2006 02:00 PM
Makes sense?
10-09-2008 06:42 AM
10-09-2008 06:43 AM
10-09-2008 06:57 AM
I posted three times but there is no display of message I am trying the fourth time.
I tried inserting an element into a 2d array ata sepecified location but the resultant array doesnot seem to change.Why could it be?
regards
Sivanand
10-09-2008 07:17 AM - edited 10-09-2008 07:22 AM
You cannot replace an element of an array if that element does not exist.
For exemple trying to replace element on the 4th row and 1st column of a 3x3 array will result in the same array as output
10-09-2008 10:06 AM
siva0182 wrote:I tried inserting an element into a 2d array ata sepecified location but the resultant array doesnot seem to change.Why could it be?
We cannot debug an image, so please attach a real VI instead to make things easier for all of us. 🙂
There is no way to determine what's wrong with your VI, because we don't know the values of any of your controls. One possibility (as the above post suspects) hs that you are indexing outside the input array.
(On a side note, you typically would use "stop if true" for a loop condition. Also such a loop that just updates user input would need a small wait (e.g. 100ms) to make it play well with everything else running on your computer. You should also avoid overlapping wires. Right now it is impossible th tell what's connected to where :()
10-10-2008 04:36 AM
Thanks for the suggestions and tips.After I intialized the array I was able to use the replace required elements in the array.
But after every time the array changed the next time we need to send/pass the new array into replace array subset vi.
So I used a case structure to decide on if it is iteration 1 or higher iteration and if it is iteration no 1 I sent the newly intialized array and if it is higher iteration i sent thenew array (output of replace array subset) back to the array sunset thro the case structure.
Thanks for all people concerned.
regards
Sivanand Somasundaram
10-10-2008 10:46 AM
siva0182 wrote:But after every time the array changed the next time we need to send/pass the new array into replace array subset vi.
So I used a case structure to decide on if it is iteration 1 or higher iteration and if it is iteration no 1 I sent the newly intialized array and if it is higher iteration i sent thenew array (output of replace array subset) back to the array sunset thro the case structure.
Could you show us your actual code, because many of your terms are poorly defined (send/pass? Send back? sunset???).
I don't relly understand what you are doing.
(Typically you would use a shift register and either initialize it outside the loop or in a case wired to the "first run?" primitive.)