My AmiBroker is running on Windows 10, 24/7. Every day at 7:00 AM and 2:30 PM, it runs a program called ABSaveDBQuit.js.
var oAB = WScript.CreateObject("Broker.Application");
oAB.SaveDatabase();
oAB.Quit();
This saves data and restarts AmiBroker. This approach has a problem: after about 10 days, my AFL application will exit and become blank. How can I troubleshoot this issue? I've checked the Windows event log, but there's no record of any issues.
One additional condition: This computer is newly installed with Windows 10 64-bit Enterprise Edition, using an AMD R7-9800X3D CPU and 64GB of RAM. I previously had an older PC, also running Windows 10 64-bit Enterprise Edition, with an i7-8700 CPU. The same problem has never occurred & amibroker 6.43.1 64bit , using myown data plugin , for realtime trading system
First, Quit() by default is saving database. The code quits AmiBroker forcefully, but you said it "restarts". Chances are that you are starting AmiBroker BEFORE it (or file system) finishes writing to files and those premature restart is reading incomplete files. Also if that happens on NEW computer only, it might indicate problems with SSD drives. First thing to do is to update firmware of SSD drive.
Sorry, I didn't express myself clearly:
I used Windows Task Scheduler to quit AmiBroker at 8:20 and then restarted it at 8:30. I didn't restart AmiBroker immediately.
Additional note: The SSD I used was a Crucial T700 1TB PCIe Gen5 NVMe M.2 SSD. I just checked the official website and there's no new firmware available, but there is a new NVMe SSD driver. I'll try updating that first.