Matrix Problem--Urgent.

AAshokAAshok Member Posts: 53
Hi Experts,

Can anyone help me please ..........

I have created one matrix form, where the user can enter the values at columns, but when i enter the values then the entered value is updated in all the remaining columns.

for ex.

I have one item 1001 with different size codes like 10, 12, 14, 16...

when i entered a value ( ex. 6 or 7 anything ) in combination at cell position 1001 & 12 . then the value is updating in all the cell positions.

Please help me..


](*,) ](*,) ](*,) ](*,) ](*,) ](*,)

Comments

  • kapamaroukapamarou Member Posts: 1,152
    Most Probably you are updating a Variable (Text?) which is the source for the matrix...

    I think value typed in the cell must be stored in the source table so that the cell value will read the new value and display it...
  • AAshokAAshok Member Posts: 53
    Hi,

    Thankx for reply.

    Actually i have created a new variable (i.e Cellvalue) and the sourceexpr for the column side textbox is cellvalue .

    Please let me know if u want more information.
  • kapamaroukapamarou Member Posts: 1,152
    When the matrix loads does it display any data from a table or is it used only for input?
  • AAshokAAshok Member Posts: 53
    hi,

    This is only for one time input. once the form is closed then the values are erased.

    I have written code in cellvalue - onvalidate () trigger to insert into a temporary table.
    and in onformat() i am displaying the value from the temp. table
  • kapamaroukapamarou Member Posts: 1,152
    Have you tried to add code on the trigger that validates the value entered to store the value in the temporary data and after that reload the data from the table? The idea is that since you are changing the value of the Matrix source variable it will be displayed in all cells. You will have to reload all the matrix data after the validation. I haven't used matrix for data input before, but this is the general idea behind the matrix control.
  • AAshokAAshok Member Posts: 53
    Hi,

    Thanks for reply.

    I have added code to insert to temp table. and the data is also displaying.

    but my prob is when i open a form the initial values will be Null and when i enter the value 6 in (size code ex. 10 ) then the value in the remaining size codes 12 14 16 .. are also automatically filled with same value,

    In short to say

    if we have a single row with 5 columns , if i enter a value in 1 column then remaining 4 columns also updated with this value. if i change 3 column then remaining 3 are updated with new value.
  • kapamaroukapamarou Member Posts: 1,152
    Maybe posting some lines from your code would help...
  • kinekine Member Posts: 12,562
    1) Do not use the OnFormat to change what to display. This trigger is for something else
    2) You need to "fill" the displayed variable (variable used in the edit box of the matrix table) with appropriate value in OnAfterGetRecord of the MATRIX Table control. (not on the OnAfterGetRecord of the whole form).
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • AAshokAAshok Member Posts: 53
    Hi,

    Thanks i will try this once..
Sign In or Register to comment.