on 10-03-2017 5:09 PM
Hi, Colleagues,
I managed to create Journal Entry Vouchers in ABSL (from Custom BO action), but when I try to post the Journal Entry Voucher I get the error message: "Action POST not possible; action is disabled".
Sometimes the method Post works and Vouchers are posted, but I cannot find out what the fault/success cause is.
I created several Journal Entry Vouchers manually in the standard Work Center View, but their posting in ABSL gives the same message.
All Journal Entry Vouchers (created both in ABSL and in the standard Work Center View) can be posted by option Action -> Post of the standard Work Center View, though.
Are there any ideas?
Thank you.
Action-PostAccountingEntry.absl
import ABSL;
import AP.FinancialAccounting.Global;
import AP.Common.GDT as apCommonGDT;
import AP.FO.CompanyFinancialsProcessControl.Global;
import AP.FO.MOM.Global;
var query = AccountingEntry.QueryByElements;
var selectionParams = query.CreateSelectionParams();
selectionParams.Add(query.ID.content, "I", "EQ", this.AccountingEntryID.content.RemoveLeadingZeros() );
var result = query.Execute ( selectionParams );
var journalEntryVoucher = result.GetFirst();
if ( journalEntryVoucher.IsSet() ) {
journalEntryVoucher.Post();
}
return;
Dear Alexsei,
the action "post" in the UI is a combination of various actions. Can you please try this please: first "SubmitForPosting" and then "post".
Best regards
marlene
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Dear marlene.katzschner ,
What about cancelling a journal entry voucher from ABSL.
When i debug the code it calls JEV.Cancel(), but the status in the system stays Posted.
If i try to reverse it through the UI, it is successfully cancelled...
Is the action cancel also a combination of various actions?
Should i do something else before calling cancel?
Thanks,
Kostadin
Thank you, Marlene,
It works so, indeed.
journalEntryVoucher.SubmitForPosting();
journalEntryVoucher.Post();
Many thanks,
Aleksei
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 | |
3 | |
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.