Is there documentation on how to create and use a matrix box? I have a form that uses a matrix box(created by someone else) and I do not understand how it works. The source table of the form is the Item table. The left side of the form displays all the items and the tablebox on the right displays the QOH for the items in all the Units of Measure. The source expression of the table box is: Calc_QOH_For_UOM(“No.”,CurrForm.ItemUOMMatrix.MatrixRec.Code,“Quantity on Hand”) The function Calc_QOH_For_UOM calculates the QOH for the Unit of Measure from the QOH(base UOM) using the conversion factor from the Item Unit of Measure table. My question is: Is there a way of subtotalling the QOH in each UOM based on the Material Type(new field in Item table) of the items. I need to display all items(one row per item displaying the QOH in each UOM) and then a row to display the subtotal for the material type. The table is sorted on Material type for this form. Pari Somasundaram.

Paris I know is bad that there is not even a mention of Matrix boxes in the ADG, but there is a page in the online help. It is under Controls and describes most of what you need to know. An Extract is here Creating a Matrix Box It can be confusing to create a matrix box for the first time. Here is a step-by-step instruction to guide you through the process (what will be created is a matrix box where both the vertical and the horizontal table are based on the Integer table, and the matrix cells display the product of the two integers in the records that intersect at that cell). Create a new form, and select the Integer table as the source table. Add a matrix box to the form. Give the matrix box control a name (by setting the Name property), and set the HorzGlue and VertGlue properties to Both. Insert a text box with the Number field from the Integer record as the source expression in the table part of the matrix box. In the property sheet of the matrix box control, select Integer as the MatrixSourceTable property. Add a text box without a source expression to the empty part of the matrix box control. Check the InMatrix property of this text box - it should be Yes. Add a text box without a source expression to the last empty part (the matrix heading) of the matrix box control. Check the InMatrixHeading property of this text box - it should be Yes. Add a source expression to the text box in the matrix heading (the last one added.) The source expression should point to a field from the MatrixSourceTable. If the matrix box was named Matrix, and the horizontal table is the Integer table, it could be: CurrForm.Matrix.MatrixRec.Number Add a source expression to the text box in the matrix. Here, it could be: Number * CurrForm.Matrix.MatrixRec.Number Hope This helps Paul Baxter

Pari, As you found out, the Matrix Box seems to be one of the least documented objects. It is even confusing to try to look at example code in the system. If I understand what you want is to create a matrix box with a list of items down the side and then group items by a field on the item table with this summary line appearing in the list of items. The only way I have found to do this is to create a Temporary table and have the Matrix Box use this table. When you add the records, add one for each Item and another for each sub-total. This option involves a fair bit of code as you have to customize the drill-downs, etc. Chris Krantz NCSD,NCSQL,MCSD,MCSE Microforum Inc. Toronto, Ontario, Canada

Create a new item unit of measure for the items (ex. call it “material”) and when making the calculation check if the item unit of measure code is the one you’ve set for the material… if it’s the one choosen, show in that colum the subtotal QOH for the item material instead of the QOH for a unit of measure. Regards, Alfonso Pertierra (Spain)apertierra@teleline.es

Hi Chris, I find your suggestion very interesting. Can you share how can I reference the matrix box to a table? For example, on the left column, I have Item No. and on the column header, I have column No. The temporarily table has field Item No., Column No, and Quantity. The matrix box is referenced to integer table and the form is referenced to Sales Line table with a filter on Document No. and Document Type. How can I reference the data in matrix box to the temporary table? Desperate for a solution…Thanks in advance.

I have a form that uses a matrix box (created by someone else) and I do not understand how it works. The source table of the form is the Item table. The left side of the form displays the item code and description on the right displays the Sales Amount for the items.

My question is:

I need to display the Purchase Amount instead of Sales Amount on the right side box…