cancel
Showing results for 
Search instead for 
Did you mean: 

Access to matrix system item

Former Member
0 Kudos

Hi everybody,

I'm trying to access to an item (ItemCode field) in a system matrix (delivery notes lines). My code is:

oMat = oForm.Items.Item("38").Specific

strValor = oMat.Columns.Item(1).Cells.Item(pVal.Row).Specific.value

But I get an error, "Item - Invalid item", in the fisrt line (oMat = oForm.Items.Item("38").Specific)

What's wrong in my code????

Regards.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

i think the error is in the second line... you can't use "Specific.Value", so you must use an "EditText", try this:

oEdit = oMat.Columns.Item(1).Cells.Item(pVal.row).Specific

strValor = oEdit.Value

Hope it works

Regards,

Fabio Salucci

Former Member
0 Kudos

Hi Fabio,

thanks for your help...I think you're right about the second line....but I still have the same problem. If I disconnect second line and leave only "oMat = oForm.Items.Item("38").Specific", it doiesn't work anyway. So the error is for the first line.

¿Any idea?

Regards.

Former Member
0 Kudos

guys,

try:

Dim oMat As SAPbouiCOM.matrix

Dim strValor as EditText

Set oMat = frm.Items("38").Specific

Set strValor = oMat.Columns(1).Cells.Item(pVal.Row).Specific

'to access the value : strValor.String

tell me if this works with you.

Former Member
0 Kudos

guys,

try:

Dim oMat As SAPbouiCOM.matrix

Dim strValor as EditText

Set oMat = frm.Items("38").Specific

Set strValor = oMat.Columns(1).Cells.Item(pVal.Row).Specific

'to access the value : strValor.String

by the way this is for SBO 6.5....i'll be doing my first SDK for SBO 2004A tomorrow. tell me if this works.

tell me if this works with you.

Answers (0)