How can i change sounds with the expression pedal?

Im very new at this, but Im trying to change sounds or patches with my pedal, but i cant do it :c
Im using a M-Audio prokeys 88sx with cubase

What sounds?

A lot of synths can have midi cc’s (continuous controller) assigned to certain parameters.

Like cc74 is often used to control cutoff frequency, that’s something you can really hear.

You need to learn your synth and find out what parameters you want to control then you can go about mapping signals your equipment can produce with controls your synth needs.

Automation is a great way to do this, you can write it or record it real time etc.

Lot of info on SOS:

I mean, for example, change of a piano sound to a string sound using only my pedal, which is connected the controller.

OK, sorry, thought you meant real time changing of the texture of your sound as you play.

Are you talking about changing the sounds that are produced inside of your keyboard or a VSTinstrument?

Depends on what you mean by “My Pedal”.

You just need a pedal that can send midi program change messages. There are some older ones out there that you could get pretty cheap, a new one would be like a Behringer FCB1010
You can spend a lot more.

Your keyboard should respond to midi program changes, you can try it out by putting some program changes into a midi track and sending it to your keyboard.

Try recording your keyboard as you change sounds and see if it recorded the program changes. Examine what you recorded in list view.