cancel
Showing results for 
Search instead for 
Did you mean: 

Alternative Items

Former Member
0 Kudos

Hi,

Does anyone know if I can access the alternative items (table OALI) through the SDK?

Or is there any other way to import data to OALI ?

DTW does not include importing alternative items.

Regards,

Kari

Accepted Solutions (1)

Accepted Solutions (1)

barend_morkel2
Active Contributor
0 Kudos

Hi Kari,

As far as know there is no object to manipulate alternative items. (That's the reason why you can't do it through DTW - DTW uses the DI Objects to commit its transactions)

Former Member
0 Kudos

Hi Barend,

i have made a DRQ to SAP.

So I hope some day there is an object for alternative items.

Thanks

Former Member
0 Kudos

Hi kari,

what do you need to do with them?

Add the initial alternative Items?

If yes, although there isn´t any object for it, you could do some stuff to solve it.

Make a little AddOn that automatices the adding process, reading from a source file like excell or something like this. Just program "The way you will do it by hand", and automatice it using UI API.

Regards,

Ibai Peñ

Former Member
0 Kudos

Hi Ibai,

we need to add initial alternative items to OALI-table.

I tried to do it (VB6) with UI-API something like this:

Dim strItemCode, strAltItem As String

strItemCode = "A1001"

strAltItem = "B1001"

Set edittexti = frm.Items.Item("4").Specific

edittexti.String = strItemCode

Set edittexti = frm.Items.Item("6").Specific

edittexti.String = strAltItem

But i dont manage to add a record to OALI using UI-API.

Form which i use is: FormType = 40014

Kari

Former Member
0 Kudos

Hi Kari,

The idea is to create something like a "macro".

What did you do to manually do the task?

Moreles could be:

1 - Click on Item master data menu.

2 - Set the ItemCode and click on the search button.

3 - Click in the Alternative Items menu.

4 - Assign the alternative Item code.

5 - Click on Update button.

6 - Click on OK button.

...

So, you must create the UI API code that will do that for you, automatically. Something like:


ActiveProcess = True
Application.ActivateMenuItem("ItemMasterDataMenuID") '1 -Click in the...
For each oItem in your list
   ItemMasterDataForm.ItemCode.String = oItem.String '2 - Set the...
   OKButton.Click '2 - click Search button
   Application.ActivateMenuItem("AlternativeItemMenuID") '3 -Click in the...
   
End For
ActiveProcess = False

Alternative Items Form Load Event
If ActiveProcess = True
   Get Actual Item
   For each Alternative Item
      AlternativeItemForm.ItemCode = Alternative Item.String '4 - Assign the ...
   End For
   ButtonOK.click '5 - Click on ...
   ButtonOK.click '6 - Click on ...
End If
End Load Event

I hope you get the main idea.

Ibai Peña

PD: Does it worth? How much alternative items are they?

Former Member
0 Kudos

Hi,

This looks like what i need.

I'll try to do this.

Thank you Ibai for your help !

Answers (0)