Adding Parameters in code, how?

J

Jeff

hi

asp.net 2.0

I have a ObjectDataSource which I in my code wants to create the
SelectParameters for.
(reason as this GridView is used on multiple pages and hence sometime
parameters will differ)

ObjectDataSource ods = (ObjectDataSource)LoginView1.FindControl("odsCars");
ods.SelectParameters.Add(new Parameter());

Problem, i don't know what arguments to send into the Paramer() constructor.
I want to define parameter name, default value (or value) and datatype

any suggestions?
 
J

Jeff

Jeff said:
hi

asp.net 2.0

I have a ObjectDataSource which I in my code wants to create the
SelectParameters for.
(reason as this GridView is used on multiple pages and hence sometime
parameters will differ)

ObjectDataSource ods =
(ObjectDataSource)LoginView1.FindControl("odsCars");
ods.SelectParameters.Add(new Parameter());

Problem, i don't know what arguments to send into the Paramer()
constructor. I want to define parameter name, default value (or value) and
datatype

any suggestions?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,007
Latest member
obedient dusk

Latest Threads

Top