on 2008 Jun 18 12:56 PM
Hi To All,
In my screen there is textbox with link button. when i click the link button another screen should open... Here is my source
Case "lnkWNo"
Select Case pVal.EventType
Case SAPbouiCOM.BoEventTypes.et_ITEM_PRESSED
objXML.LoadForm("aaa.xml")
objForm = App.Forms.Item("AAA")
objForm.Mode = SAPbouiCOM.BoFormMode.fm_FIND_MODE
objForm.Items.Item("txtOrderNo").Enabled = True
objForm.Items.Item("txtOrderNo").Specific.value = Datasource.GetValue("U_worderno", Datasource.Offset).Trim
objForm.Items.Item("1").Click()
End Select
When i crossed this line
objForm.Mode = SAPbouiCOM.BoFormMode.fm_FIND_MODE
error message as
object reference not set to an instance of object
same as when i crossed this line
objForm.Items.Item("txtOrderNo").Specific.value = Datasource.GetValue("U_worderno", Datasource.Offset).Trim
error message comes as
object reference not set to an instance of object
Wats the problem.........
You need to initilise the form and linked button object also.
as
Dim oLink As SAPbouiCOM.LinkedButton
Set oColumn = oColumns.Add("A", it_LINKED_BUTTON)
Set oLink = oColumn.ExtendedObject
oLink.LinkedObject = lf_BusinessPartner
hope this will help you..
lg Mahendra
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
For Master you can use the following code
Dim OCT_LinkButton As SAPbouiCOM.LinkedButton
OCT_Item = OCT_Form.Items.Add("lnkGINo", SAPbouiCOM.BoFormItemTypes.it_LINKED_BUTTON)
OCT_Item.Left = OCT_Form.Items.Item("lblGINo").Left + OCT_Form.Items.Item("lblGINo").Width + 5
OCT_Item.Width = 10
OCT_Item.Top = OCT_Form.Items.Item("lblGINo").Top
OCT_Item.Height = OCT_Form.Items.Item("lblGINo").Height
OCT_Item.LinkTo = "editGINo"
OCT_LinkButton = OCT_Form.Items.Item("lnkGINo").Specific
OCT_LinkButton.LinkedObject = SAPbouiCOM.BoLinkedObject.lf_GoodsIssue
lg Mahendra
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
It doesnot matters where it is.just set the following property
Dim oLink As SAPbouiCOM.LinkedButton
Set oColumn = oColumns.Add("A", it_LINKED_BUTTON)
Set oLink = oColumn.ExtendedObject
oLink.LinkedObject = lf_BusinessPartner
I hope It will resolved ur issue.
lg Mahendra
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sridhar,
The problem are that your variable objForm is null because the Form.Item(XX) require the UID of the form.
I think it was the problem.
Hope i help you
Michael
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
104 | |
8 | |
6 | |
6 | |
6 | |
5 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.