Turn on a transistor with your remote control.
This in turn, turns on a small motor which will have a small cog, turning a bigger cog which has a roller attached to it, this has the curtain string turned around it.
It goes one way to open, the other to close.
The curtain string is in a big loop, from a roller in the middle of the curtains, back through loops to the motor/roller, then back out to the middle again.
Thats for a domestic house curtain, if your after a more heavy duty theatre type then it's most likely completely different.
The whole curtain track "must" be clean & smooth flowing.
Try having a look at curtain track manufacturers online for pictures?