on 02-03-2006 3:57 PM
hey All,
Can anyone tell me how I can remove a row from my UDO document lines table? I know how to update a row in the UDO document table but i am unsure as to how I can remove a row from my lines table using DI API.
Thanks
Hello Curtis,
As far as I know, you can't access to UDO using the DI API.
you may be able to do that using a recordset, but you're not allowed to do it, and it may have some bad effect
Sebastien
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Last thing I've heard was that the UDO data would be exposed to the DI in version 2006A.... Already waiting...
Regarding recordset, I've read many times from a UDO using that, but haven't had the nerve to write to it using recordset, but it depense on how desperate customor becomes in needing this over the year.
Actualy there is a way if you want do cascade remove all the child records of you master data UDO
Here is a little snipet of how i did it in C#
private void CascadeRemove(string __Code) { //Code is the MasterData record's code
UserTable _ChildTable = SBOCompany.UserTables.Item("ChildTable");
while (_ChildTable.GetByKey(__Code)) {
_ChildTable.Remove();
}
}
Hi Curtis,
If you've got the Parent ID of the child lines you want to remove its easy. You won't be using the udo object in the DI API. You will run a delete query using a Recordset Object on your table. Here is an example:
''''''''''''''
DELETE
FROM [@SOS_RBC]
WHERE DocEntry = 'xxx'
'''''''''''''''
(@SOS_RBC has the object type Document Lines)
DocEntry is the key to the master table.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
95 | |
11 | |
11 | |
6 | |
6 | |
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.