Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 724665
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T06:14:55+00:00 2026-05-14T06:14:55+00:00

I have a legacy app that seems to be exporting/saving files with CArchive (legacy

  • 0

I have a legacy app that seems to be exporting/saving files with CArchive (legacy MFC application).

We’re currently refactoring the tool for the web. Is there a library I can look at in Ruby for parsing and loading these legacy files?

What possible libraries could I look into?

Problems with the file format according to XML serialization for MFC include:
Non-robustness—your program will probably crash if you read an archive produced by another version of your program. This can be avoided by complex and unwieldly version management. By using XML, this can be largely avoided.
– Heavy dependencies between your program object model and the archived data. Change the program model and it is almost impossible to read data from a previous version.
– Archived data cannot be edited, understood, and changed, except with the associated application.

Also – 4 versions of the legacy software exists, how would I be able to overcome this ObjectModel, Archived data problem for the different versions? Total backward (import) capabilities are required.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T06:14:56+00:00Added an answer on May 14, 2026 at 6:14 am

    CArchive doesn’t have a format that you can parse. It’s just a binary file. You have to know what is in it to know how to read it. A library could make it easier to read some data types (CString, CArray, etc.) but I’m not sure you’ll find anything like this.

    CArchive works like this (storing part):

    CArchive ar;
    int i = 5;
    float f = 5.42f;
    CString str("string");
    ar << i << f << str;
    

    Then all this is dumped into binary file. You would have to read binary data and somehow interpret it. This is easy in C++ because MFC knows how to serialize types, including complex types like CString and CArray. But you’ll have to do this on your own using Ruby.

    For example you might read 4 bytes (because you know that int is that big) and interpret it as integer. Next four bytes for float. And then you have to see how to load CString, it stores the length first and then data, but you’ll have to take a look at the exact format it uses. You could create utility functions for each type to make your life easier but don’t expect this to be simple.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a legacy intranet web app that was written for IE7 and contains
I have a legacy app that used to use small(er) sets of data. Currently
I have a legacy web app that I am maintaining. It started out as
I have an unconventional legacy asp.net 1.1 web app that uses the src attribute
I have a legacy PHP/MySQL app that calls mysql_connect(). Tons of existing downstream code
I have a legacy Java (not my native language) app that I'm trying to
I have a legacy MFC C++ application for Win CE 4.2 (x86 ONLY) which
I have one legacy web application based on struts2 (primarily using annotation). While debugging
I'm attempting to open some database files used by a legacy application that I
I have a web application written in ASP.NET, Framework 4.0. The web app is

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.