Showing results for 
Search instead for 
Did you mean: 

Save contents of memory window to file

Is it possible to save the contents of the memory window to a file?



0 Kudos
Message 1 of 4

Hello Tony,


No, there is no option to save the contents of memory window. If you are interested in the value of an array you can use Array Display to save the values to a file: right-click and Output>>Ascii or Binary




0 Kudos
Message 2 of 4

Actually you can use the array display to visualize the memory contents and save from there:

  • Right-clik in memory window and "Add Memory Watch Expression"
  • In Watch window right-clik on the memory expression, "Edit Watch Expression" and set the second value in the parathesis to the amount of data you want to display
  • Right-clik>>View>Array Display or F4
  • In Array Display you can change the format (right-click>>Format) if the default is not appropriate
  • Right-click>>Output
0 Kudos
Message 3 of 4

Using the array view is a really clever suggestion, but unfortunately it didn't work for me.  First I should provide some more background to explain my issue.  I ran a test that captured a large amount of data.  The test took about 12 hours.  The amount of data was approxiamtely 500 kB.  The application crashed at the end of the test as it was trying to display some results and before it had saved the data to a file.  Since I was running in Debug mode, the application forced a break point when it hit the fatal run-time error.  So all of the test data was in memory, I just couldn't find a way to save it to a file. 


I was hoping to save the 500 kB to a CSV file which I could then load into Excel and decode into actual values.  This was particullraly enticing since I could arrange the memory window such that each row contained a single record of data (40 bytes).  If I could have saved that view with one record per row to a CSV file, then decoding the fields in the records would have been easy.


I tried your suggestion of using the array view, but I ran into 2 problems.  First, the view would only let me see 10 kB at a time, so I would have to save over 50 files.  Second, the files were formatted with one value per line which would have been very difficult to work with in Excel.


I decided instead to add a line of code to save the data file before showing the results.  I then re-ran the test (another 12 hours) and got the data before the fatal run-time error.  Once I had the data file, I was able to load it into the program and skip straight to displaying the results.  That allowed me to debug the fatal run-time error without having to wait another 12 hours for a third test to run.


Even though I managed to get the data I needed eventually, I would imagine that I'm not the only person this has happened to.  If someone has a good suggestion for how to save a large amount of data from the memory view to a file, it might be helpful to someone else.



0 Kudos
Message 4 of 4