18

Are the binary formats of *.lyr and *.mxd files published?

1
  • perhaps make this two part (or ask another): Are there any projects working to reverse engineer the formats? Jul 28, 2010 at 19:24

4 Answers 4

27

They're not published, and you're probably not supposed to reverse engineer them and still expect free cookies at the ESRI UC, but they're basically OLE2 Compound Document format files, like MS Word & Excel documents. With a nice tool for cracking them open (e.g. http://www.gemboxsoftware.com/CompoundFile.htm), you can get to the hacking part pretty quickly. With a keen eye and a little knowledge of the ArcObjects object model, you'll be reading interesting data in no time. I've even heard rumors of people creating LYR files from scratch using non-ESRI code.

3
  • 1
    I suppose you could be able to do this with a huge effort but still, I would consider such implementation to be very fragile for the reasons mentioned in my answer.
    – Petr Krebs
    Aug 2, 2010 at 20:05
  • @petr a reverse engineered implementation is stable in direct correlation to the vendors' needs to maintain backwards compatibility. Aug 3, 2010 at 17:53
  • Good point Matt. While custom extensions will stymie you from a truly complete implementation, usually figuring out data sources and simple rendering options is enough to do what you want to do. The format is not fast-changing for Matt's reasons. Aug 19, 2010 at 3:07
17

The answer is No.

1
  • 4
    It would have been shorter, but have to put in at least 15 characters :)
    – JasonBirch
    Jul 23, 2010 at 2:16
3

It is not and I guess by nature it cannot be, since an .mxd is essentialy composed by ArcObjects (toolbars, maps, layers, renderers, symbols etc.) serialized via standard IPersistStream mechanism.

With the open ArcObjects ecosystem, where a map can contain lots of custom components each with their own serialization, not to mention changes in serializated data between component versions, I cannot imagine how this would be possible, unfortunately.

-3

if you change the .lyr extension to .zip or .7z and you open it with 7Zip (tested with ver 9.20) you may find 3 files: - Layer - LayerLargeImage (just add .bmp to see it) - LayerSmallImage (just add .bmp to see it)

No idea on how to open the "Layer" file, but a step is done.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.