How to update AR Invoice Matrix (UDF)

Hi,
I want to load the matrix data to a custom form. After user updates the custom form data. Then, get back the data to matrix.
Now I am using the following code:
- Get matrix value
For i = 1 To mMatrix.VisualRowCount
   Dim tmp as stsring = mMatrix.Columns.Item("U_UDF1").Cells.Item(i).Specific.value
   Dim tmp as stsring = mMatrix.Columns.Item("U_UDF2").Cells.Item(i).Specific.value
Next
- Update matrix value
For i As Integer = i To mDataTable.Rows.Count - 1
   mMatrix.Columns.Item("U_UDF1").Cells.Item(i + 1).Specific.value = mDataTable.GetValue("Value1",i)
   mMatrix.Columns.Item("U_UDF2").Cells.Item(i + 1).Specific.value = mDataTable.GetValue("Value2",i)
Next
Have any better solution? If the matrix's sorting order is changed, all the data will be wrong. How can solve this problem?
Regards,
On

The problem you are facing is because both AR Inv and AR Res Inv are stored in the same table OINV. The AR RESERVE Invoice is differentiated by the OINV field isINS which will have a Y when the Invoice is an AR Invoice. Checking this field is they approach.
1.  Add a database field (let us presume this is Field_341)
Table: AR Invoice
Field: isINS - Reserve Invoice
2. Add a Formula Field
Formula: Field_341 == "Y"
3. Add another Formula Field
Formula: Field_341 != "Y"
4. Add another Text Field:
AR Reserve Invoice
To the Text field which has INVOICE link the formula in Step 3
To the Text field which has AR Reserve Invoice link the formula in Step 2
THIS WILL WORK

Similar Messages

  • How to update excise invoice values after migo.

    Hi Guru's,
    I have checked the forum. but did not get exact solution.
    Here im having the problem with  bapi  BAPI_GOODSMVT_CREATE . This bapi don't have the structure to update excise invoice values.
    I have one bapi  'BAPI_EXCINV_CREATE_FROMDATA'  to update the excise duty, but in that also i didn't find the structure
    'J_1IEXITEM'  to update the ECS value ( field is 'total_ecs').
    Please help me on this,Thanks in Advance...
    Regards
    Naren

    Hi Krishna
    Do not do excise invoice capture during 103. At that time select the option "No excise entry". Then capture excise invoice during 105.
    The system messge " No selectable items for this document" is prompted since the preceeding document is already assigned with invoice.
    Try this and give feedback.
    regards
    sairam akundi

  • How to update PO invoice plan?

    Dear all,
    I need to update Start-date and End-date of PO's invoice plan, the two dates storage in a Z-table.
    Anyone who can tell me which function module I should use or how I can achieve this functionality.
    Thanks very much!
    Best Regards.

    >
    kumar kaduri wrote:
    > Hi,
    >
    > You didn't mention about the link of your Z table to PO Invoice. I think it must be updated in any user Exit while crating PO. If not there must be some Z program for it. Even z program doesn't exist, you need to write a zprogram if you want to update it after creation of PO Invoice or if you want to update your z table while creating invoice, you need to write code in user exit.
    >
    >        Kumar.
    >
    > Edited by: kumar kaduri on Jun 29, 2009 11:17 AM
    Hi Kumar
    Sorry I haven't describe it clearly.
    First I create a PO with Invoice Plan, but the Start-date and End-date is estimated.
    Then vendor will send the actual dates of invoice plan, and these data will be stored in Ztable.
    Finally a Zprogram will be executed to update the Start-date and End-date of the invoice plan.
    I need to write code in the Zprogram to realize this functionality.
    Thanks.

  • How to update the condition price in sales order while creating the invoice

    Hi,
    How to update the condition price in the sales order to carry out the new price while creating the invoice?
    While creating the invoice it should update the condition price in sales order.
    Thanks,
    Balaram

    No, pricing is not there in delivery.
    I found an exit for VF01transaction where we can update the price in order.
    Can you please tell me how to update the price if I have the order, material numbers and conditions number?
    Thanks,
    Balaram

  • How to add data to A/R Invoice Matrix via DI API ?

    Hello everyone,
    Could you please answer to my question?
    I insert new button on SAP system form (A/R Invoice). I want to add new line with item code at Invoice Matrix when I click the button.
    Thanks,
    KZT

    Hi Kyaw,
    If you want to update an Existing Sales Invoice Document then I am sorry but it is not possible.
    But if you want to create a whole New Document with DIAPI then try this:
    Dim oInvoice As SAPbobsCOM.Documents
                    oInvoice = ocompany.GetBusinessObject(BoObjectTypes.oInvoices)
                    oInvoice .CardCode = "C001"
                    oInvoice .DocDate = "Date"
                    oInvoice .DocDueDate = "Date"
    oInvoice .Lines.ItemCode = "ItemCode"
                oInvoice .Lines.Quantity = 1
                oInvoice .Lines.Price = 100
                oInvoice .Lines.DiscountPercent = 2
                oInvoice .Lines.TaxCode = Tax
                oInvoice .Lines.Add()
    Finally try to add using oInvoice .Add()
    Hope it helps.
    Thanks & Regards
    Ankit Chauhan

  • How to updated matrix into related table?

    hi, can anyone help me below coding how to updated matrix into related table?
    Thank you.
                For rowNum = 0 To oMatrix.RowCount
                    oRecordset.Fields.Item("Code").Value = oMatrix.Columns.Item("DSCode").Cells.Item(rowNum).Specific.Value
                    oRecordset.Fields.Item("Name").Value = oMatrix.Columns.Item("DSName").Cells.Item(rowNum).Specific.Value
                    oRecordset.Fields.Item("U_RPTC").Value = oMatrix.Columns.Item("DSReport").Cells.Item(rowNum).Specific.Value
                    oRecordset.Fields.Item("U_USRC").Value = oMatrix.Columns.Item("DSUser").Cells.Item(rowNum).Specific.Value
                    oRecordset.MoveNext()
                Next

    For Fast Matrix Loading you can user some thing like this.
            Dim Column As SAPbouiCOM.Column
            Dim Matrix As SAPbouiCOM.Matrix
            Dim Table As SAPbouiCOM.DataTable
            Table = oForm.DataSources.DataTables.Add("Documents")
            Table.Columns.Add("Code", SAPbouiCOM.BoFieldsType.ft_Integer)
            Table.Columns.Add("Name", SAPbouiCOM.BoFieldsType.ft_Integer)
            Table.Columns.Add("U_RPTC", SAPbouiCOM.BoFieldsType.ft_AlphaNumeric, 255)
            Table.Columns.Add("U_USRC", SAPbouiCOM.BoFieldsType.ft_AlphaNumeric, 255)
            Matrix = oForm.Items.Item("MatrixUID").Specific
            Column = Matrix.Columns.Item("Code")
            Column.DataBind.Bind("Documents", "Code")
            Column = Matrix.Columns.Item("Name")
            Column.DataBind.Bind("Documents", "Name")
            Column = Matrix.Columns.Item("U_RPTC")
            Column.DataBind.Bind("Documents", "U_RPTC")
            Column = Matrix.Columns.Item("U_USRC")
            Column.DataBind.Bind("Documents", "U_USRC")
            Table.ExecuteQuery(SQLQuery)
            Matrix.LoadFromDataSource() 'Load The Data to the Matrix
    To pull the data form the display back to the Table you can use this
    Matrix.FlushToDataSource()

  • How to update UDF in OID11g(OIM 11g configured with LDAP SYNC)

    Hi All,
    I have configured OIM11g with LDAP SYNC and it is working fine. i have added some UDF on the user creation form and the same attributes has been created on OID as well. Now, when i create users on OIM with these custom attributes the values are not getting updated on OID resource, can anyone please let me know how to update these attributes on OID?
    Thanks in advance,

    to Update a UDF you must assign a copy value adpter in Lookup.USR_PROCESS_TRIGGERS(design console / lookup definition)
    eg.
    CODE --------------------------DECODE
    USR_UDF_MYATTR1----- Change MYATTR1
    USR_UDF_MYATTR2----- Change MYATTR2
    Edited by: Lighting Cui on 2011-8-3 上午12:25

  • How to update 'number of notes' field in UDM_SUPERVISOR in Invoices tab

    I made program to create the notes using UDM_RSM_CREATE function module.
    it is creating notes for selected customer and invoices and shows perfect in Notes tab, but when i see on Invoices tab there is column by the Name: Number of Notes'  this is not getting updated with the counter.
    Can any one please let me know how to update the number of notes column.
    if there are 10 notes in notes tab for the particular Invoice then the Number notes column should show as '10'.
    Please ask me if it is not clear.
    Thanks,
    Maheshkumar Gattu

    Hi Mahesh,
    I AM also trying to mass upload Notes Data and Promise to Pay data using FM "UDM_RSM_CREATE" and  "FDM_P2P_CREATE" respectively from an excel file. .
    1.My query in fm UDM_RSM_CREATE is from where will i get parameter   i_rsm_guid ,as that cannt be generated from excel file user data.
    2. My second query is once i generated case_guide via FM FDM_P2P_CREATE , its a succesfull return tat means data should appear in promise to pay but that is not happening.
    3. I got a help that after successful generation of case guid from FDM_P2P_CREATE I need to use one FM for customer create contact i.e "FDM_CCT_CREATE"  then only data will appear in collection management ....but I am not the parameters of this FM.
    Can you guide me in it. If possible can you share ur logic if my requirement is same as your. Its very critical issue for project go live.
    Thanks a lot.

  • How to update PAYMENT tables manually from backend after invoice creation.

    Hi,
    I am Financial beginner. how to update payment details from invoices using backend in P2P.
    Thanks and Regards,
    Srikanth

    I have created a invoice and updating payment details.
    I just need small information regarding payaments.
    After invoice we create payments using validate, pay in full.
    But What actually happens when we do validate and pay in full.
    and what are the fields and tables effected in this process.FAQ: Common Tracing Techniques in Oracle E-Business Applications 11i and R12 [ID 296559.1]
    R12 Docs
    http://docs.oracle.com/cd/E18727_01/index.htm
    eTRM
    http://etrm.oracle.com/
    Thanks,
    Hussein

  • How i get data in matrix grid from A/P Invoice

    How i get data in matrix grid from A/P Invoice before click add button

    Hi,
    Are you trying to read the data in the matrix of a system form? Then you only have to look for the matrix with the ID you can see by visualising the System Information in B1 and then directly read from the matrix cells (using columns element in matrix), the DBDataSources are not filled in until the document has been added to the database.
    There are many messages in this forum talking about how to read information in matrix item, just make a search for it.
    Hope it helps
    Trinidad.

  • How to update pricing condition type in a cancelled invoice?

    I have one invoice(let say invoice number 01) which did not posted any accounting documents because one condition type in pricing procedure didn't had any record at the time of creation of invoice. so i cancelled the previous invoice and maintained the condition record of the condition type and again invoiced(let say invoice number 02) the delivery which posted the correct accounting documents.
    Now the problem is that when i am going to the invoice number 01 in change mode and trying to update the pricing procedure by going to item level then the system is now allowing to update the pricing procedure as the UPDATE TAB is grayed out and i cant click on it. (is it because for invoice nummber 01 follow on cncllation invoice has been created? or any other reason and is ther a solution for this?)
    action required: i want to update the invoice number 01.

    Dear Manpreet500,
    If the invoice not having the accounting document no need to cancell that invoice.
    In your case you might have done like this without cancell the invoice 01.
    -->Create condition record for the condition type which was missed while creating invoice.
    -->After creation of condition record you just go to VF02 transaction enter invoice 01 then go to condition tab here you can find the Update tab click on the Update tab now system will take you to the Pricing selection screen here you select B- Carry out new pricing now system will consider the condition record for the missed condition type.
    Now you can release the 01 invoice manually by clicking on green Flag.
    You can not update the 01 invoice may be due to the subsequent document cancelled invoice.
    I hope this will help you,
    Regards,
    Murali.

  • How to block an invoice if the value of a post is zero?

    Hello,
    In the rules of copy we use the field " Pricing type " with the value " C = Copy manual pricing elements and redetermine the others ".
    The order is complete and the price of the post is not equal to zero.
    During the invoicing the system makes a new search for the prices in the tables of conditions.
    If the condition does not exist in the date of invoice the post takes the zero value.
    How to block an invoice if the value of a post is zero?
    There is no incompleteness procedure for the invoice.
    The value of the post is the result of several conditions and we cannot make them obligatory.
    Who already has to meet this problem with the recalcul of the price in the invoicing?
    Best regards
    Frédéric Blaise
    e-Kenz S.A.
    Luxembourg

    Hi,
    It is not the total invoice which is equal to zero but only one post.
    As I explained it at first the problem is the following one:
    In the rules of copy we use the field " Pricing type " with the value " C = Copy manual pricing elements and redetermine the others ".
    he order is complete and the price of the post is not equal to zero.
    +During the invoicing the system makes a new search for the prices in the tables of conditions.
    If the condition does not exist in the date of invoice the post takes the zero value.
    I look for a solution to block the creation of the invoice if a post only is equal to zero after the updating of the prices.
    Thanks
    Frédéric

  • How to update Tr code FB02   and update the field reference key1 (bseg-xref

    Can any body
    help me how to update   Tr code   fb02
    and  update the field  reference  key1 (bseg-xref1)  with the interest amount
    calculated.
    Below i have  written My  program  flow logic
    The program should read the open items i.e debit items in the customer account,
    Based on the  invoice date and customer payment terms  calculate the due date and then the  interest should be  calculated on that item based on the due date.
    Use the  transaction  fb02  and update the field  reference  key 1 (BSEG-xref1)
    with the interest amount calculated
    Only  consider  customers whose  interest indicator  knb1-vzskz = 'vk'.
    Interest is to be  calculated for every  30  days
    at the rate of  1% .please see example below.
    Document date is 01.01.2007
    for amount  1000SGD   payment  term  7  days
    It becomes  due  on  08.01.2007
    until  06.02.2007 you should not  consider  for calculation of interest
    SGD  on   7.02.2007 run you can consider this  item for interest calculation

    Hi Robert,
    Thanks for answering.
    I am looking at Ref 2 should flow automatically to clearing document from the accounitng document for billing.
    Ex: Billing document is created and accounted. Ref 2 is AB
    Now when receipt is accounted for this biling document this AB should flow automatically to Ref 2 field.
    Thanks
    NNS.

  • Changing column value on every row in invoice matrix

    Hi,
    I'm trying to change the value of the GLaccount column for every row in the invoice matrix when the user changes the document owner.  The code seems to work for the first row  but then on other rows I get a message that says the item can't be changed because it can't get focus.  I know there are similar posts on the forum already, but nothing that solves this problem that I can see.
    My code follows:
            <B1Listener(BoEventTypes.et_CHOOSE_FROM_LIST, False)> _
            Public Overridable Sub OnAfterChooseFromList(ByVal pVal As ItemEvent)
                Dim ActionSuccess As Boolean = pVal.ActionSuccess
                Dim form As Form = B1Connections.theAppl.Forms.Item(pVal.FormUID)
                Dim item As Item = form.Items.Item("222") 'document owner
                Dim item2 As Item = form.Items.Item("38")
                Dim Matrix As Matrix = CType(item2.Specific, Matrix)
                Dim userID As String
                userID = ChooseFromList_Value(pVal)
                If ActionSuccess And pVal.InnerEvent Then
                    ChangeMatrixAccounts(Matrix, userID)
                End If
            End Sub
        Friend Function ChangeMatrixAccounts(ByVal zMatrix As SAPbouiCOM.Matrix, ByVal zDocOwner As String) As ReturnStatus
                For x = 1 To zMatrix.RowCount
                    Dim cell As SAPbouiCOM.Cell = zMatrix.Columns.Item("159").Cells.Item(x)
                    Dim oedit As SAPbouiCOM.EditText = zMatrix.Columns.Item("159").Cells.Item(x).Specific
                    cell.Click(SAPbouiCOM.BoCellClickType.ct_Regular) 'force focus, I hope
                    ChangeRevenueAccountInCell(oedit, WhseGLLocCode)
                Next
    end function
        Private Function ChangeRevenueAccountInCell(ByVal zGLAcct As SAPbouiCOM.EditText, ByVal zWhseGLLocCode As String) As ReturnStatus
            Dim tempwork(2) As String
            'change the value of the matrix cell passed in to the new gl acct
            tempwork = zGLAcct.Value.Split("-")
            <b>zGLAcct.Value = tempwork(0) & "-" & tempwork(1) & "-" & zWhseGLLocCode</b>
            Console.Write(" Changed GL value")
        End Function
    Is there more to it than that?  -- THANKS!

    Hi John,
    I don't know if this is of use, but here's the code I used to set the project code value on each row of a marketing document through the UI (which is similar to what you are looking to do). The Project Code column needs to be visible and editable for this to work:
    Private Function SetProjectCodeOnRows(ByVal oForm As SAPbouiCOM.Form, ByVal oMatrix As SAPbouiCOM.Matrix, ByVal sProjectCode As String) As Boolean
            Dim bSuccess As Boolean = True
            Dim sItemCode As String
            Dim sExistingProjCode
            Dim i As Int32
            Dim oCol As SAPbouiCOM.Column
            Dim oEdit As SAPbouiCOM.EditText
            Dim oFolder As SAPbouiCOM.Folder
            'Select the Contents folder before updating any project codes
            oFolder = oForm.Items.Item("112").Specific
            oFolder.Select()
            For i = 1 To oMatrix.RowCount
                Try
                    ' Check to see if an item code has been entered (last line will always be empty)
                    oCol = oMatrix.Columns.Item("1")
                    oEdit = oCol.Cells.Item(i).Specific
                    sItemCode = oEdit.String
                    ' Read the project code from the row
                    oCol = oMatrix.Columns.Item("31")
                    oEdit = oCol.Cells.Item(i).Specific
                    sExistingProjCode = oEdit.String
                    If sExistingProjCode = "" And sItemCode <> "" Then
                        oEdit.Value = sProjectCode
                    End If
                Catch ex As Exception
                    m_sboApp.SetStatusBarMessage(ex.Message, SAPbouiCOM.BoMessageTime.bmt_Medium, True)
                    bSuccess = False
                End Try
            Next i
            SetProjectCodeOnRows = bSuccess
        End Function
    Kind Regards,
    Owen

  • Update AR Invoice - Distribution Account - Class Revenue

    Hi,
    I want to update AR Invoice - Distribution Account - Class Revenue. The transaction is completed but not posted into GL. From front-end I can do it easily, but I have 1000 + transactions.
    Is there any API available to update AR Invoices Distribution Accounts?
    Thanks
    Waqas Hassan

    Hi,
    There is no update API available. I have uploaded AR Invoices and all that invoices are complete. But our Financial Consultant send me the request to change to Distribution Account.
    It can be, if I do the invoices to incomplete and then delete it.
    This could be the logic to re-create the invoices.
    Please guide me how could I do it incomplete?
    Thanks

Maybe you are looking for