on 11-16-2010 12:31 PM
Hello All,
While uninstalling the addon i want to delete the respective UDO's and UDT.'s. How can i solve this problem?
Thank u,
Shraddha
Hi Shraddha......
Go to Tools > Customization Tools> Unregister.
You have to unregister All the UDTs from here and then go to User Defined Tables in Tools and delete one by one.
This will solve your Problem......
Regards,
Rahul
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Shraddha....
I'm not a technical person so I can not give you exact codes but I can suggest you the best possible way if you can do it.
Can you not incorporate Back end delete table function so that while uninstallation this function should get triggered and the UDO, UDTs would be deleted?
Regards,
Rahul
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Gordon,
Thanks for your time. I m able to generate the setup of addon successfully and it works great!. But my problem is when user uninstall the addon, the UDO's and UDT's will be not removed from database. I know this can be achieved by manual process but i want know is there any method by which we can make it automatic?
Regards,
Shraddha
Hello
There is no automatic method for this. What you can do: program the same steps when you created/Registered the UDO
Possible scenario would be:
1. Unregister UDO by oUserObjectsMD.Remove method (of course here you must first use the GetBekey method to receive the installed UDO)
2. Right now, you have the tables only in the database, all logic has been unregistered. Now you make backup of the data (if necessary) then remore the table oUserTables.Remove() method. (also getbykey is needed before removal),
You can try....
regards
János
@Janos,
Thanks for your time. I have done the coding for removal of UDO's and UDT's as
Dim MyUDO As SAPbobsCOM.UserObjectsMD = DirectCast(oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oUserObjectsMD), SAPbobsCOM.UserObjectsMD)
Dim RevVal As Integer
Dim errmsg As String
Try
MyUDO.GetByKey("IS_RESOURCES")
RevVal = MyUDO.Remove()
If RevVal <> 0 Then
oCompany.GetLastError(RevVal, errmsg)
MessageBox.Show("Failed to remove Resource UDO")
End If
Catch ex As Exception
End Try
Similarly for the UDT also. But my problem is when to call this removal method?because i can't call this method in my addon project so i tried to call this method in setup project(the one which will be generated while doing setup of addon). If i run that project in debug mode it work correctly but if i make an .exe and then run it gives an error 'Interop.SAPbouiCOM.dll not found'.
Please correct me where am i wrong!
Regards
Shraddha
Edited by: Shraddha P on Nov 18, 2010 2:13 PM
Edited by: Shraddha P on Nov 18, 2010 2:26 PM
User | Count |
---|---|
107 | |
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.