Edit Menus?

Ok guys, I had a quick question. So if I took a program, say, Notepad, would there be a way to add additional menu items to it? For instance, Notepad has the following menu setup:

File | Edit | Format | View | Help

Would there be a way to add an additional section, like so:

File | Edit | Format | View | Help | Extensions

What I am trying to do is add additional functionality to a program that is outdated and has been scrapped. The source code was never published. If there is a way to add additional menu items, would I then be able to create items under said menu option? Such as the following:

Extensions:
- Save File
- Search File
- Change Text Color

As such, how would I capture when the user clicks one of these items? How much reverse engineering am I really looking at? Also, I'm not looking to do anything malicious.
Last edited on
What if You had the menu and its` entries and could click it... Where is the code that shall be executed and in which process' virtual address space would You like to run it and how should this be able to interact with the original notepad? ;)
Last edited on
I've not really reverse engineered software, just PSP games, so I have a very basic understanding of assembly. I also don't know much about these topics, considering I've never really had reason to look into them. I think it would be an interesting topic to learn about, though. So perhaps you could point me in the right direction?

I know it would be a rather long and tedious task, but I don't mind that. I'll give an example of what I was looking to do:

Extensions:
- Change Font Size

If I click that item, it'd be like I clicked "Format" and then the "Font" option in Notepad, and the font box would pop up. Or, instead of that, if I click "Change Font Size" under the "Extensions" tab, perhaps I could generate a new window that's a child of notepad that takes user input.

I'm just looking for any relevant information, I don't know much about the topic or really anything I am trying to do in this scenario.
Last edited on
You need to use hooking. Look at SetWindowsHookEx() family functions or maybe subclassing original notepad window and injecting your DLL in notepad.exe process by using CreateRemoteThread(), WriteProcessMemory(), etc ...

It is very hard to do it.
Topic archived. No new replies allowed.