Replacing Microsoft Money, Part 5: OFX Scripts
This is part 5 in my series for replacing Microsoft Money. I gave my requirements in part 1. Then I looked at Quicken, GnuCash, and Moneydance.
I still haven’t found a perfect replacement for Microsoft Money. Money isn’t perfect either, but it’s working. Well, sort of. I already know the bugs and limitations and I know how to work around them.
Having suffered from being at the mercy of one software vendor, I really don’t look forward to jumping into the arms of another vendor with the same policy of automatically disabling features. Meanwhile, the contenders GnuCash and Moneydance still don’t match all the functionalities I’d like to have.
If only the downloading features won’t work in Money, why junk the whole thing? Why not just fix the downloads?
Having seen how GnuCash and Moneydance can download transactions directly from the financial institutions, I wondered if there is a way to use an alternative application for downloading. I can then import the downloaded files into Microsoft Money. If it’s only a one-time setup and a few more mouse clicks, I can live with that.
With the help of Google and GnuCash Wiki, I found two great Python scripts (ofx.py and ofx-ba.py). With some trial and error, I figured out how to use them on Windows.
[The rest of this post contains detailed technical instructions. I provide enough details to make it work even if you are not that technical. Skip if you are not interested.]
1. Download and install Python. I used ActivePython 2.6.2 for Windows. I think the 2.6.2 version from python.org will work too.
2. Download the Python scripts: ofx.py and ofx-ba.py. Just save them in a folder. Open ofx.py and ofx-ba.py in a text editor. You will see something like this:
sites = {
“ucard”: {
“caps”: [ "SIGNON", "CCSTMT" ],
“fid”: “24909″,
“fiorg”: “Citigroup”,
“url”: “https://secureofx2.bankhost.com/citi/cgi-forte/ofx_rt?servicename=ofx_rt&pagename=ofx”,
},
“discover”: {
“caps”: [ "SIGNON", "CCSTMT" ],
“fiorg”: “Discover Financial Services”,
“fid”: “7101″,
“url”: “https://ofx.discovercard.com/”,
},
“ameritrade”: {
“caps”: [ "SIGNON", "INVSTMT" ],
“fiorg”: “ameritrade.com”,
“url”: “https://ofx.ameritrade.com/ofxproxy/ofx_proxy.dll”,
}
}
These are the address and IDs used in downloading from the sample financial institutions. You will need the address and IDs for the financial institutions you use.
While you have the scripts open, make two small changes necessary for Windows. The scripts will not work on Windows without these changes. By the way, if you are still using Notepad, download and install the free, open source program Notepad++. Notepad will work. Notepad++ is much better.
Replace this line (line 2 in both ofx.py and ofx-ba.py):
import time, os, httplib, urllib2
with
import time, os, httplib, urllib2, uuid
Replace this line (line 37 in ofx.py; line 27 in ofx-ba.py):
return os.popen(”uuidgen”).read().rstrip().upper()
with
return uuid.uuid4().hex
Save the scripts.
3. Look for OFX settings. The settings for some financial institutions are listed in OFX Direct Connect Bank Settings on GnuCash Wiki. There is another searchable list at a web site OFX Home. If the companies you use are not listed there, you will have to find them yourself in the next step.
4. Download online banking directory. This is a zip file. Unzip the directory files into a folder.
If your zip utility can’t handle the .tgz file format, download and install the excellent open source program 7-Zip. You may have to extract twice: first from the .tgz file to a .tar file, then from the .tar file to the individual files. In the end, you will have 3 index files and more than 5,000 details files in a fi subfolder.
Suppose you are looking for the settings for a credit card. You open creditcard.xml in a text editor (open bank.xml for banks and brokerage.xml for brokerage).
In creditcard.xml, search for the name of the credit card company you are looking for. For example, for Chase, I find
<prov>
<name>Chase</name>
<phonetic/>
<guid>7685</guid>
<label>User ID</label>
<type>1</type>
<webcr>1</webcr>
<weben>1</weben>
</prov>
The number between <guid> and </guid>, 7685, is the key. It tells you which details file has more information for Chase. You open the details file 7685.xml in the fi subfolder. You look for 3 values in the details file:
<Org>B1</Org>
<FID>10898</FID>
… …
<ProviderURL>https://onlineofx.chase.com/chase.ofx</ProviderURL>
These are the values you need in ofx.py. By the way B1 means Bank One. Chase bought Bank One in 2004.
Find and gather all the values for each of your financial institutions.
5. Update Python scripts. Open the Python scripts ofx.py and ofx-ba.py again in a text editor. Replace the sample settings in the scripts with the settings for the companies you use. Give each entry a short name. Put Org in fiorg, FID in fid, and ProviderURL in url. Add or remove more entries in the “sites” area if necessary.
For credit cards, make them look like ucard and discover in the original ofx.py with a CCSTMT. For brokerage accounts, make them look like ameritrade in the original ofx.py with a INVSTMT. Add bank settings to ofx-ba.py. You will also need the routing number for your bank.
Just in case the financial institutions don’t like our scripts, replace
config["appid"] = “PyOFX”
config["appver"] = “0100″
with
config["appid"] = “QWIN”
config["appver"] = “1800″
This makes our scripts look like Quicken 2009 for Windows.
6. Run Python scripts. Open a command prompt (Start -> Run … -> cmd). For credit cards and brokerage accounts, type
python ofx.py [name of the site] [your online login] [your account number]
For bank accounts, use ofx-ba.py instead of ofx.py:
python ofx-ba.py [name of the site] [your online login] [your account number] [CHECKING or SAVINGS]
When you are prompted for the password, type your online password and press Enter.
The script will download a [site][yyyymmdd].ofx file. Open Microsoft Money. Double click on the downloaded .ofx file. The Microsoft Money Import Handler mnyimprt.exe will take it from there.
Upon closer inspection, I see the ofx-ba.py script can actually handle all types of accounts: credit cards, brokerage accounts, and bank accounts. I made additional changes to my script to make it work with Vanguard (hat tip to Costin Manolache). You can look at my modified script. It works with American Express, Chase, Fidelity, Vanguard, and presumably USAA (I don’t have a bank account to test).
So far, this is still not much different from going to each financial institution’s web site and downloading the transactions manually. With more modifications, I made the script:
- take the password as a parameter instead of prompting the user for the password
- trigger the Microsoft Money Import Handler automatically after each download
You can download my automated script. To use the automated script, insert your online password between your login and your account number. For credit card or brokerage account:
python ofx-ba-tfb-auto.py [name of the site] [your online login] [your online password] [your account number]
For bank account:
python ofx-ba-tfb-auto.py [name of the site] [your online login] [your online password] [your account number] [CHECKING or SAVINGS]
To download one account after another, a batch file calls the automated script for each account (remove the .txt extension from these scripts). Because you have to put your logins, passwords, and account numbers into the batch file, I suggest you put the scripts and the batch file on a portable USB drive. Plug the USB drive into your computer only when you import. Unplug when you are done.
I placed a shortcut to the batch file on my desktop. Now I have my own one-step update. In a round-about way, after looking at the alternatives, I realize I don’t have to replace Microsoft Money after all.
The files generated by these scripts only work with Microsoft Money. Attempting to import the same file into an older version of Quicken gave me this error:
[Update on Sept. 3, 2009: These transaction download scripts only update the prices of securities held at the institutions that provide direct OFX downloads. If you have stocks or mutual funds at institutions that don't offer OFX transaction downloads, you need a different script for updating the prices. See follow-up post Download Price Quotes to Microsoft Money After Microsoft Pulls the Plug.]
Once again, the downloads are:
- ActivePython 2.6.2 or Python 2.6.2
- The original Python scripts: ofx.py and ofx-ba.py
- (optional) A better text editor: Notepad++
- Online banking directory files for the server address and IDs
- (optional) A better zip/unzip program: 7-Zip
- TFB’s modified script for downloading interactively. Remove .txt extension. Test your settings with this one first.
- TFB’s automated script and batch file. Remove .txt extension.
- TFB’s script for downloading price quotes. Remove .txt extension.
Special thanks to:
- GnuCash community for the inspiration
- OFX Direct Connect Bank Settings on GnuCash Wiki
- Jeremy Jongsma for hosting the Python scripts and the OFX directory files
- Costin Manolache for the fix for Vanguard
- Google, for helping me find the resources above
Software picked, likely related posts:
- Replacing Microsoft Money, Part 2: Quicken
- Download Price Quotes to Microsoft Money After Microsoft Pulls the Plug
- Replacing Microsoft Money, Part 1: Requirements
Comments
140 Comments on Replacing Microsoft Money, Part 5: OFX Scripts
-
indexfundfan on August 28, 2009 |
permalink
-
TFB on August 28, 2009 |
permalink
Not directly. The brokerage statement includes the positions and the current prices. If you have positions elsewhere, those prices are not updated. However, it is conceivable to create a dummy brokerage account in Money, construct a fake OFX statement with prices from Yahoo! and then import that fake statement for the dummy accout. In your Money reports, you just exclude that dummy account. I will leave that exercise to the future or a more capable developer.
-
DT on August 28, 2009 |
permalink
Seems like all you really wanted to do was fix the
downloads issue with MS money, and now that
you’ve solved that bugaboo, you’re gonna stick
with MS Money after all. Is that about right?I mean, it appears you’ve just talked yourself
into staying with MS Money, due to these Python
scripts.Are you planning a summary post for your conclusions?
-
J on August 29, 2009 |
permalink
Not sure about MS money, but Quicken won’t import files without validating with the bank. And it won’t validate with the bank after it expires.
-
Simon Fell on August 30, 2009 |
permalink
The scripts are a nice idea for sticking with Money, but it seens like once money is dead, the OFX download format will soon be after it, and I can see most financial institutions might stop offering it.
-
TFB on August 30, 2009 |
permalink
@DT – Yes, I’m going to stick with MS Money as long as the Python scripts work. Maybe I will write a summary post after I get the stock quotes working and after I take a look at Quicken 2010.
@Simon – That’s a possibility. We will just have to see. I hope Quicken also hit those URIs and the financial institutions will continue to support Quicken. The scripts just piggy back on Quicken.
-
Chrisem on September 5, 2009 |
permalink
Well done! Thank you. At the least it buys time for other options to develop.
-
J on September 6, 2009 |
permalink
To test if import works for MS Money, try pulling the network cable after downloading the files, then do the import. If MS Money needs to phone home, like Quicken does, you should get an error during the import.
Good luck!
-
TFB on September 7, 2009 |
permalink
J – Yep, tested. After downloading the transactions, I turned off WiFi on my laptop. Money 2006 imported the files successfully.
-
T on September 8, 2009 |
permalink
TFB,
Your posts absolutely made my day. Probably my week too, which otherwise would have been spent buying Quicken and converting heaps of data into it.
I wrote a small Batch file to download and import all of my accounts, just like Money used to do, which doesn’t require a hard-coded password…posting it here in case anyone else is interested.
Thanks for the posts.
P.S… The BAT relies on your Automated Script – which accepts password as a parameter – for both Bank and CreditCard. If you have multiple accounts at the same bank, using the BAT file below requires a few small changes to the Python in order to make the filename on each OFX unique, thus to prevent overwrite. In short, change the “client.doQuery” line to include “argv[4]” as part of the filename. Something like
client.doQuery(query, argv[1]+argv[4]+dtnow+”.ofx”)-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
@echo offREM Place this .bat file in the same directory as your Python scripts.
REM delete the old files.
del *.ofxREM Prompt for password. If all accounts use the same password,
REM you’re done. Otherwise repeat this “set /p Password=” command
REM before each account having a different password.echo Enter Password
set /p Password=echo Downloading [Credit Account 1]…
python ofx.py [account] [user] %Password% [acct#]echo Downloading [Investment Account 2]…
python ofx.py [account] [user] %Password% [acct#]echo Downloading [Bank Account 3]…
python ofx-ba.py [account] [user] %Password% [acct#] [CHECKING or SAVINGS]REM repeat as necessary for each account…
echo ————————————
echo Processing files.REM this will “execute” the ofx file, which should open it in Money. If Money
REM is running, it will be imported automatically. If not, Money will process
REM the import the next time it starts.FOR %%D in (*.ofx) DO START %%D
echo Done.
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
-
Dave on September 10, 2009 |
permalink
I went through a similar procedure to the one you have been describing in your “Replacing MS Money” series.
I am evaluating two options at the moment.
My first option is to use Yodlee to handle all the downloading. It is an easier way to do the same thing you are doing with the scrips. Yodlee downloads and aggregates all my transactions from banks and investment institutions (and some other vendors too). Then I export from Yodlee and import to GnuCash. Here is a discussion with more details on UbuntuForums:
http://ubuntuforums.org/showthread.php?t=1049798The second option I’m considering is “My Money 2.0″ by MTH. I’m not sure why it never came up on my radar previously, but I’m going to test it now. Here’s a link:
http://www.mthbuilt.com/I decided that in addition to moving away from MS Money, I wanted to move away from all Microsoft products, so my goals are a bit different, although my requirementes are very similar to yours.
-
DK on September 15, 2009 |
permalink
TFB: Again I appreciate your pulling this information together. I have the following suggestions to help clarify the use of the various scripts you provide in your article:
1. Using the ofx-ba.py script for downloading bank statements requires FOUR arguments in its call, not the three you mention above:
[name of the site: which is the short name given to the site parameters in the script]
[your online login/username]
[your account number]
[CHECKING/SAVINGS].2. The modified script appears to only allow for credit card and financial institution downloads, excluding bank statements. The parameters required for this script are:
[name of the site: which is the short name given to the site parameters in the script]
[your online login/username]
[your password]
[your account number]3. The ofx.py script is for credit card and financial institution downloads only and the parameter call is as described in your article.
Thanks for your invaluable help, DK
-
TFB on September 15, 2009 |
permalink
DK – Thank you for the notes. I didn’t do anything to the ofx-ba.py script because I don’t have a bank account. I will do the same modification and update the post later.
-
Dave on September 17, 2009 |
permalink
I’m transitioning gradually from MS Money to something such as GnuCash. In the mean time it may interest others to know what I’m doing. I found out that MS Money will run in Ubuntu 9.04 under Wine 1.0 — and online banking works. Everything works**.
I’m using Money 2003 Deluxe and Business. All my online banking works. My investment account transactions are downloaded too. (Stock prices in my portfolio are not updated automatically, but that’s no big deal.)
I think these older versions of Money (e.g., 2003, 2004) lack the code that makes them stop downloading transactions.
One could revert to an older version of money by using this method:
http://wiki.github.com/mulicheng/csv2ofx/microsoft-money-mapping-fileGetting Money to work under Wine:
There are some tricks to it; find them here: http://ubuntuforums.org/showpost.php?p=7963718&postcount=13 -
TFB on September 18, 2009 |
permalink
DK – I found out that the ofx-ba.py script actually handles all three types of accounts: credit card, brokerage, and bank. I re-did my modified scripts based on ofx-ba.py. I updated the post and links. I hope everything is clear now.
-
mmblanco on September 30, 2009 |
permalink
TFB – Thanks for this valuable scripts.
I want to know if there’s a way I can update the historial values for mutual funds quote prices. I have received an excel doc with two columns, one for the date and the other for th price. I wold like to import this data into MS Money, so that I can make some index comparison, etc.
Thanks in advance. -
TFB on September 30, 2009 |
permalink
mmblanco – Sorry I don’t know how to import historical prices.
-
John Brinnand on October 1, 2009 |
permalink
TFB: Along with others I would like to thank you for sharing your solution to updating the stock/fund prices after Microsoft pulls the plug on us. I have spent a lot of time, without success, trying to come up with a way that I could retain all my information in Money and avoid having to enter over 30 stock/mutual fund prices manually – it was a big relief to find the answer on “TheFinanceBuff”.
I have had no problem using your quotes.py script to create the “ofx” file and importing the prices into Money Plus Deluxe.
Rather than having the dummy “Investment” account showing a market value I have changed the “number of units” in the script to zero. Even though Money states “You have no unread statements” it does appear to update the “Price File” on a daily basis. I tested this with 5 consecutive daily “ofx” files with no connection to the Internet.
I am quite happy to just update the prices on a daily basis after the market closes but I did see that someone would like to update the prices though out the day. The only way I have found how to do this is: -
1. Do the first update of the day as usual.
2. One the second, and subsequent updates for the same day open Money and delete the dummy “Investment Account” (As there are no open investments in it, it will delete with one click).
3. Run a price update – Money will ask you to set up a new account – click “New” and then “Next” a few times and enter “xxx” for Bank Name. Money will then import the ofx file and update the “Price File” with the latest prices.Not an ideal solution but it seems to work and could come in handy if you update before all the closing mutual fund prices are in and have to do a second update.
-
TFB on October 1, 2009 |
permalink
John – Thanks for the tip on making the number of unit zero. I never thought of that. I think that works better than unit of one because it won’t affect the holdings and reports. Let me try it. If it works well, I will update the script.
-
DK on October 1, 2009 |
permalink
TFB, I have modified the quotes.py script slightly to download historical security prices for single days. It works basically like your script. I don’t maintain a website myself, but am willing to pass the script and accompanying batch file to you for posting. I like this new option as it lets me download prices for days on which I missed downloading prices with the quotes script.
DK -
DK on October 12, 2009 |
permalink
TFB: Has anyone tried to connect to RBC Wealth Management, formerly RBC Dain Rauscher? The information from the fi file (RBC Dain Rauscher and 8035) do not work. Thanks!
-
alw on October 13, 2009 |
permalink
Am so happy and relieved to have found your site as I’ve been using and depending heavily on MS-Money for almost 15 years now and did not relish the idea of converting data to Quicken or another PF program. I’ve installed Active Python and your various scripts documented here and the quotes download works great for me. When attempting to execute your auto script though either at the command line or with the batch file I get the following error. I haven’t edited your script at all and am just attempting to use my own AmEx and Chase login credentials. Any thoughts as to the cause?
Traceback (most recent call last):
File “ofx-ba-tfb-auto.py”, line 212, in
client.doQuery(query, argv[1]+”_acct.ofx”)
File “ofx-ba-tfb-auto.py”, line 178, in doQuery
h = httplib.HTTPSConnection(host)
AttributeError: ‘module’ object has no attribute ‘HTTPSConnection’ -
alw on October 15, 2009 |
permalink
I posted the above HTTPSConnection error message and am happy to report that I’ve found resolution. It turns out that Active Python for Windows 64 OS doesn’t come with the necessary SSL support to run these scripts. I am using the 32 bit version instead now and the scripts run fine. Thanks so much TFB for this fine site and solution.
-
Bob on October 31, 2009 |
permalink
Can this be set up to just get quotes into MOney without contacting a financial institution. I don’t want updates from my bank. I just want to update stock prices
-
TFB on October 31, 2009 |
permalink
Bob – See follow-up post Download Price Quotes to Microsoft Money After Microsoft Pulls the Plug.
-
Julee on November 3, 2009 |
permalink
I am not a programmer but I am determined to keep money downloads working.
When I attempt to run the python script at the cmd prompt I get the following error message.
python: can’t open file ‘ofx.py’: [Errno 2] No such file or directory.
I have tried saving the file in a variety of places so it can be found but to no avail.
I had to use Python 2.6.3.7 and chose the Windows(x86) version, rather than the Python 2.6.2 that you suggested. It doesn’t seem to be available anymore.
-
Julee on November 3, 2009 |
permalink
Now that I have used the cd command to change directories to the python26 folder, I am getting a different message.
Traceback (most recent call last):
file “ofx.py”, line 167 in
client = OFXClient(sites[argv[1]], argv[2], passwd)
KeyError: ‘[discover]‘Please help.
-
Julee on November 4, 2009 |
permalink
I got it to work now. Thanks for giving me this fun experience of feeling like I am back in college in my beginning computer science class. Clearly I learned a LOT.
-
Julee on November 9, 2009 |
permalink
Has anyone successfully tried to download account information from an entity that uses Yodlee? I get a long string of problems relating to sending with a final soctet.error [Errno 10061]
No connection could be made because the target machine actively refused it.I have two a bank account and a couple of credit cards athat have Yodlee as the Org and use the same provider url. https://216.34.60.221/DatafeedAPI.
Please help.
-
Randy on November 11, 2009 |
permalink
When I use ofx.py to get my Scottrade account (had to add “fid” field to the sites data), I do get an ofx file. When Money imports it, I have to match every symbol to one in my account (they all seem to be the same anyways) and OK it. Then it shows all my share counts as 0. It also appears to be from 10-24-2009 and not showing any activity newer than that.
Is anyone successfully using these scripts for Scottrade?
-
Scott on November 15, 2009 |
permalink
Thanks so much for posting these scripts! These are exactly what I was looking for.
I admit that I was having problems with getting it to work with JP Morgan Retirement Services–the server kept returning 2020 error codes (something about invalid date in the request).
I tracked it down by comparing what Money was sending in its request. It turns out that JP Morgan doesn’t like to have the time included in the DTASOF field in the request–it wants only the date. In the “_invstreq” procedure, I had to add the following line:
dtnow_notime = time.strftime(”%Y%m%d”,time.localtime())
and then adjust the DTASOF parameter as follows:
_field(”DTASOF”, dtnow_notime),
I don’t know what impact this will have on other brokers, but the JP Morgan import is now working fine for me.
Thanks again!
-
Inko on November 22, 2009 |
permalink
TFB:
Thanks so much for the great work. I have one more challenge for you though. In addition to a userid and password, my bank also (during successive logins) rotates through several other predefined qualifying questions (i.e. What is your father’s middle name) as a additional security feature. Money does support this feature. When setting up the online access for this bank, you’re prompted with a ledger that itemizes the questions and responses. Any idea on how to replicate this feature in your scripts.
Thank you…Inko
-
TFB on November 22, 2009 |
permalink
Inko – Sorry, the script can’t handle that challenge.
-
George Lindauer on December 4, 2009 |
permalink
I’ve been unable to get any of these scripts to do anything for Chase using Active Python 2.6.4. It only calls five programs, the first two the originating python program and the last three to httplib.py lines 974, 391 and finally 355 before quitting.
2.6.4.Traceback (most recent call last)
httplib.py line 355, in _read_status raise BadStatusLine
httplib.BadStatusLine.Please help!
-
TFB on December 5, 2009 |
permalink
George – Chase changed the OFX server address around Nov. 15. The new address is https://ofx.chase.com. If you replace the old address https://onlineofx.chase.com/chase.ofx with that new address, it will start working again.
-
George Lindauer on December 6, 2009 |
permalink
Thanks! That worked fine.
-
Michael on December 6, 2009 |
permalink
Love the help this site is providing. To bad Microsoft won’t help us.
Can I get some insight to fixing the following error?
File “C:\Python26\lib\urllib2.py”, line 516, in http_error_default
raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)
HTTPError: HTTP Error 400: Bad RequestI’m using ofx-ba.py sample.
-
Michael on December 6, 2009 |
permalink
I got the ofx.tfb.auto.py to function.. I’ll use it. thanks. This stuff is fun.
-
DK on December 10, 2009 |
permalink
I am getting the same error as referenced in message 29. I am trying to access a bank which has Yodlee as designation. Does anyone know the source of this problem – I get urlopen error 1006: no connection could be made because target machine actively refused it. Any help will be appreciated. Thanks.
-
TFB on December 10, 2009 |
permalink
DK – This script will not work with Yodlee because Yodlee does not provide a true OFX interface. Yodlee charges Microsoft for its service. It will not let you just connect to it. If the bank itself does not provide a web download, the best workaround is perhaps using Yodlee MoneyCenter. I heard you can export to OFX from Yodlee MoneyCenter, although it’s manual, not automated.
-
Michael on December 16, 2009 |
permalink
Anybody solve the OFX URL access to Dodge and Cox mutual funds?
Thanks
-
TFB on December 17, 2009 |
permalink
Michael – According to the online banking directory zip file, Dodge & Cox mutual funds uses Yodlee. I don’t think this script will work for Dodge & Cox.
-
George on December 26, 2009 |
permalink
The ofx-ba-tfb-auto.bat works fine at Chase for a credit card but not for checking. I tried a single python script for checking
ofx-ba-tfb-auto.py chase chase_login chase_password account # CHECKING
which logs on, and produces a small OFX file but does not download banking information. The downloaded OFX information from Chase for the checking account is
0INFOSUCCESS20091226164624.986[0:GMT]ENG0INFOSUCCESS20091226181846.172[0:GMT]ENGB110898f51e5fc49b6b4494bfe3d34ab0c98aec2003ERROR4</OFX
at which point it ends.The credit card information which works for the same login without CHECKING is
0INFO4USD etcIt appears that the ERROR prevents OFX from asking for my account number. Is there something I’m missing?
-
TFB on December 27, 2009 |
permalink
George – For a bank account, you will have to put the ABA routing number in the script (modify from the “usaa” profile in the example script). If you have both a credit card and a bank account with Chase, you will need two site profiles: chase_cc with “SIGNON”, “CCSTMT” and chase_bank with “SIGNON”, “BASTMT”.
-
George on December 27, 2009 |
permalink
I tried changing the profile for chase to,
“chase”: {
“caps”: [ "SIGNON", "BASTMT" ],
“fid”: “10898″,
“fiorg”: “B1″,
“url”: “https://ofx.chase.com”,
“bankid”: “074000010″,
},where 074000010 is the routing number for Chase in Indiana but once again It read in the fid and fiorg information but then gave the CODE 2003 SEVERITY ERROR STATUS CLTCOOKIE4 STMTTRNRS BANKMSGSRSV1 with no downloaded information. Is there something else I need to change?
-
G on December 31, 2009 |
permalink
Does any body know any way to get more than 30 days of historical data? I waited about 2 months after money expired to get this working and now I’m missing a month of data. Thx
-
Michael on December 31, 2009 |
permalink
Look in the main PY routine for:
if __name__==”__main__”:
# print “Number of args”,len(argv)
dayamt = int(argv[5])
dtstart = time.strftime(”%Y%m%d”,time.localtime(time.time()- dayamt*86400))
dtnow = time.strftime(”%Y%m%d%H%M%S”,time.localtime())dayamt should be 31 (I changed this item to be a variable taken from the control cards. I changed default to 8 in my bat file.) Change to number of days you need.
-
George on December 31, 2009 |
permalink
The bank id for Chase savings apparently was incorrect. It should have been 083000137. Although I live in Indiana, and my checks use 074000010, the routing number needed was that for Kentucky! Using this, the download worked.
I just purchased a new computer and installed MM 2007 (which does not require activation) on it. I imported my data from my old computer using a .qif file and the MM program update feature successfully updated the data from Chase.
-
Michael on January 9, 2010 |
permalink
*** Here’s a heads up for MS Money users and using these routines ***
Firstly, remember to take backups before any account setting changes that deal with MSMoney’s online access setting, once your access has expired.
I discovered that after I removed the online access settings for my accounts (of which I have about 20) two things occured: First, activity previously downloaded, and then downloaded once again, from the bank showed up as new/matching existing entries and I had to ‘accept’ them end to the system. Previously, previously downloaded transactions were ignored. Second, since you have expired your MSMoney online access, you can’t restore it.
I used a backup file to get the online settings restored.
I recommend you don’t turn off your online access after MSMoney expires.Thanks so much to all the comments and help being offered at this site. It has been a life saver for me.
-
Barry on January 10, 2010 |
permalink
I have to say thank you, thank you, thank you for putting this information out on the net. I saw this script update info months ago but having little knowledge about scripts and batch files it seemed way too complicated for me. I was just going to buy Quicken but the Quicken 2010 reviews that I’ve seen have been lukewarm and I was afraid of how well the Quicken conversion tool would actually work. Since Fidelity and Vanguard are major holdings of mine I decided that since you had a working script that I would finally give this a try. It probably took me much longer than it should but I finally got downloads working for Fidelity, Vanguard, and security price updates. I still have other accounts that I will probably update manually but since I do my bill paying with Fidelity SmartCash that is the account that I really had to have updated automatically instead of manually. So screw you Microsoft, instead of getting cash from me every 2 yearsto renew my software like before now you get nothing and I still have a useful Money product. Don’t know if these companies will support OFX downloads once all current Money users are phased out but this is great for now. So thanks again to the original poster and for all the comments that followed.
-
Actigraph on January 12, 2010 |
permalink
I am still using MS money deluxe 2004 version and I am able to download my credit card and bank transactions as well as stock quotes. Here is the trick
1. Set the computer time back to some time in year 2006 or any time before the online update expiration date.
2. Run MS money, and open you file.
3. Change the computer clock back to current.
4. Update your online account, new transactions and latest stock quotes will show upIt should works with those financial institutions that have direct connect services.
-
Bobby on January 12, 2010 |
permalink
Excellent information! I found your post while looking for options to move data from Money Plus. Quicken doesn’t sound like it’s quite where I want it.
As for the scripts, they are fairly straight-forward, but being a programmer of sorts, I quickly started modifying a few things. The first was to replace the batch file with another Python script, since I wanted a “do this for real… y/n” confirmation before executing… and Python is a *much* better scripting environment than batch commands.
I now have a question regarding OFX messages. Per the OFX standard, can multiple “statements” be aggregated into one message? If so, will Money still require you press the “OK” button every time an account is updated? It would be a nice improvement to not have to “accept” the import process for every statement, even though it is trivial overall. Parsing and aggregating multiple ofx files would be easy, but is there an official OFX format for this that Money will accept?
-
Leo on January 13, 2010 |
permalink
Like others who have posted here, I like Money and do not want to change and appreciate the work you’ve done. However, I am not a programmer, but I think I understand what you’re trying to do.
Having said that, I think my requirement is not as demanding as yours. I simply want to update my fund closing prices. I looked at Google Finance (GF) and found, not unlike Yahoo, that I could create a portfolio of my funds. So, I created a portfolio with the intention of manually updating the prices (this is before I discovered your site). After I created my portfolio I noticed that I could download to OFX from GF. I thought, Hey this is great, can Money import it? Apparently it can and does. At least when I tried it, something was imported as I got a success message. But, I don’t know what happened as none of the prices were updated. I guess my problem is that I don’t know how the import function works. Can someone help?
Thanks in advance.
-
TFB on January 13, 2010 |
permalink
Leo – If you open the OFX file from Google Finance in a text editor, you will see it doesn’t have the current prices. That’s why Money didn’t update anything. I will release a small application with a graphical user interface for updating the prices shortly. Stay tuned.
-
Leo on January 14, 2010 |
permalink
Thanks for the quick reply.
Yes, you are correct there aren’t any prices in the OFX file. But, I don’t understand. What is the point of the download OFX option in Google Finance? What data is a person downloading?
I’ll stay tuned for the GUI application and perhaps then you might explain why there are no prices.
Thanks again for all you do.
-
TFB on January 14, 2010 |
permalink
Leo – I can’t answer for Google Finance because I only knew about its export to OFX feature after you brought it up. It looks like you can enter buys and sells on Google Finance and then download those buys and sells to OFX.
-
Barry on January 14, 2010 |
permalink
Is there any down side to changing the system date as suggested by Actigraph?. I tried it and it works. I like this idea better than running the scrips because I have some investments that I have not yet set up to update using the script.
-
c230 on January 16, 2010 |
permalink
Are you aware of a solution with Schwab brokerage? The ofx that I get with QWIN 1700 only contains account numbers – no transactions or positions. I tried MICROSOFT MONEY 1700, but that produces Traceback errors.
-
c230 on January 16, 2010 |
permalink
In the previous post I meant I changed the appid and appver values from QWIN and 1800 to MONEY PLUS and 1800 respectively.
-
Denis on January 19, 2010 |
permalink
Hi,
Thank you for all these information.
You said that in your last Python script, you managed to launch Money import Handler automatically to download your ofx file into money.
I had a look at your script, but could’nt figure out where this instruction was (the script seems to be troncated somewhere). Could you give me this part of code ?
Thanks
-
TFB on January 19, 2010 |
permalink
Dennis – In the automated transaction download script, this line starts the Money import handler:
os.startfile(”\”" + os.getcwd() + “\\” + name + “\”")
-
TFB on January 19, 2010 |
permalink
c230 – If you read the notes on GnuCash Wiki, you will see other people had the same problem with downloading from Schwab using GnuCash. Sorry I don’t know what the correct settings are for Schwab or if it’s possible to download from Schwab at all.
-
c230 on January 19, 2010 |
permalink
Thanks for the reply. I’ve escalated my request at Schwab to hopefully provide some means of initiating the generation of an ofx file. It sounds like the Direct Connect that Schwab uses is a two-way conversation to generate the ofx, rather than a simple download.
I haven’t had luck with Discover yet either, but maybe I need to let a couple of days pass before trying again. I get no errors, but no transactions either.
-
TFB on January 19, 2010 |
permalink
From Scott via e-mail:
Schwab has been working fine for me with these scripts, for both bank and brokerage:
“schwab”: {
“caps”: [ "SIGNON", "INVSTMT" ],
“fiorg”: “ISC”,
“fid”: “5104″,
“url”: “https://ofx.schwab.com/cgi_dev/ofx_server”,
},“schwabbank”: {
“caps”: [ "SIGNON", "BASTMT" ],
“fid”: “101″,
“fiorg”: “ISC”,
“url”: “https://ofx.schwab.com/bankcgi_dev/ofx_server”,
“bankid”: “121202211″
}, -
c230 on January 19, 2010 |
permalink
After downloading my Schwab statements, Money wants to change all of my positions to a quantity of 0. I wonder what values Scott is using for appid and appver. I’ve been using QWIN and 1700.
-
John Brinnand on January 19, 2010 |
permalink
Would appreciate it if anyone can provide the script to download prices for a specific date.
This would be handy for getting month-end prices after the fact.Thanks
-
Scott on January 19, 2010 |
permalink
I’m using appid/appver QWIN, 1800. All of my position information seems to be getting recorded properly as well. Are you at least getting the transactions through?
I also made some changes to the date functionality (see comment 31 for details) to make the script work with another service provider. I could have sworn that Schwab was working before I implemented those, but I suppose you could try implementing them too.
-
TFB on January 19, 2010 |
permalink
John Brinnand – Reader DK sent me histquot.py. It downloads quotes for a specific date in YYYYMMDD format. I have not had the chance to test it. I’m posting it AS-IS.
-
c230 on January 20, 2010 |
permalink
Thanks Scott,
My Money online services haven’t expired yet – I’m trying out these scripts ahead of time, so I don’t need to try the date trick. I’ll keep trying different things…
-
c230 on January 20, 2010 |
permalink
TFB,
Is it your understanding that online services have to be turned off in Money in order for these scripts to work? Perhaps that is why my “successful” ofx files don’t actually do anything. My quotes.py script works fine for the Dummy account (which doesn’t have any online services associated with it).
-
c230 on January 20, 2010 |
permalink
Scott,
My browser (IE8) only shows the last digit of the comment # in the TFB Blog, so I was looking at the wrong one #51 instead of #31). Now I know which one you referred to. I am not getting an error like you did with JPMorgan, but I’ll try your suggestion anyways.
-
Michael on January 20, 2010 |
permalink
C230, post #70
Refer to prior post #49.
Don’t remove the online update status to your accounts. You can run these OFX downloads and run MSMoney udpates (until they expire) at the same time.
If you remove online update status and MSMoney expires, you must restore your money file from a backup when the accounts had update status to reinstate update status.
Michael -
TFB on January 20, 2010 |
permalink
c230 – The transaction download script downloads transactions. Money is smart enough to know which transactions have been already downloaded and which ones are new. For this script to show anything in Money, there have to be new transactions not yet downloaded. Don’t remove online update. Just stop using it for a few days or at least check off the box in the list of accounts to be updated for the account you are testing. Test again when there are new transactions in the account you haven’t downloaded before.
-
c230 on January 20, 2010 |
permalink
Michael,
Thanx for the ALERT. I remembered reading #49, but was curious whether the scripts and online updates could be run simultaneously, which as you point out now – yes they can. Unless someone else chimes in, I’m going to give up on Schwab brokerage downloads for now, as I am not having any success.
Dan
-
c230 on January 20, 2010 |
permalink
TFB,
Sorry for my high count of blog comments
After running the scripts several times this morning for both Discover and Schwab, with no transactions or positions ending up in the ofx files this morning, I did the Money online update and got 7 Discover transactions and 5 Schwab transactions. So there were transactions in the que. I’m giving up for now…
Dan
-
c230 on January 20, 2010 |
permalink
TFB,
I ran the scripts several times this morning for both Schwab Brokerage and Discover CC and got no transactions in either ofx file. Then when I ran the Money online update I received several transactions from both, so I know they were in the que.
I give up for now…
-
Scott on January 20, 2010 |
permalink
c230,
Earlier, you mentioned that you received only account numbers in your downloaded transaction file. Is that still the case?
This is what happens for me if I call the script using only my Schwab account credentials and not an account number–this asks Schwab to just list your accounts and nothing else.
If I provide the account number on the command line when executing the script, it should download the actual account content an transactions for the account.
I’m not sure if this is obvious or not, but I thought I’d point it out. if you are in fact including the account number and it’s still not working, I’d be interested to know what is actually contained in the resulting OFX file.
-
c230 on January 20, 2010 |
permalink
It wasn’t obvious to me Scott. THANK YOU! That did the trick – so you get an ofx file for each account. I looked in the ofx file and Wala, the transactions were there AND the positions.
TFB – If this was pointed out, I missed it, but to help others, I think it should be pointed out that if you have multiple accounts at a brokerage, you need to run the script for each account. Now that I look in your batch file, I see you spell out [acct 1] and [acct2] but for some reason, that didn’t strike a chord until Scott mentioned it.
-
Michael on January 20, 2010 |
permalink
C230,
I have no trouble with Discover Card. Here’s my setup structure:
“discvr”: {
“caps”: [ "SIGNON", "CCSTMT" ],
“fiorg”: “Discover Financial Services”,
“fid”: “7101″,
“url”: “https://ofx.discovercard.com/”,
},
I don’t have Schwab. Have you edited the ofx file to see if it has any comments or error codes? -
c230 on January 20, 2010 |
permalink
Michael,
Well now that Schwab works, I just have Discover to work on…
my ofx file seems fine other than that there are no transactions – I see my credit card #.
0INFO20100120104329.942[-5:EST]ENGDiscover Financial Services71012f9a099888404c3c8a0d08d78979955c0INFO419990101170000 my credit card number YNNACTIVEIs this the same situation where I need to have the account # in the command line?
-
Bobby on January 20, 2010 |
permalink
I don’t have access to my files right now, but Discover works fine. Post #78 matches my memory. As with others, you *must* include the account #. Login for Discover is usually the account# plus password, but you still have to include an account# in the account field (last parameter input to the script call I believe).
-
Michael on January 20, 2010 |
permalink
control card:
python ofx-ba-auto.py discvr %discpwd%I take password from the download.bat file.
is your discover userid
is your discover card account number. 16 digets. -
Michael on January 20, 2010 |
permalink
control card:
python ofx-ba-auto.py discvr $userid$ %discpwd% $acctnbr$I take password from the download.bat file.
$userid$ is your discover userid
$acctnbr$ is your discover card account number. 16 digets. -
c230 on January 20, 2010 |
permalink
OK, thanks everyone. I’ve always heard that ofx downloads were “smart” in that you didn’t have to worry about duplication of transactions, etc., so I incorrectly assumed that since the ofx contained the account number(s) already, they didn’t need to be input as a variable. I sure was wrong!!
Hopefully if TFB adds a note like “Unless account number is part of your python statement, you will not input any positions or transactions in your Money import file.”, this will save others from going through the frustration I experienced.
-
c230 on January 20, 2010 |
permalink
I sure feel stupid! Nowhere is it implied that account number is optional, so I don’t know why I kept omitting it. All is well now – all of the scripts work great.
TFB, you’ve got a great blog, and I’ve joined your Facebook group to insure I don’t miss your postings now that I’ve found you through the Microsoft Money Discussion Group. The python scripts will keep Money going for quite awhile.
-
Bobby on January 20, 2010 |
permalink
FWIW, I’m having an issue with duplicate entries on Discover downloads. I’ve found that duplicate entries randomly match existing transactions. If I fix the duplicates, and then re-download the transactions soon after, all is well. If I come back and do the same a few days later, it re-enters a bunch of duplicate transactions again… not all of them, but a lot. It seems random as to which ones don’t match correctly. I’m going to watch this and see what happens, but if there’s a setting in Money, I’d be interested to hear about it. Otherwise, I’ll look into a fix on the OFX end of things.
-
c230 on January 20, 2010 |
permalink
Bobby,
I got 49 Discover transactions today in my ofx file that were all repeats. I right clicked each one and selected delete rather than accepting them to delete later. I don’t plan on doing both methods in parallel, so I didn’t see this as a problem.
My guess is that if we only use the python script method, as TFB stated – we probably won’t get repeats.
-
Bobby on January 20, 2010 |
permalink
As of now, I’m only using the scripts. Before starting, I deleted all online connections in Money, and then started *only* using the OFX script. It works well, except that the duplicate entries for Discover are random and Money doesn’t see them as duplicates. What is odd, is that it only happens w/ Discover and it doesn’t happen with every transaction. It’s either a date/time issue (something I saw w/ Discover and Money before), or maybe something to do with the recent deletion of the online connections within Money itself. I’m going to shorten my download window to maybe 10 days for a while, and see if it gets past the issue once I’ve gone past the 10-day window.
-
c230 on January 20, 2010 |
permalink
I don’t like the idea of having a batch file with all of my account numbers, passwords, userids, etc. so I’m going to try QuickBFC to encrypt the file:
Quick Batch File Compiler convert your batch files into actual program (.EXE format) in one click. This program may be run on Windows 2000/2003/XP/Vista without any limitations. An .EXE file is much harder to casually reverse-engineer, so this could be a way to conceal a particular batch file’s operations from an end user. Content of your batch file will be encrypted and protected from changes.
I’ll let you know how I like it afterwards.
-
hokie94 on January 21, 2010 |
permalink
The “Bank Balance” for my accounts do not update. Is there something I’m missing? Some other piece of code that needs to be written that will make Money read the “Bank Balance” that is listed in the ofx file and update it within money?
Thanks
-
c230 on January 22, 2010 |
permalink
I’ll see if I can help. When you click on “View downloaded statements”, you’ll see 2 columns – Bank balance and Local balance. If you reconcile your accounts periodically, the amounts should match, or at least be pretty close, depending on whether you have future transactions recorded etc. (ie. upcoming bills paid).
If you are downloading statements, you’ll see the summary of that downloaded statement when you click on the “unread” account, but for cash accounts at a brokerage, you may be working off a delta from your last reconciliation (daily updates vs. a monthly statement as an example.
See if you are still having a problem after reconciling your accounts.
-
hokie94 on January 22, 2010 |
permalink
c230
I’m not sure I was clear with my question.Currently, the “Bank Balance” column indicates that Bank balance as of my last “live” download (12/15/09) which was the last time I was able to download information within MS Money, not using any of the awesome scripts here.
Now, when I use the scripts, the bank balance remains unchanged from 12/15/09. New transactions download just fine, but ht “Bank Balance” remains what it was on 12/15/09. I tend not to like a discrepancy between the “Bank Balance” and the “Local Balance” and moving forward, if that balance does not update (ever), this is going to be an issue.
Thanks for any help you can provide on the issue.
-
c230 on January 22, 2010 |
permalink
I’ll have to defer to someone else as I only have 1 day’s experience with the script
I saw that the correct bank balance was there, but it may have already been correct. If you get paper statements once per month or check the web statement and reconcile atleast that frequently, then I think I’d have confidence in the balance. My brokerage cash accounts don’t even transmit a balance, so I reconcile them every 6 months or so and have never had a problem, since all of the transactions are downloaded.
-
c230 on January 23, 2010 |
permalink
Bobby,
It seems that you are correct regarding a slight difference in the downloaded transactions vs. the online updates. A sample of a downloaded transaction…
STMTTRN
DEBIT
DTPOSTED>20100110170000
TRNAMT>-35.79
FITID>FITID20100111-35.7900021
NAME>Sams Club – #4778 Auburn Hills M
/STMTTRNindicates that it has got to be either the date/time or the ID#. Not really a problem except as you stated they have to be manually matched if running both updates in parallel.
hokie94,
If you look at the end of your ofx file you should see your balance info…
LEDGERBAL
BALAMT>-1258.57
DTASOF>20100121070000
/LEDGERBALso you can verify that it is part of the file.
By the way, a tool you might find handy is MT2OFX at http://www.mt2ofx.tk/ which can take CSV, QIF, and OFC files and reformat them into OFX for import into Money. It also makes an OFX file easier to read.
-
hokie94 on January 23, 2010 |
permalink
C230
I see the balance in the ofx files for all statements I download. What I’m asking (humbly requesting) is that someone write some code so that that part of the ofx file is read and updated by money.
The other nice to have option would be to delete ofx files that are processed.
I don’t mean to sound ungrateful…these scripts are absolutely awesome and a lifesaver.
-
c230 on January 23, 2010 |
permalink
The 2nd part of your request is easy if you’re using a batch file. and it was posted by T (comment 10). You can’t delete them until they’ve been processed, so it’s much easier to delete them the next time you’re creating ofx files.
————————————-
@echo off
REM Place this .bat file in the same directory as your Python scripts.
REM delete the old files.
del *.ofxecho Downloading Discover
python….————————————-
As to the 1st part of your request, there is no code to write for Money, it should just happen (but doesn’t always, as you know) if the data is compatible. I waiting for an expert to chime in, yet still trying to help. You could try changing appid and appver values from QWIN and 1800 to MONEY PLUS and 1700 respectively. You could also try opening Sample.mny and creating an account from scratch to try your ofx on to see if the expected results occur.
-
c230 on January 24, 2010 |
permalink
TFB,
Using your automated script and batch file example, I’ve done the same and included your Quote script as well. Then in order to not have a batch file on my PC with sensitive information, I downloaded Quick BFC from http://www.abyssmedia.com/quickbfc/ and it creates an encoded EXE file so that you can get rid of the batch file. You simply open the bat file, click on the Build button, and name your new file (keep it in the same folder as your python scripts). I’m happy to report that it works very nicely.
If you need to make changes, simply repeat the entire process, as you can’t edit the EXE file.
——————————————
@echo offREM Place this .bat file in the same directory as your Python scripts.
REM delete the old files.
del *.ofxecho Downloading [name of the site]
python ofx-ba-tfb-auto.py [name of the site] [your online login] [your online password] [your account number]— repeat for all of your other accounts using TFB’s automated script…
echo Downloading other quotes
python quotes.pyecho Done.
—————————————— -
Bobby on January 24, 2010 |
permalink
After multiple tests, Money would always duplicate Discover transactions and rarely match them. I have no idea why, but it is obviously unacceptable. So, I began editing the script and started using the last download date+time for each account. That fixed the credit account “duplicates”. Unfortunately, this did not work for a Vanguard account that I have. Requesting too short of a time interval for that account produces a malformed OFX file, that subsequently crashes Money. Not good!
The fix I’m using now is to remember the last connect time for credit and bank accounts, but to use a 90 day window for brokerage accounts. It’s working perfectly. I placed the data get function inside an exception clause so that if the https connection fails, the “last date/time” doesn’t update. I’m going to add a check that the OFX file was created and isn’t empty as well. A better option will be to include a “time window” field in the data structure for each account, where the default window is some # of days (or zero to use the last successful time).
There’s probably more to this than I’m remembering right now (I did the coding last week), but it’s looking good. If anyone is interested, I can see if I can figure a way to post it somewhere. FWIW, I’m using a Python wrapper rather than a batch file. I had never used Python until now, but I’m hooked (I program a lot and *have* used other scripting shells, but never Python for some reason).
-
c230 on January 24, 2010 |
permalink
Bobby,
I found an old Moneydance trouble ticket (#1193 http://moneydance.com/trac/ticket/1193 ) regarding duplicate Discover transactions and sure enough I’m experiencing the same thing. If you compare my sample transaction in comment 94 to this:
STMTTRN
DEBIT
DTPOSTED>20100110170000
TRNAMT>-35.79
FITID>FITID20100111-35.7900022
NAME>Sams Club – #4778 Auburn Hills M
/STMTTRNyou’ll see that the last digit of the ID# is different, which explains why the transaction doesn’t match up with a previously downloaded duplicate. This is the same condition that others have experienced for the last 2 – 3 years with no apparent fix. I can’t find an explanation as to why Discover would do this.
So I thought I’d try downloading from the website to see if that would be less troublesome than the scripted ofx request and I get this as part of 46 duplicates:
STMTTRN
DEBIT
DTPOSTED>20100110170000
TRNAMT>-35.79
FITID>FITID20100111-35.790
NAME>Sams Club – #4778 Auburn Hills M
/STMTTRN———————————–
My conclusion/finding/request: Perhaps TFB can modify the code to only obtain the first 3 digits after the ID# decimal, rather than all 7 digits.
-
c230 on January 25, 2010 |
permalink
Bobby,
I also noted that the FID for Discover using the Web OFX download is 9625 vs. 7101, so I tried that in the OFX.PY thinking that it might generate the data differently, but I got an error instead. I still think the solution might be to truncate the last 4 digits of the generated FITID (transaction ID) for the Discover OFX.
To try out my theory, someone that hasn’t downloaded Discover transactions via OFX.PY could manually modify their OFX file generated from the Discover website “Download into Money” option, prior to importing the file into Money.
-
c230 on January 25, 2010 |
permalink
Too bad we can’t edit our postings…
What I meant to say was – To try out my theory, someone that hasn’t downloaded Discover transactions via OFX.PY could manually modify their OFX file generated from the script prior to importing the file into Money.
I’m pretty sure that I’ve triggered the Discover website “Download into Money” option before trying these scripts and didn’t get the duplicates after the file imported into Money.
,
-
Bobby on January 26, 2010 |
permalink
I plan to develop a fix for the Discover transactions soon. I have been testing a method that doesn’t require truncating the FITID value, but it has a glitch itself. I’ll probably write something up elsewhere and provide a link, since a comment post doesn’t work very well.
-
c230 on January 26, 2010 |
permalink
Bobby,
Just a thought (that perhaps coincides with your plan). Before deleting all of the ofx files, the name of the existing Discover file (discover20100125104535.ofx as an example) could be used to determine the start date of requested transactions, rather than the default 30 days.
Dan
-
hokie94 on January 26, 2010 |
permalink
Folks…I discovered something that maybe useful to some.
I changed my system date to a day prior to when my software “expired” (just changed the year to 2009). I opened my money file. I changed the date back to the current date. I was able to update all of my accounts. No scripts needed. I have bank and credit card accounts. Not sure if anyone has tried this before, but it works for me.
Anybody willing to figure out and post what the registry entry is for the expiration date?
-
c230 on January 26, 2010 |
permalink
The fact still remains that come next January, Microsoft is pulling the plug on their Money servers, so this activity for many of us is proactive – we’re preparing for going offline, but not there yet.
-
Michael on January 26, 2010 |
permalink
Here’s something I found on the web: Save computer date; Reset computer date; start up program; restore computer date. It might help speed up the process:
set saved=%DATE%
set date=01-03-09
start msmoney
set date=%saved%Maybe at this point, you can launch the OFX file extracts for money.
-
Bobby on January 27, 2010 |
permalink
Changing the system date before start-up does work, but it’s not a good idea to use Money with the date set back. By my current understanding, Money relies on OFX data files that reside a Microsoft server. When they pull those (and they will), Money will no longer have what it needs, regardless of the system date.
-
Ken on January 28, 2010 |
permalink
Thanks for your efforts !
I have downloaded the scripts and have run them. As I do a lot of programming at work I have made some modifications to output file names and locations. I have also written a script to decipher JHancock price quotes from a download of their daily “Investment Options” page where they list their prices.
I have two questions:
1. Regarding the activity script … the import file from Fidelity returned my monthly statement activity. Have you, or anyone for that matter, found how to download daily activity for just the previous day(s), as MsMoney Plus DeLuxe 2008 used to download ? This would be like downloading the history for the last 2-3 days or something like that.
2. The updates appear in the price listings (Select update prices\update prices manually…”) by date with a Source = “update” rather than “online.” “Update” prices are not used to calculate the “Change” in price value or the “TotalChange” value columns I include on some of my listings, whereas “Online” price values do result in these calculations. Any idea how to modify the scripts to make these “Online” price updates rather than “Update” price updates?
Thanks again,
Ken
-
TFB on January 28, 2010 |
permalink
Ken – The script has hard coded to download 30 days of activities. It’s controlled by this line:
dtstart = time.strftime(”%Y%m%d”,time.localtime(time.time()-31*86400))
If you want to make it download for fewer days, or remember the last download date and time and resume from that point, just play with that dtstart variable.
What Money does with the imported prices is controlled by Money. I don’t think there’s way to force it to treat the prices as “Online” as opposed to “Update.”
-
schecker on January 30, 2010 |
permalink
I am trying to download brokerage transactions from E*Trade. The download works, shows success and my account no. etc. but does not bring down the detailed transactions. What could I be missing? I am using the ofx-ba-tfb-auto.py script.
-
CH on January 30, 2010 |
permalink
Thank you TFB for all your hard work. I was able to get Scottrade to work. The key for me was that the brokerid is not the same as the org. I changed the line
_field(”BROKERID”, brokerid),
to be
_field(”BROKERID”, “www.scottrade.com”),
and it started working. I know this breaks it for other brokerages and I was hoping you might amend the script in a better way.
Before this modification, the OFX file would say that it logged in successfully, but then have a 2003 ERROR.
Thank you again, this has been a real life saver!
CH -
c230 on January 30, 2010 |
permalink
CH,
Per the Online Banking Directory, 5468.xml – Scottrade in your py script should read something like:
“scottrade”: {
“caps”: [ "SIGNON", "INVSTMT" ],
“fiorg”: “scottsave.com”,
“url”: “https://ofxstl.scottsave.com”,but if “www.scottrade.com” works better, change the fiorg to that instead and return the brokerid code as it was.
schecker,
You’re not making the same error I made in omitting the account number, are you?
-
MDB on January 30, 2010 |
permalink
Maybe you might consider AceMoney as an alternative to MS Money; just a thought.
-
schecker on January 30, 2010 |
permalink
I was able to get e*trade brokerage to work by using etrade.com in the fiorg section instead of what the downloaded xml contained. etrade.com was in the brokerid section of the xml.
Has anyone been able to make Wells Fargo Credit Card work?
-
Bobby on February 5, 2010 |
permalink
OK… after messing with this for a while to fix the Discover issue, I then ended up modifying/adding code to the extent that I decided to do a little write-up on it. I wrote too much for my taste, but what the heck… it’s done now.
If interested, you can read about it at:
http://sites.google.com/site/pocketsense/Note: I’m not a web-guy… and created the site and entry for the sole purpose of sharing/discussing the OFX import to Money. I didn’t realize until well into doing it how much time I would spend describing what’s going on… live and learn.
If you have comments, I *think* you can leave them on the site.
-
Dan on February 6, 2010 |
permalink
Bobby,
Great Job!! I will be one of your first testers. I couldn’t find a way to leave a comment on your site, by the way. That scubber code for Discover is exactly what I was looking for.
-
Dan on February 6, 2010 |
permalink
Bobby,
We really shouldn’t bring up issues on your scripts on this forum, but you don’t have contact info or a comments method. Your setup.py bombs out on me when testing Discover ….
Traceback:
File “setup.py”, line 253, in
test_acct(AcctArray[acctnum])
File “setup.py”, line 111, in test_acct
if ofx.getOFX(acct) == 0:
File “C:\Documents and Settings\…\ofx.py
“, line 191, in getOFX
minInterval = float(Sites[sitename]['minInterval']) #minimum interval (da
ys) defined for this site
KeyError: ‘minInterval’ -
Dan on February 6, 2010 |
permalink
Never mind Bobby,
I had copied the institution data from TFB’s script and omitted to add the minInterval variable in the control.py
-
Bobby on February 6, 2010 |
permalink
Dan: I added a comments page, but apparently it only works if a person has been explicitly “invited”? Rather than try to figure that out tonight, I just added a link to a blogspot.com entry for this topic. Hopefully, that works better.
Sorry about the minInterval issue, I forgot to mention that on the setup page. It was the way I fixed the issue w/ Vanguard requiring longer intervals than the others. I’ll update the instructions for anyone trying to copy their prior stuff over.
-
steve on February 7, 2010 |
permalink
Please help. After working my way through this fix, I can’t seem to get past an error on line 163 in my ofx.py file that says: tuple indices must be integers, not str. This happens after it prompts me to enter my password.
-
Troy on February 7, 2010 |
permalink
Firstly, thank you very much for this. I’ve been downloading quotes for a couple of months and now I’m trying to set up credit card and investment account downloads.
I’ve gotten all other accounts to work except for New York Life and Principal investment accounts. Has anybody gotten these to download using the scripts. Here is the code I have entered:
“nyl”: {
“caps”: [ "SIGNON", "INVSTMT" ],
“fiorg”: “Yodlee”,
“fid”: “9111″,
“url”: “https://216.34.60.221/DatafeedAPI”,
},“principal”: {
“caps”: [ "SIGNON", "INVSTMT" ],
“fiorg”: “Yodlee”,
“fid”: “3776″,
“url”: “https://216.34.60.221/DatafeedAPI”,
}, -
c230 on February 7, 2010 |
permalink
Troy,
The scripts do not work with Yodlee unfortunately.Steve,
Were you inquiring about scripts by TFB or Bobby? (We should respectfully address questions to Bobby on his Blog comments page) -
Steve on February 8, 2010 |
permalink
Sorry about the confusion, my question was to TFB and the suggested ofx.py script.
-
TFB on February 8, 2010 |
permalink
Steve – You will have to show us what you had in the sites section. The script can throw an error if you missed a comma, a quote, a square bracket, or a curly brace, or if you had one too many of those. I would also suggest you use ofx-ba-tfb.py with the changes I made for Windows.
-
Steve on February 8, 2010 |
permalink
Okay, I’ve pasted below the section from my sites:
sites = {
“fidelity”: {
“caps”: [ "SIGNON", "INVSTMT" ],
“fid”: “7776″,
“fiorg”: “fidelity.com”,
“url”: “https://ofx.fidelity.com/ftgw/OFX/clients/download”,
},
},I tried removing the extra }, but then I received an error saying invalid syntax on line 18 which has def _field (tag,value):
I don’t believe I have the file ofx-ba-tfb.py? I only have ofx-ba.py which I tried but get the same error but on line 183 which says: client = OFXClient(sites[argv[1]], argv[2], passwd)
-
TFB on February 8, 2010 |
permalink
Steve – Remove that very last comma. Make it
sites = {
“fidelity”: {
“caps”: [ "SIGNON", "INVSTMT" ],
“fid”: “7776″,
“fiorg”: “fidelity.com”,
“url”: “https://ofx.fidelity.com/ftgw/OFX/clients/download”,
},
} -
matt on February 9, 2010 |
permalink
Hi, trying to get this to work, followed the steps correctly, i think, but get an error trying to execute the b-a py:
File “ofx-ba.py”, line 69
req = _tag(”STMTRQ”,
^
whats the correct syntax for executing the script from cmd? -
TFB on February 9, 2010 |
permalink
Matt – If you are using the original ofx-ba.py, without my modifications,
python ofx-ba.py [name of the site] [your online login] [your account number] [CHECKING or SAVINGS]
The script will prompt you for the password.
-
matt on February 9, 2010 |
permalink
Hi again,
Yeah, i followed the steps listed above, but I still get that error. Are the parameters encapsulated in brackets [ ]?
-
matt on February 9, 2010 |
permalink
So, I made a bit of progress. I installed an earlier version of Python (2.6) and followed the steps, again. I got further, it prompted me for a password, but then returns:
Traceback (most recent call last):
File “ofx-ba.py”, line 182, in
client = OFXClient(sites[argv[1]], argv[2], passwd)
KeyError: ‘[test]‘Im throwing it:
python ofx-ba.py [test] [account] [CHECKING]if i just do python ofx-ba.py, it tells me that test is an available site. Any ideas?
-
matt on February 9, 2010 |
permalink
Ah, got it. Missed a param. Now I get an error 15500
-
Matt on February 10, 2010 |
permalink
Hi all,
I finally figured out the error – Wells Fargo is one of the banks that charges for OFX connectivity.
Would anyone be willing to send me some sample checking/debit card transactions that are returned from their banks service? I am trying to build a DTD that will normalize data. Yeah, they should be following the ofx spec, but you know how that goes.
If so, you can axe any confidential info – just make sure you give me the bank name. I’ll create a public wiki just in case anyone else wants this info.
-
circuit_breaker on February 19, 2010 |
permalink
I’m the guy that extended ofx.py to include checking/savings and released it as ofx-ba.py. I guess I could have documented it better, and it does contain an ugly hack that shows my ignorance of python.. but it was my first time ever working with python, and it was thoroughly enjoyable. I’m really glad to see it scattered around the web now helping other people. I can’t really claim to be able to support well it as I haven’t used it in YEARS myself.. but I may soon use it again as I recently wrote myself a fancy check balancing spreadsheet. This would integrate well with that… so you might see some more OFX related code from me. But this time it will be in perl with a Gtk front-end
-
circuit_breaker on February 19, 2010 |
permalink
By the way, guys, you do NOT need to enclose the arguments to ofx-ba.py with [ ]’s. I’m not sure why I wrote it that way, too long ago!
-
Michael on February 23, 2010 |
permalink
I’ve been using this for some time, and it works pretty good.
Just curious, is there any encription going on for these requests to the financial groups?
What’s the chance that some web skimmer won’t find these things and get access to our passwords, etc?
Any ideas out there?
-
Bobby on February 23, 2010 |
permalink
Michael: Yes, the connection occurs via a secure, encrypted (HTTPS) connection. You may be interested in the modified scripts I put together too. I started with the stuff posted here, but modified quite a bit and wrapped the whole thing with a “user configuration” shell. The primary reason I headed down that path was to allow encryption of locally stored account info, including user-names and passwords, but I extended the effort a bit. You can read more @ http://sites.google.com/site/pocketsense/home/msmoneyfixp1 .
-
Michael on February 23, 2010 |
permalink
Bobby, thanks for the update. I feel safer.
I did try Quicken 2010 Deluxe, and boy is it ‘clunky’! Not a smooth GUI like Money.
Anyway, while trying Quicken, I noticed that I could get Oppenhiemer accounts.Does anyboy out there access Oppenheimer with the OFX downloads? If so, what is their URL and FID codes, etc.
Thanks, Michael
-
ameridan on February 23, 2010 |
permalink
Try these:
“fiorg” = “Oppenheimer”
“fid” = “125″
“url” = “https://ofx.opco.com/eftxweb/access.ofx” -
ameridan on February 23, 2010 |
permalink
I’ve found (and published) a very populated file that Moneydance keeps up-to-date with FI settings that don’t seem to be available on the GnuCash site, for those trying to locate their settings for the OFX scripts.
http://microsoftmoneyoffline.wordpress.com/moneydance-ofx-settings/
ENJOY!
-
ameridan on February 25, 2010 |
permalink
For those that might be interested, I’ve come up with a method to run the OFX scripts (Bobby’s PocketSense in particular) from with the Money program to replace the “Update Online Information” function that we currently use. Although a shortcut in the Toolbar would have been my preferred method, this webpage approach doesn’t require any hacking into the program.
Read more here:
Tell me what you're thinking, but please don't spam. See comments moderation policy.



tfb, would the above scripts also download security prices?