[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1168
  • Last Modified:

Close Quickbooks data file programmatically for scheduled backups

Hi folks,

I have a client for whom Quickbooks is the life of his business.  They have a multi-user version, and would like to augment their weekly CD backup with a daily backup to another computer.  

I am expecting to tell everyone that they have to ensure that they've logged off and closed Quickbooks before leaving for the day, but I can almost guarantee that someone's going to leave it open at some point, and then the file will not copy.

Is there a way to script something that will close the QB data file and all connections to it, soon before the backup begins?

Thanks for your help.

Charlie T.
0
charlietou
Asked:
charlietou
  • 6
  • 6
1 Solution
 
turn123Commented:
Charlie,

We schedule the server to reboot nightly then schedule the backup to run after it comes back up here.

Turn123
0
 
charlietouAuthor Commented:
Well, turn123,  I certainly can't fault you for your response time.  :-)

That strategy should have no ill effects on the QB data file?

CT
0
 
turn123Commented:
I happened to be online :-).

If someone forgets to save it causes problems and if they don't have a similar reboot policy they will get an error in the morning.

We haven't had any major problems from the program and I think that any program to close it will encounter the same problem (having to be force closed).

The other thing you could look at is backing up the file while it's being used.  Haven't played with that yet but I think I could locate some links if your interested.
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
turn123Commented:
http://www.experts-exchange.com/Applications/Q_21160105.html are the links I was thinking of.  I've not used them myself though.
0
 
charlietouAuthor Commented:
I don't think there would be a problem with any particular transaction not being saved, but certainly I could expect the connection to the data file to remain open inadvertantly.  

Yeah, if there's a way to back it up during use, I'd be interested.  I tried to copy the data file from one place to another while it was open, and got a locking error.  

The data file resides on an XP Pro machine.  Upon reboot, would task scheduler run a backup job without the user being logged on?

CT
0
 
charlietouAuthor Commented:
I just looked at those links.  I'm familiar with Second Copy and as a matter of fact was intending on installing it here.

I guess I'll have to give it a shot to see if it works.

0
 
turn123Commented:
How are you thinking of copying?  I was thinking a batch file with something like.

cd\folderThatTheFileIsIn
copy CompanyFile.QBW //friendsComputer/C/DataFolder

which should run fine through scheduled tasks.

The link I posted above goes to a thread with a lot of links that supposedly work around the locking error.  I haven't tried any of them myself yet but might in the future.

I would be interested in your results if you do try some :-).

Turn123
0
 
turn123Commented:
Blah posting over each other.
0
 
charlietouAuthor Commented:
Well, I tried using Second Copy, but it also could not copy the open QB data file.

What I settled on, is using Steve Gibson's wizmo.exe to do the reboot via Task Scheduler, and then scheduling second copy to run its profile a little bit later.

I think that's going to do the trick.

Thanks for the advice.

CT
0
 
charlietouAuthor Commented:
HELP!!!!!

Just wanted to get your attention again.... :-)

Okay, I ran into a catch-22:

Scheduling a task, as far as I can tell, requires a user account with a password.  As I didn't want to alter the current user's situation, I set up a second account with p/w on the system, and gave these credentials to the reboot batch file.  Problem is, Second Copy only runs upon logon, and the second user account necessitates user interaction to get past the logon screen.  And the goal here is to backup after hours with no intervention required.

So back to the first question:  Is there a way to script a command, first off, to Disconnect All Open Files?  Second, can I script a command to close Quickbooks?

Thanks.

CT
0
 
turn123Commented:
Auto-logon is easy enough with XP.  Here our computers are setup with the user account having a password and auto-logon so that the user isn't aware that they have a password.

http://www.experts-exchange.com/Operating_Systems/WinXP/Q_20804330.html

If you need to close all open connections post back and I'll see if I can find anything.  But as I've never done it before I might not be able to find an answer.

Turn123
0
 
charlietouAuthor Commented:
Okay, I changed the auto-login setting, and that has solved the problem.

Thanks again.
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

  • 6
  • 6
Tackle projects and never again get stuck behind a technical roadblock.
Join Now