You don't need C#

Assuming you can connect to your ISeries, set up your data set and use Text for the command type. Then, enclose your query string in curly braces:

{call lib.object(parm )} Use ? for the parms and seperate mult parms by a comma.

In my case I had one parameter: {call RT_DB.RPT_HHQVO L(?)}

Works like a champ.