Skip to Content
author's profile photo Former Member
Former Member

problem with adding a column to a matrix.

hi all,

I need to insert a new column to an existing matrix item in the Stock Posting Form(item No 902)[Stock Management->Stock Transactions->Initial Quantities,Stock Tracking, Stock Posting->Stock Posting]

There exist many rows with data when the form is loaded.So to add a new column, I first cleared the matrix with Clear() method and was able to insert a new column.

The problem is,Clear() method clears all the data from the item matrix.How do i dispaly back all the data in the matrix again????

below is the code snippet...

Set oItm = objForm.Items("3")

Set oSAPMatrix = oItm.Specific

oSAPMatrix.Clear

Set oSAPMatrixCol_Wh = oSAPMatrix.Columns.Add("WH", it_EDIT)

oSAPMatrixCol_Wh.TitleObject.Caption = "WareHouse"

pls help....

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Jan 03, 2005 at 08:33 AM

    On some form containing matrix, it's possible to add column very easily.

    For example, on the Sale Order Form (Sales - A/R) :

    - Open it, and click on Tools, Form Setting (CtrlShiftS)

    -Click on the tab "Table Format", and then you can choose the available column you may add.

    On the specific form Stock Posting, you can't add columns in the way I'm describing, but it seems that WareHouse is a parameter from the previous form, and the value is out of the matrix, so you don't need to add it.

    Happy new year

    S├ębastien

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Dec 31, 2004 at 09:22 AM

    This is a good question and unfortunately one that I don't think has an easy answer.

    Your best bet is to hide the current matrix, and create a new matrix with your new column and then copy the information in the original matrix into the new matrix.

    Hopefully in the future we will be able to

    matrix.clear()

    and then when we have added our new column

    then we can go

    dbDataSource.query()

    and the system matrix will be refilled from the dbDataSource.

    Hope this has helped,

    Cormac

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.