on 01-05-2007 4:25 PM
Hi All,
I'm try to update a line in Journal Voucher, but the method Browser.RecordSet was with this error: "The object does not support this method, or method not implemented yet."
This is the Code:
Dim oJournalVoucher As SAPbobsCOM.JournalVouchers
Dim oRecordSet As SAPbobsCOM.Recordset
Dim nDebit As Double
Set oJournalVoucher = oCompany.GetBusinessObject(oJournalVouchers)
Set oRecordSet = oCompany.GetBusinessObject(BoRecordset)
oRecordSet.DoQuery ("Select * From OBTF")
oJournalVoucher.JournalEntries.Browser.Recordset = oRecordSet
oJournalVoucher.JournalEntries.GetByKey ("1")
oJournalVoucher.JournalEntries.SetCurrentLine (0)
oJournalVoucher.JournalEntries.Lines.Debit = nDebit
Anybody help me?
Thank´
Hi,
you have to do that in this way,
oJournalVoucher = (SAPbobsCOM.Items)oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oJournalVouchers);
if (oJournalVoucher.GetByKey("1") == true)
{
oJournalVoucher.JournalEntries.SetCurrentLine (0)
oJournalVoucher.JournalEntries.Lines.Debit = nDebit
int iRetCode = oJournalVoucher.Update();
}
hope it will work.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
99 | |
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.