Here's a procedure for perl, just adapt it for C. Hope it helps.
* Open Notepad
* Type F6 to open the execute window
* write the following commands:
o npp_save <-- Saves the current document
o CD $(CURRENT_DIRECTORY) <-- Moves to the current directory
o perl.exe -c -w "$(FILE_NAME)" <-- executes the command perl.exe -c -w <filename>, example: perl.exe -c -w test.pl (-c = compile -w = warnings)
* Click on Save
* Type a name to save the script (ie Perl Compile)
* Go to Menu Plugins -> Nppexec -> advanced options -> Menu Item
* In the combobox select the script recently created and click ok -> ok
* Restart Notepad
* Go to Menu Settings -> Shortcut mappter -> Plugins -> search for the script name
* Select the shortcut to use (ie ctrl + 1), click ok
* Verify that you can now run the script created with the shortcut selected.