Also, check the Korg Kontrol Editor and make sure the correct profile is set up. The important thing is pressing the right buttons when you connect it to the USB port so it is working for Sonar. You need to do that every time you connect.
SONAR 1. While pressing and holding down the SET MARKER and REC buttons, connect the USB cable from your computer to the nanoKONTROL2.
2. Open the “MIDI device” window in SONAR, then select nanoKONTROL2 for “Input” and “Output.”
3. Open the “Controllers/Surfaces” window, then select “Mackie Control” for “Control Surface.”
4. Select nanoKONTROL2 for the MIDI In/Out ports used.