First of all:
Normally you don't need that cheat. The only spots in the game, when I really got problems with a lack of force energy was during that Reborn fight in Yavin_courtyard (the Yedi Training Area) and the fight with Desann.
As far as I know there is no "infinite force cheat". But you could bind an unused key to the function "give all".
Just open the console ([shift]+[^]) and type:
BIND <key> "give force"
I would bind the [alt] key, for I actually never use it in game.
It would look like this:
BIND ALT "give force" (or BIND alt "give force" ?)
Whenever you need force energy, just hit [alt] and you're at full health again.
If you bind another function to the [alt] key (in the menu or something), you have to repeat the steps above, otherwise the key binding will be saved in the jk2config.cfg.
If you don't want to spoil the game with this approach use the hit-and-wait approach. Face an enemy or attract him with the Force Mind Trick ability and kill him.
Wait till you're on full force again and face the next enemy...
Take this, Jedi! Oh, no. What am I saying!