Monday, February 27, 2006

Automatically restarting the Application

The Microsoft Money FAQ site is running ASP.NET 2.0, and is developed on my home machine before being manually copied across to the live site.

One curious thing that has started happening to the site, and I believe it is new to ASP.NET 2.0 in the way that it compiles code, is that I sometimes see errors like this:

Exception information:
Exception type: System.IO.FileNotFoundException
Exception message: Could not load file or assembly 'App_Web_muq0ffjm, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified.


Over the last week, this error has been logged about 1000 times :-( And they always seem to start in the middle of the night, just when I won't notice....

The most annoying fact for me is that users see just error, even though the error is in the compilation of one minor component which could be safely ignored. I haven't found a solution to this apparent compilation problem, but I have now installed a workaround, so hopefully it should appear a lot less.

The basic premise is this - the Global.asax file has the following code:
Sub Application_Start(ByVal sender As Object, ByVal e As EventArgs)
' Code that runs on application startup
Application.Item("appErrors") = 0
End Sub

Sub Application_Error(ByVal sender As Object, ByVal e As EventArgs)
' Code that runs when an unhandled error occurs
Application.Lock()
Application("appErrors") = CInt(Application("appErrors")) + 1
Application.UnLock()

If CInt(Application("appErrors")) > 10 Then
' restart application
rewriteConfig()
End If
End Sub
The idea is that I have a threshold (I use a setting from web.config, but have used '10' in the example above) when I reach a certain number of errors, the restart application code fires.

The code to restart the application rewrites the web.config file, which forces the application to reload. This code doesn't have to be used in the same application as the one it is restarting, which is good for additional security.
Private Sub rewriteConfig()
Try
Dim cfg As System.Configuration.Configuration
cfg = WebConfigurationManager.OpenWebConfiguration("~")

Dim compilation As CompilationSection
compilation = CType(cfg.GetSection("system.web/compilation"), CompilationSection)
If Not (compilation Is Nothing) Then

compilation.Debug = Not compilation.Debug
compilation.Debug = False
config.Save()
End If
Catch ex As Exception
End Try
End Sub
Only time will tell me whether this will work, but hopefully less errors will now be seen.

If you're having similar problems, then see if this will help you. You may need to use impersonation if your application can't write directly to the web.config file.

It would be nice to use Health Monitoring to do this for me, as that seems to me to be a 'cleaner' way of doing things, but at least this is one step on the way to reducing the occurrence of the error.

Saturday, February 25, 2006

How much will this purchase cost

The "How much will this purchase cost" tool is similar to the mini debt reduction planner - so much so, they are in the same place in Microsoft Money.

Another very simple tool which is in certain versions of Microsoft Money, but hard to find, as it is buried within the program.

This one basically gives you a guide on how much something you buy will cost, when you add in interest charges etc.

Mini Debt Reduction Planner

The Mini Debt Reduction Planner tool is a tool buried within Microsoft Money. Often I forget it is there, and so go to Excel or the Web to find one for my needs.

Simple tool within the program, difficult to track down. Hopefully more people will know about this and use the tool.


It is similar to the how much will this purchase cost tool, which is also on the same page.

The mini debt reduction planner is not a substitute for the proper debt reduction planner in the program.

New Article - "Downloaded date on the account register"

I have added a new article - Downloaded date on the account register.

This is a reasonably frequently asked question in the UK newsgroup. It relates to the display of the downloaded date in the top right corner of the account register.

In UK Versions, this is frequently not the downloaded date, but the date the statement is 'valid' from. Occasionally our banks make mistakes with the date too, and you can see a time a few hours ahead of the current time!!

The fact that it is often misleading, causes it to be a question which is often asked.

Wednesday, February 22, 2006

Update to "Attention Required Message on ActiveSync" article (83)

"You receive the "Attention Required" message in the ActiveSync interface when you try to synchronize Money data files to Money for the Pocket PC on a Windows 98 Second Edition-based computer" - Microsoft have updated/edited KB Article 913094.

Microsoft Money for the Pocket PC 2004 and later are not supported on Windows 98 SE versions. The FAQ Article is updated to reflect that.

New article - OFX Analyzers

I have collected together all of the OFX analyzers for Microsoft Money onto one page (article 366). Previously, some of these were on the OFX Page and versions of the analyzer for Money 98 to Money 2001 were not present.

Microsoft Money only supported OFX from Money 98, so all the analyzers ever produced are in this article.

Tuesday, February 21, 2006

Update to 'Archiving Microsoft Money Data Files' article (66)

I installed Money 1.0 today, to take a look at it, and produce some screenshots so it would be possible to see how things have changed in the various versions of Money.

I noticed it had the 'archive' function. What didn't surprise me too much, is that it was the same as the current archive functionality in Money 2006.

Because it was a first version of Microsoft Money, it had a definition of what archive is all about - possibly later versions do in their help, but this was pretty clear, and so the FAQ article has been updated to say what archive is first, before suggesting you don't use it :-)

When you archive your file, Microsoft Money backs up the complete file for archival reference, and then removes old transactions from your current file to keep it to a manageable size.

When you remove old transactions from the current file, it will be easier to work with because you work with a smaller number of transactions in your accounts. The transactions that remain are those you are currently working with, and the starting balance of each account in the Account Book is automatically updated to adjust for the deleted transactions.

Monday, February 20, 2006

MSN Money Planner

I came across the 'MSN Money Planner' today. I downloaded it, and checked it out - and I must say I was pretty disappointed.

What I expected to see was a system that I could use to provide a calendar of events - that *I* could change. That didn't appear to be the case - the dates, categories were fixed. So, in the 'your holiday' section it says on July 10th to tell me to get the best deal on currency - my holiday will be long gone by then!! I know I can download to Outlook and then edit, but I would have preferred this in the tool - it could have been a useful little program to have all the dates of financial events in it.



In addition, I would have liked to be able to select one or more categories on the left hand side.

I'm not sure why this was provided as a downloadable application - given the links directly into MSN Money, seems like it should have just been a web page.

So, I uninstalled it pretty quickly - not much value to me.

New article - Tracking a Cash ISA

New article - Tracking a Cash ISA added to site. I need to add one for tracking a Stocks and Shares ISA or PEP, if I don't already have this.

Article is really only for UK users, but as a Cash ISA is a tax free account, then it could be used for reference for any tax free savings.

In the UK, we have something called the Savings Centre, which can be used for this.

Sunday, February 19, 2006

Update to 'Customizing the Toolbar' article (345)

Addition of image to show the toolbar, and some minor text updates. I had previously shown just the menu which is used to customize the toolbar, but not the toolbar itself.

Saturday, February 18, 2006

The 60% Solution

Twenty years of complicated budget calculations have led me to this one simple conclusion: By limiting all essential spending to 60% of total income, savings will soar.

The 60% Solution article is about dividing up your money, and limiting your essential spending to 60% of your income. This is typically how I want to budget, but find Microsoft Money inflexible in terms of supporting such a solution.

Richard Jenkins explains how to divide your income into 5 categories - Committed expenses, Irregular Expenses, Long-term saving/debt, retirement and 'fun' money.

I doubt this will work for everyone, but it is a worthy idealized budget to aim at.

Friday, February 17, 2006

About the Microsoft Money Blog

This intends to be a infrequently updated Blog relating to Microsoft (MS) Money, and the Microsoft Money FAQ website at http://moneymvps.org.

When I make updates to the Microsoft Money FAQ, I might add some comments here explaining changes or just detailing why a change was made.

In addition, I may sometimes pick up on something which isn't necessarily in the product, but could be interesting. For example, explain some of the workings of the site, which is written using Visual Studio 2005, using VB.NET and a little C#, or an MSN Money or Financial article.