on 02-08-2008 7:19 AM
Dear friends,
My requirement is to select the value of transaction category combobox which is on Purchase order form automatically through my program.
But when i do this
oformPO.PaneLevel = oformPO.Items.Item("2068").ToPane
Dim ocombo1 As SAPbouiCOM.ComboBox
ocombo1 = oformPO.Items.Item("2068").Specific
ocombo1.Select("T2", SAPbouiCOM.BoSearchKey.psk_ByDescription)
It gives this error "Argument is out of Range [66000-91]"
although the Description is present in Valid values collection of combo I also tried by using SAPbouiCOM.BoSearchKey.psk_Index
but it gives the same error
Note: oformPO is set to newly opened Purchase Order form in Add mode
Regards,
Atul.
Hi,
you topic says "How to select Value"
but in your sample you are using psk_ByDescription
to select the value you use psk_ByValue
Roland was faster
Edited by: David Nussböck on Feb 8, 2008 9:54 AM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Roland
Yes I am using SBO 2005B PL 05
I have tried all the three option of selecting the combobox
psk_ByDescription
psk_ByValue
psk_Index
Dear friends, what you said is correct but the Combo.Select method gives error for this combobox item("2068") only and this is first time I got this error Argument out of range [66000-91]
I have tried same for other comboboxes like Item UID "20" Buyer and "121" Shipping type On Purchase Order form itself and it is working perfect.
Can somebody clarify what is going wrong for Transaction category combobox on Tax Folder item UID "2068"....
Regards,
Atul
Hmmm...
My last idea:
Is it possible by the B1-user to change this comboBox directly in the GUI?
What I mean is in exactly the same state of the form as it has when you try it by your AddOn (FormMode, entered values...etc...).
Maybe it's not allowed to change this Combo by the user in some situations? And maybe now the same restriction occurs and results in your error?
(too easy answer I fear...)
Cheers,
Roland
Hello!
I can't find Item("2068") - maybe because it's 2005A here?
Anyway:
In case of the Language combo on the A/R Invoice->Logistics it works like this here:
The Combo only shows the language-name.
When switching View->System Information on, I can see integer values at the beginning of the debugging line at the foot of B1 (MouseOver the closed combo).
For this combo the following 2 code examples are working:
Dim oCbx As SAPbouiCOM.ComboBox
oCbx = oForm.Items.Item("216").Specific
oCbx.Select("Swedish", SAPbouiCOM.BoSearchKey.psk_ByValue)
or:
Dim oCbx As SAPbouiCOM.ComboBox
oCbx = oForm.Items.Item("216").Specific
oCbx.Select("20", SAPbouiCOM.BoSearchKey.psk_ByDescription)
It's a little bit weird that "20" is the description and not the value...
Cheers,
Roland
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
110 | |
12 | |
11 | |
6 | |
5 | |
4 | |
4 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.