1

I edit a file (could be any file), in a hex editor that shows it like this:

Hex editor layout

I want to save the hex numbers and text, like it shows up in the hex editor, original view, in a text file.

2
  • Ok, this looks like Windows, so I added the Windows tag. Do you have any price requirement (tag "gratis" maybe)? I assume you don't need the colors. Commented Oct 17, 2016 at 20:02
  • Why do you think that it "looks like" a Windwos question? Statistically, it probably is, but I don't see anythoing to indicate that. In fatc, I cannot understand the question, if there is one, at all.
    – Mawg
    Commented Oct 18, 2016 at 12:08

2 Answers 2

3

I recommend HxD, since it

  • works on Windows
  • is gratis (HxD is free of charge for private and commercial use)
  • can copy selected bytes as shown in the editor

Here's how it works:

Copy as editor view

And in the clipboard you have

Offset(h) 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F

00000000  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
00000010  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
00000020  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
00000030  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
00000040  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
00000050  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
00000060  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
00000070  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
4
  • So, that's what he wanted?! Well done
    – Mawg
    Commented Nov 17, 2016 at 13:42
  • 1
    @Mawg: well, that's my understanding of what he wanted :-) The answer was never accepted, so I'm still not 100% sure. Commented Nov 17, 2016 at 13:54
  • I could not see his image before & just tried to understand his English. I am sure that you have it correct (+1). @fastestsuperman if this answer is good, please accept it as the answer. That will help other people in the future
    – Mawg
    Commented Nov 17, 2016 at 22:22
  • One kind of interesting thing is that the asker of this question already asked a hex editor question (earlier in the same day, according to the timestamp), in which they state that they use HxD. (The screenshot they gave for this question is of Hex Editor Neo.)
    – John Y
    Commented Oct 11, 2019 at 15:14
1

wxHexEditor, which is available for Windows, claims to support this. From the wiki page dedicated to this "CopyAs" feature...

Before, sharing an hex information is a really painful experience when you compare it with wxHexEditor's solution. You have to take a screenshot, cut it, find a picture host at internet, upload it, generate an url for forum or Wiki page, paste it. If you take a snapshot of wrong region of the file, do it all over!

With wxHexEditor, you can copy a part of the file for showing at Internet, Wiki or for using in C/C++, ASM souce codes or as many other formats...

All you need to do is selecting the region that you want to export and just use CopyAs function! Than wxHexEditor will copy the block to system clipboard with selected formatting.

Here we show Hex + Text output with 16 byte per line only.

74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
7A AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA   zªªªªªªªªªªªªªªª
AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA   ªªªªªªªªªªªªªªªª
AA AA AA AA AB 69 6C 65 74 65 73 74 66 69 6C 65   ªªªª«iletestfile
74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
74 65 73 74 66 69 BB BB BB BB BB BB BB BB BB BB   testfi»»»»»»»»»»
BB BB BB 74 66 69 6C 65 74                        »»»tfilet

That is referred to as "Full Text Format". It also claims to support the following format options...

  • With or without text output
  • With or without offset output
  • Byte groupings
    • No spaces between bytes
    • One space between every byte
    • One space between every four bytes
  • With or without 0x byte prefix
  • With or without , byte separator

...though it's not clear if each option can be toggled individually or only predefined formats are available.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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