AccountUtuil not working?

davidcullen's Avatar

davidcullen

29 Jun, 2019 05:49 AM

Making this Public as no reply from earlier Private post.

Just upgraded to md 2019.3 (1880). Now seems AccountUtil is not working, or am I doing something incorrectly?
Code is as follows:

from com.infinitekind.moneydance.model import *
root = moneydance.getCurrentAccount()
book = moneydance.getCurrentAccountBook()
EM1=root.getAccountByName('Rental:Z:Debit interest - apportionable:EM1')
bal = AccountUtil.getBalanceAsOfDate(book, EM1, 20181231)
This results in "NameError: name 'AccountUtil' is not defined".
  1. 1 Posted by davidcullen on 16 Jul, 2019 04:09 AM

    davidcullen's Avatar

    Finally resolved.
    from com.infinitekind.moneydance.model import * does not work.
    Used instead:
    from com.infinitekind.moneydance.model import SplitTxn, ParentTxn, AccountUtil
    Avoids 'not defined' errors for SplitTxn, ParentTxn, & AccountUtil.
    Many thanks to:
    https://infinitekind.tenderapp.com/discussions/moneydance-developme...

  2. davidcullen closed this discussion on 16 Jul, 2019 04:10 AM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac