<?xml version="1.0" encoding="UTF-8"?>
<chapter id="details.accounts">
<chapterinfo>
  <authorgroup>
    <author> &Michael.T.Edwardes; &Michael.T.Edwardes.mail; </author>
    <author> &Roger.Lum; &Roger.Lum.mail; </author>
    <author> &Jack.H.Ostroff; &Jack.H.Ostroff.mail; </author>
  </authorgroup>
  <date>2018-02-01</date>
  <releaseinfo>5.0.0</releaseinfo>
</chapterinfo>

<title>Accounts</title>

<sect1 id="details.accounts.view">
<title>The Accounts View</title>

<para>
  The Accounts view provides a summary of all the accounts. It is similar to the
  Institutions view, except accounts are grouped under the Asset and Liability
  asset categories.  Typical asset accounts include bank accounts, cash, and
  investments, while typical liability accounts include credit cards and loans.
</para>

<para>
  There are actually two other account categories: Income and
  Expense. Categories are a way to organize your transaction; they are grouped
  under either the Income or Expense account category and are treated
  internally by &kmymoney; as accounts. They are described in more detail in
  the chapter on <link linkend="details.categories">Categories</link>. The
  Income and Expense account categories are always displayed in the Categories
  view, but it is possible to <link linkend="details.settings">configure
  &kmymoney;</link> to also display them on the Accounts view.
</para>

<para>
<screenshot>
    	<screeninfo>account view</screeninfo>
	<mediaobject>
	<imageobject>
	<imagedata fileref="account_view.png" format="PNG" />
	</imageobject>
	<textobject>
	<phrase>account view</phrase>
	</textobject>
	</mediaobject>
</screenshot>
</para>

<para>
  Similar to the Institutions view, the Accounts view displays several columns
  with descriptive and summary information about each account.  The rest of this
  chapter will focus on Asset and Liability account functionality.  Income and
  Expense accounts, &ie;, Categories, are described in the chapter on <link
  linkend="details.categories">Categories</link>.
</para>

</sect1>

<sect1 id="details.accounts.create">
<title>Creating an Account</title>

<note><para>
    You must have a file open before you can create a new account. If you
    do not have an existing file, you will need to <link
    linkend="firsttime.3">create one</link>.
</para></note>

<para>
  To create a new account, you can either select the <menuchoice>
  <guimenu>Account</guimenu><guimenuitem>New account...</guimenuitem></menuchoice>
  menu item or choose the <guiicon><inlinemediaobject><imageobject><imagedata
  fileref="newacct.png" format="PNG"/></imageobject></inlinemediaobject>
  </guiicon> new account icon from the toolbar. You can also create an account
  from the Accounts view; click on the Accounts icon in the view selector and
  then right click on the Asset or Liability tree icon and select <guimenuitem>New
  account...</guimenuitem> from the popup menu.
</para>

<sect2 id="details.accounts.create.institution">
<title>The Institution (Bank) name</title>

<para>
  <screenshot>
    <mediaobject>
      <imageobject>
        <imagedata fileref="accwiz1.png" format="PNG" />
      </imageobject>
      <textobject>
        <phrase>Account Wizard</phrase>
      </textobject>
    </mediaobject>
  </screenshot>
</para>

<para>
  The first step involves selecting an institution for the account.  If this is
  an account for an institution you have already created, you can select the
  institution from the dropdown list.  If you want to create a new institution,
  click on the <guibutton>New Institution</guibutton> button.  This will bring
  up the New Institution Dialog, as described in the previous section.  If this
  is not a bank account, or if you do not want to use online banking, you do not
  need to specify an institution.
</para>

<para>
  The Account Number and the <ulink
  url="https://en.wikipedia.org/wiki/International_Bank_Account_Number"><acronym>IBAN</acronym>
  (International Bank Account Number)</ulink> are not currently used
  by &kmymoney;.  These fields may be left blank and filled in at a later time;
  they are only required for online banking.
</para>

<para>
  To proceed to the next step click on <guibutton>Next</guibutton>.
</para>
</sect2>

<sect2 id="details.accounts.create.account">
<title>Account</title>

<para>
  <screenshot>
          <mediaobject>
            <imageobject>
              <imagedata fileref="accwiz2.png" format="PNG" />
            </imageobject>
            <textobject>
              <phrase>Account Wizard</phrase>
            </textobject>
          </mediaobject>
  </screenshot>
</para>

<para>
  First, enter a name for the account. This name will be used to identify it.
</para>

<para>
  Next, select the type of account from one of the types available from the
  dropdown list.  Different account types are handled differently within
  &kmymoney;, so it is important to choose the correct type when creating the
  account.  Also, different types of accounts require different setup
  information, and may display different pages in the new account setup wizard
  to collect that information.
</para>

<variablelist>
  <varlistentry>
    <term>Checking</term>
    <listitem>
      <para>
        A normal checking account, the type you get with any bank or credit union.
      </para>
    </listitem>
  </varlistentry>

  <varlistentry>
    <term>Savings</term>
    <listitem>
      <para>
        A normal savings account, the type you get with any bank or credit union.
      </para>
    </listitem>
  </varlistentry>

  <varlistentry>
    <term>Credit Card</term>
    <listitem>
      <para>
        An account to represent your credit card.
      </para>
    </listitem>
  </varlistentry>

  <varlistentry>
    <term>Cash</term>
    <listitem>
      <para>
        A general purpose account, typically used for accounts not held at a
        bank, such as the cash in your wallet.
      </para>
    </listitem>
  </varlistentry>

  <varlistentry>
    <term>Loan</term>
    <listitem>
      <para>
        An account to manage a loan for money either borrowed or lent.  With a
        Loan account &kmymoney; automatically calculates interest payments to
        help you track the remaining principal on the loan.  Loans with no
        interest might use the plain Asset or Liability type below, depending on
        whether the money is lent or borrowed.
      </para>
    </listitem>
  </varlistentry>

  <varlistentry>
    <term>Investment</term>
    <listitem>
      <para>
        An account to manage an investment such as stocks, bonds, or mutual
        funds.
      </para>
    </listitem>
  </varlistentry>

  <varlistentry>
    <term>Asset</term>
    <listitem>
      <para>
        An account to manage an asset that does not fit in one of the above
        types.
      </para>
    </listitem>
  </varlistentry>

  <varlistentry>
    <term>Liability</term>
    <listitem>
      <para>
        An account to manage a money you owe or a future expense that does not
        fit in one of the above types.  This is most commonly used for loans
        with no interest.  If interest needs to be calculated, you might be
        better using the Loan type above.
      </para>
    </listitem>
  </varlistentry>
</variablelist>

<para>
  Select the currency to be used for the account from the dropdown list.
</para>

<para>
  Enter the date the account was opened or select it from the calendar using the
  icon to the right.  You will not be able to enter any transaction with a date
  earlier than the account opening date, but you can change this date later, if
  necessary.
</para>

<para>
  Enter the opening balance for the account. If this is an existing bank
  account, this information can be found on your statement. If it is a new
  account, the opening balance can be left at zero.
</para>

<para>
  Selecting the <emphasis>Preferred Account</emphasis> check box will allow
  preferred access in some dialogs and views of &kmymoney;.
</para>

<para>
  To proceed to the next step click on <guibutton>Next</guibutton>.
</para>
</sect2>

<sect2>
<title>Credit Card Accounts</title>

<para>
  When creating a Credit Card account, after entering the basic information and
  clicking <guibutton>Next</guibutton>, you can optionally have &kmymoney;
  create a <link linkend="details.schedules">scheduled transaction</link> for
  you.
</para>

<para>
  <screenshot>
            <mediaobject>
              <imageobject>
                <imagedata fileref="accwiz6.png" format="PNG" />
              </imageobject>
              <textobject>
                <phrase>Account Wizard</phrase>
              </textobject>
            </mediaobject>
  </screenshot>
</para>

<para>
  If you want such a transaction generated, make sure the check box is selected
  and enter the required information.
</para>

<para>
  Click on <guibutton>Next</guibutton> to continue.
</para>
</sect2>

<sect2>
<title>Investment Accounts</title>

<para>
  In &kmymoney;, Investment accounts contain only equities (stocks, bonds,
  &etc;) but do not contain cash.  (This is why you cannot specify a Opening
  balance for an Investment account.)  If a transaction in an Investment account
  requires or generates cash (such as to buy or sell stock,) a Brokerage account
  is used for the cash.  Brokerage accounts are described further in the chapter
  on <link linkend="details.investments">Investments</link>.  When you create a
  new Investment account, after entering the basic information, and clicking
  <guibutton>Next</guibutton>, you have the option to create an associated
  Brokerage account.
</para>

<para>
  <screenshot>
            <mediaobject>
              <imageobject>
                <imagedata fileref="accwiz7.png" format="PNG" />
              </imageobject>
              <textobject>
                <phrase>Account Wizard</phrase>
              </textobject>
            </mediaobject>
  </screenshot>
</para>

<para>
  It is generally best to create the Brokerage account here, which will be given
  the same name as the Investment account, with "(Brokerage)" appended.
  Currently it is not possible to specify the opening date or balance for the
  Brokerage account at this point; you may do by editing the account details
  after the account has been created.
</para>
</sect2>

<sect2>
<title>Loan Accounts</title>

<para>
  Loan accounts are special accounts used to help you manage Loans with interest
  and scheduled repayments.  By providing &kmymoney; with information about the
  loan, &kmymoney; can help you track interest payments and the remaining
  principal of the loan.
</para>

<para>
  <screenshot>
            <mediaobject>
              <imageobject>
                <imagedata fileref="accwiz8_1.png" format="PNG" />
              </imageobject>
              <textobject>
                <phrase>Account Wizard</phrase>
              </textobject>
            </mediaobject>
  </screenshot>
</para>

<para>
  On the Details page you enter the general information about the loan.
</para>

<para>
  First, select whether you are borrowing or lending money.  If you are
  borrowing money the loan will be listed in Accounts under Liabilities.  If you
  are lending money the loan will be listed under Assets.
</para>

<para>
  Next, select the payee or payer of the loan.  As always, if the name doesn't
  yet exist in the Payees list, enter it here and &kmymoney; will create it for
  you.
</para>

<para>
  The next three items are for handling Loans on which you've already made
  payments.  If you select <guibutton>Yes</guibutton> in the <guilabel>Did you make/receive any
  payments yet?</guilabel> dropdown, you can then select whether you want to
  record all payments or just those from the beginning of the current year.  If
  you want to record from the beginning of the current year, you are than asked
  to input the balance at the beginning of this year.
</para>

<para>
  Next, select how often payments will be made and how often interest is
  compounded.  Compounding is where the interest is added to the amount owed on
  the loan so that when the interest is next calculated there will be more
  interest paid on the interest.  It's common for interest to be compounded at
  the same frequency that payments are made.
</para>

<para>
  Next, enter the date the first payment to be recorded.
</para>

<para>
  Finally, enter information about how the interest rate varies.  If the loan is
  fixed-rate there is nothing to do.  If the rate varies, select Variable in
  <guilabel>Type of interest rate</guilabel> and then enter the interval
  between interest rate changes and the date the first change of interest rate
  is due: &kmymoney; will ask you to update the interest rate when that date
  arrives.  Click <guibutton>Next</guibutton> to continue.
</para>

<para>
  <screenshot>
            <mediaobject>
              <imageobject>
                <imagedata fileref="accwiz8_2.png" format="PNG" />
              </imageobject>
              <textobject>
                <phrase>Account Wizard</phrase>
              </textobject>
            </mediaobject>
  </screenshot>
</para>

<para>
  The Payments page is where you enter the payment and interest values for the
  loan.
</para>

<para>
  First, select whether the interest rate is calculated when the payment is
  received or when it becomes due.  If you don't know, leave it on the default
  value.
</para>

<para>
  Next, enter the following values:
</para>

<variablelist>
  <varlistentry>
    <term>Loan amount</term>
    <listitem>
      <para>The amount of the loan.</para>
    </listitem>
  </varlistentry>

  <varlistentry>
    <term>Interest rate</term>
    <listitem>
      <para>The annual percentage interest rate of the loan.</para>
    </listitem>
  </varlistentry>

  <varlistentry>
    <term>Term</term>
    <listitem>
      <para>
        The length of the loan.  Enter a number and select either Months or
        Years.
      </para>
    </listitem>
  </varlistentry>

  <varlistentry>
    <term>Payment (principal and interest)</term>
    <listitem>
      <para>
        The amount of each loan payment.  This is the total of the principal and
        interest paid with each payment.
      </para>
    </listitem>
  </varlistentry>

  <varlistentry>
    <term>Balloon payment</term>
    <listitem>
      <para>
        Additional final payment made at the end of the term to pay off the
        remaining principal of the loan.  For a repayment loan this is often
        zero.  For an interest-only loan this will be the same as the loan
        amount.
      </para>
    </listitem>
  </varlistentry>
</variablelist>

<para>
  Finally, use the <guibutton>Calculate</guibutton> button to check the values
  you have entered.  You must have entered either all or all but one of the
  values listed above.  If you omit two or more values the button is disabled
  because it is not possible to check that the entered values are consistent: in
  that case you will not be able to use the Loan account facility in &kmymoney;
  and will instead have to use a Liability or Asset account to track the loan
  manually.
</para>

<para>
  If you omit one value, &kmymoney; will try to calculate it for you.  If you
  have entered all values &kmymoney; will check the values are consistent.
  &kmymoney; will not adjust entered values other than the "Balloon payment",
  which it may adjust slightly to deal with rounding.  If the values are
  inconsistent or &kmymoney; cannot calculate the omitted value, &kmymoney; will
  let you know so that you can correct any errors and repeat the calculation.
</para>

<para>
  Once the values are consistent, the <guibutton>Next</guibutton> button is
  enabled and you can advance to the next page.
</para>

<para>
  <screenshot>
            <mediaobject>
              <imageobject>
                <imagedata fileref="accwiz8_3.png" format="PNG" />
              </imageobject>
              <textobject>
                <phrase>Account Wizard</phrase>
              </textobject>
            </mediaobject>
  </screenshot>
</para>

<para>
  The Fees page is where you can enter any fees added to the loan payments.
</para>

<para>
  If there are any fees press the <guibutton>Additional Fees</guibutton> button.
  The Transaction Split editor will be displayed for entry of the fees.  Any
  lines added here will be included in the payment schedule for the loan.  When
  you save the splits the Fees page will display the principal and interest
  payment, the total additional fees, and the total periodic payment.
</para>

<para>
  <screenshot>
            <mediaobject>
              <imageobject>
                <imagedata fileref="accwiz8_4.png" format="PNG" />
              </imageobject>
              <textobject>
                <phrase>Account Wizard</phrase>
              </textobject>
            </mediaobject>
  </screenshot>
</para>

<para>
  &kmymoney; will create a <link linkend="details.schedules">scheduled
  transaction</link> for your loan.  The Schedule page is where you enter the
  remaining details needed to create the schedule.
</para>

<para>
  First enter the Category to which loan interest will be assigned.  Then enter
  the account from which the loan payment will be made.
</para>

<para>
  The page also displays the first payment date for which the Schedule will be
  created.
</para>

<para>
  <screenshot>
            <mediaobject>
              <imageobject>
                <imagedata fileref="accwiz8_5.png" format="PNG" />
              </imageobject>
              <textobject>
                <phrase>Account Wizard</phrase>
              </textobject>
            </mediaobject>
  </screenshot>
</para>

<para>
  Optionally, &kmymoney; can create a transaction representing what was received
  or paid when the loan was created.
</para>

<para>
  If you borrowed or lent cash select the account from which or to which the
  loan amount was paid.
</para>

<para>
  If you borrowed money to purchase a car you can select or create an Asset
  account to help you track the value of the new car.
</para>

<para>
  If you re-financed an existing Loan, check the <guilabel>Refinance existing
  loan</guilabel> check box, select the Loan account and &kmymoney; will create
  a transfer transaction paying off the existing loan.
</para>

<para>
  If you don't want to create the payout transaction, check the <guilabel>Do
  not create payout transaction</guilabel> check box.
</para>
</sect2>

<sect2 id="details.accounts.create.parent">
<title>Parent Account</title>

<para>
  <screenshot>
	<screeninfo>Parent Account</screeninfo>
	<mediaobject>
	  <imageobject>
            <imagedata fileref="accwiz10.png" format="PNG" />
	  </imageobject>
	  <textobject>
	    <phrase>Account Wizard</phrase>
	  </textobject>
	</mediaobject>
  </screenshot>
</para>

<para>
  This is the penultimate step in creating any new account except a loan.
  Depending on the type of account that is being created, a tree of your Asset
  or Liability accounts will be displayed.
</para>

<para>
  The Parent Account page is not currently shown for Loans because they cannot
  be created as subaccounts.  Also, Investment accounts cannot contain other
  accounts so they are not shown in the tree.
</para>

<para>
  Select the account you wish contain the new account.  If you do not select a
  parent account, the new account will be created at the top level.
</para>

</sect2>

<sect2>
<title>Review and save the account details</title>

<para>
  <screenshot>
          <screeninfo>Review</screeninfo>
          <mediaobject>
            <imageobject>
              <imagedata fileref="accwiz9.png" format="PNG" />
            </imageobject>
            <textobject>
              <phrase>Account Wizard</phrase>
            </textobject>
          </mediaobject>
  </screenshot>
</para>

<para>
  This is the final step in creating a new account. A summary of the information
  entered is displayed. Review it, and if everything is OK press
  <guibutton>Finish</guibutton>. Otherwise, either press
  <guibutton>Back</guibutton> to make corrections or
  <guibutton>Cancel</guibutton> to abandon creating the new account.
</para>

<note><para>
  The Type and Currency cannot at present be changed after the account is created.
</para></note>
</sect2>
</sect1>

<sect1 id="details.accounts.viewing">
<title>Opening / viewing accounts</title>

<para>
  To open an account in the Ledger view you can either click on the link to the
  account from the Home view, or click on the <guiicon><inlinemediaobject>
  <imageobject><imagedata fileref="ledgers_view.png" format="PNG"/></imageobject>
  </inlinemediaobject></guiicon> ledgers icon in the view selector and select the
  account in the drop down box at the top of the view. Alternatively, in the
  <guiicon>Account</guiicon> view, either double-click the account entry or
  right click and select <guimenuitem>Open ledger</guimenuitem>.
</para>
</sect1>

<sect1 id="details.accounts.edit">
<title>Editing Account Information</title>

<para>
  To edit a particular account, right-click that account and choose
  <guimenuitem>Edit account...</guimenuitem> or with that account open in the
  ledger, select <menuchoice><guimenu>Account</guimenu><guimenuitem>Edit
  Account...</guimenuitem></menuchoice>. A window will pop-up with several
  tabs, each allowing you to view and change certain information about the
  account.  For more information on any of these details, see the section on
  <link linkend="details.accounts.create">creating a new account</link>.
</para>

<para>
  <screenshot>
        <screeninfo>Edit an account</screeninfo>

        <mediaobject>
          <imageobject>
            <imagedata fileref="account_edit.png" format="PNG" />
          </imageobject>

          <textobject>
            <phrase>Edit account information</phrase>
          </textobject>
        </mediaobject>
  </screenshot>
</para>

<formalpara><title>General</title>
<para>
  View the general information about the account, and change the name,
  start or opening date, as well as some of the other basic settings
  of the account.
</para>
</formalpara>

<formalpara><title>Institution</title>
<para>
  View and change the associated banking institution and account
  numbers.  You can also create a new institution here.
</para>
</formalpara>

<formalpara><title>Hierarchy</title>
<para>
<!-- not ported to kde4 yet, uncomment if that is done,
     see https://bugs.kde.org/show_bug.cgi?id=272737
  You can change the parent account by dragging the account in this
  view of the account hierarchy.  Changing the parent account is also
  possible in the main Accounts screen, by dragging the account and
  dropping it on a different parent account.
-->
  You can change the parent account by clicking on another parent account in
  this view of the account hierarchy.
</para>
</formalpara>

<formalpara><title>Limits</title>
<para>
  This tab is only present for asset and liability accounts.  If you
  enter amounts in the available fields, &kmymoney; will warn you when
  the account balance reaches those values.
</para>
</formalpara>

<formalpara><title>Tax</title>
<para>
  Here you can check whether this is a VAT account, and whether to
  include this account on tax reports.
</para>
</formalpara>

<formalpara><title>Online Settings</title>
<para>
  This tab is only be present if the account has been mapped to an <link
  linkend="details.impexp.ofxdirectconnect">online account</link>.  It has
  three subtabs.
</para>
</formalpara>

<itemizedlist>
<listitem>
<para>
  <emphasis>Account Details</emphasis>: This shows the status of the
  online connection, the bank/broker and account number, and allows
  you to store or change the password for the online account.
</para>
</listitem>

<listitem>
<para>
  <emphasis>OFX Details</emphasis>: Here you can adjust certain details
  &kmymoney; uses when it establishes an OFX connection with the
  institution.  This should only be necessary if you get certain
  errors when you first set up the online account, or perhaps if your
  institution changes its OFX server software.
</para>
</listitem>

<listitem>
<para>
  <emphasis>Import Details</emphasis>: Here you can tell &kmymoney;
 what to use as the start date for the import.  In addition, starting
 with version 4.6, you can choose whether the payee's name is based
 on the PAYEEID, NAME, or MEMO field of the imported transaction.
</para>
</listitem>
</itemizedlist>
</sect1>

<sect1 id="details.accounts.delete">
<title>Deleting accounts</title>

<para>
  To delete an account, first remove all the transactions from that account in
  the ledger. Next, find the account in the accounts view and after right
  clicking on the entry to show the popup menu select <guimenuitem>Delete
  account...</guimenuitem> from the popup menu.
</para>

<para>
  If you are unable to delete an account which looks like it has no transactions
  in it, check your filter. See <menuchoice> <guimenu>Settings</guimenu>
  <guimenuitem>Configure &kmymoney;</guimenuitem>
  <guimenuitem>General</guimenuitem> <guimenuitem>Filter</guimenuitem>
  </menuchoice>. Clear all filters. Set the start date to 1.1.1900 or so.
</para>

<para>
  There may be transactions in your ledger that are not shown, for example, if
  you have inadvertently typed in the wrong year when making an entry so that an
  entry remains outside the opening date of &kmymoney;. This appears beneath the
  ledger page as remaining funds.
</para>
</sect1>
</chapter>
