cancel
Showing results for 
Search instead for 
Did you mean: 

Sales Quotation Error : Item - Form item is not editable

Former Member
0 Kudos

Hi all,

i want to create a Sales Quotation tru Sales Quotation form. what i did is i open the form and put the values inside the fields in the form. this is my code:


Dim oMenu As SAPbouiCOM.MenuItem = SBO_Application.Menus.Item("2049")
                        Dim oFormQ As SAPbouiCOM.Form
                        Dim oFormsId As String
                        Dim oEdit As SAPbouiCOM.EditText
                        Dim oItem As SAPbouiCOM.Item
                        Dim oCell As SAPbouiCOM.Cells

                        oMenu.Activate() ' Click menu Sales Quotation

                        oFormsId = SBO_Application.Forms.ActiveForm.UniqueID

                        oFormQ = SBO_Application.Forms.Item(oFormsId)
                        oFormQ.Left = 300 ' hide the form

                        ' BP Code Edittext
                        oEdit = oFormQ.Items.Item("4").Specific
                        oEdit.Value = "CNAR-0038"

                        ' Remark Edittext
                        oEdit = oFormQ.Items.Item("16").Specific
                        oEdit.Value = "Remark"

                        ' Matrix Item/Service
                        oMatrix = oFormQ.Items.Item("39").Specific

                        ' Description Column
                        oEdit = oMatrix.Columns.Item(1).Cells.Item(1).Specific
                        oEdit.Value = "SERVICE NAME"

                        ' Amount Column
                        oEdit = oMatrix.Columns.Item(12).Cells.Item(1).Specific
                        oEdit.Value = "1000"

the problem is i got error "Item - Form item is not editable" when putting value in Amount column. the column in the form is visible and active.

how can i solve this? please help.

thanks in advance,

azif.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Azif,

the column you are looking for is column 15. the column number you see in title bar is mis-leading.

you can loop through like this:


oform =SBO_Application.Forms.GetForm("149", 1)
                oMatrix = oform.Items.Item("39").Specific
                Dim I As Integer
                For I = 1 To oMatrix.Columns.Count
                    MsgBox(I & " " & oMatrix.Columns.Item(I).Title)
                Next

Binita

Former Member
0 Kudos

Thanks you guys, those were really helpful. Thanks again. Azif.

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

I fought with this few weeks ago in stock transfer form. What I found out is:

oMatrix.Columns.Item(12).Cells.Item(1).Specific dosnt mean, that you select 12th column, it may be 10th, or 20th. Check in itemevent when you click on cell in specific column, which column id you receive (or use names of columns).

The next thing I found is, that in specific cases doesnt worked

oEdit = oFormQ.Items.Item("4").Specific

oEdit.Value = "CNAR-0038"

But work

oFormQ.Items.Item("4").Click(SAPbouiCOM.BoCellClickType.ct_regular)

SBO_Application.SendKeys("CNAR-0038")

maybe it help you