Announcement

Collapse
No announcement yet.

Saving application state?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Saving application state?

    I know (or am fairly sure, in any case) that it's perfectly feasible, but is there a simple way of saving and loading application state in Win32? I have a few apps I use regularly which require considerable configuration and tweaking, but which have absolutely no framework for saving settings. I'd like a way to configure an app completely, save its state, use it, close it, and the next time I need it, simply start it up, then load the previous state, and have it ready to use.

    I know there are live memory editors for Win32, and even those that will allow full dumps of whichever process you desire, but I don't know of any that will overwrite memory with an old dump. I do realize that I could potentially use a Win32 cheat system that has hacking capabilities to "hack" the values I want, then simply apply those each time, but the amount of configuration I have in mind would make this approach way too much of a hassle.

    Any ideas?
    I may be lazy, but I can...zzzZZZzzzZZZzzzZZZ...

  • #2
    I ran across a live memory editor when i was working in a Computer Repair and Matinence class. i dont remember the name though as this was back in 2003 and my main focus then was Apple based PowerPC computers. what i do know is that it was portable and fit on a floppy disk. other than that i dont remember much and i tossed the disk out when i no longer had a need for 3 1/2 inch disks.

    good luck
    Cant stand the 32 bit and above gaming.
    Gamers for the return of 2d sprite filled games!

    Comment


    • #3
      Yeah, like I said above, I'm aware there are live memory editors, but I haven't had any luck finding one that can save and restore the state of a process/application.
      I may be lazy, but I can...zzzZZZzzzZZZzzzZZZ...

      Comment


      • #4
        It's not an optimum solution, but you can use VirtualBox, and the lowest version of windows the software will run on, with the lowest memory usage available to it that will still let the software run correctly.

        You then use the 'Snapshot' option. Either File>Close, and use the Snapshot, or if you want multiple subsets, you can do that too. I'd go with an EeePC XP install, personally, if you can manage to get it. Experience tells me that the virtual machine itself runs ok with 80mb of ram and 5mb of video memory.

        I also find this to be a nice solution to browsing dangerous or spyware infested sites with an old version of IE, like coupon printing sites or just randomly browsing warez, porn or other dubiously oriented sites to see the latest trends in drive by download malware.

        Also, just because I'm the sort of weirdo who'd do this type of thing twice, to copy the hard drive file you've setup in virtual box, then load it as a second unique drive, do the following:
        Get a hex editor. As of now, HexEdit 3.0F(Free version) seems to be a working, junkware-free option for this task ( http://www.hexedit.com/download.htm )
        Open the copied .VDI file in the hex editor (The .VDI files can typically be found by putting this in the Run box: "C:\Documents and Settings\%USERNAME%\.VirtualBox\VDI" but if you have a custom location, go there)
        Go to the 0x188-0x1A7 portion of the file, and change any of the numbers there to something else(I generally just tap the + or - buttons, and accept on the dialog box). (Just for reference, the way the program reports this number is the sequence of addresses 0x18B, 0x18A, 0x189, 0x188, 0x18F, 0x18E, etc. until the final of the 32 numbers)
        Save and Close the file, and try to add the copy in VirtualBox. As long as you've changed 1 byte in the correct area, you should be able to load it. That makes you pretty well done.
        This reality is mine. Go hallucinate your own.

        Comment


        • #5
          I considered using a virtual machine, but I'm hoping to keep things simpler than that. I have to use several of these apps to create files, and that would mean connecting to the network from within the virtual machine, and uploading the output files to a network share or something similar.

          Thanks for the idea, though. And yeah, sandboxing is a great tool, especially for high-risk activities and malware research.
          I may be lazy, but I can...zzzZZZzzzZZZzzzZZZ...

          Comment


          • #6
            As far as I know, you can avoid installing much in the way of networking, and still have local computer access with VirtualBox.

            The "Shared Folders" can be used to simply get local computer access. Setup a dead-ish main computer folder with nothing important in it, enable write access and make it permanent. To easily gain access to it, go to the 'Entire Network' area, make a shortcut to "VirtualBox Shared Folders" on the desktop, and whenever you want access, click-through from that shortcut to the folder you want to copy to. You have to do it this way, because sometimes direct links fail the first time you try to use them upon booting, until you go through this particular path to the folder at least once. I have the network adapter disabled in the virtual machine configuration I'm testing this on, and it reads through the shared folders like nothing.

            With a little effort, you could probably create a half-way reliable connection. If you set up a persistent drive letter for the share, you can skip the copying and directly use the main hard drive this way, even from the command line.

            Hope that makes this option more viable, even if not optimal.
            This reality is mine. Go hallucinate your own.

            Comment


            • #7
              That does improve my opinion of that process. Perhaps that will be somewhat useful. Still, I'd definitely prefer a direct method of saving/loading state of the application in question alone.

              Thanks for the info, though.
              I may be lazy, but I can...zzzZZZzzzZZZzzzZZZ...

              Comment

              Working...
              X