none
How To?: Report w/5 subs and varying numbers of parameters RRS feed

  • Question

  • I apologize if this is not the correct forum for my question.

    I'm still a newbie to coding in .net and Visual Studio (2010).  I have a report I'm trying to rebuild in C# VS2010 from an old Access app (Windows app - not web app).  It has five sub reports on it.  It's being built in Crystal, but I don't think that should matter much.  There is a form that launches the report in which the user can select anywhere from one to seven different parameters.  I don't see how I can do this using an XSD when one time it might run with two parameters being passed and the next time five, three or whatever.  I built XSD just so I can have fields present to create the report, but how to code everything else is what I don't understand.  It seems to me I need to build dynamic SQL statement in the actual launching form based upon parameters selected (also for sub reports).  I don't know how to do this (I'm sure many on here find it elementary).  I can't seem to find examples showing how to do it either.  Can anyone post some links to examples of how to do what I need?  1) Creating SQL on the fly and launching main report, and 2) how to also do this for my sub reports?  I can build the SQL.  I just don't know how to tie it all together to run the report with that SQL.

    If this isn't clear, then it's because I'm still new and don't know best terminology yet.

    Saturday, September 11, 2010 4:13 AM