This isn't normally the way I like to test things, but can you manually replace "CurrentPat h" with a valid directory and/or run the following code to make sure the CurrentPath is what you expect it to be?
Just place that code in your button click event. It will show the absolute path that you are trying to write to.
Code:
MsgBox(ApplicationStartupPath)
Comment