MIDI devices link to Cubase. The first step should always be to check that they link in the right areas. Create a blank audio track by selecting "New Track>Audio" under the "Project" heading. In the new track, select the recording input menu. In this menu select the MIDI device you are using. Linking a device in this way tells Cubase that the MIDI device is a recordable source like a normal guitar or saxophone.
Mute all tracks besides your MIDI track and the blank audio track. Enable the blank track to record by selecting the circular record icon on the track. It turns red when selected. Press the record button in the main control panel. The blank track will record the MIDI track as if it were a normal instrument being played.