Friday, February 24, 2012

cookieParameter and SqlDataSource

Hi..

I-m using cookies in my application web. Now I want show a gridview using the cookies as parameters for a sqldatasource.

Ex: myCoookie("name",txt_name.Text)

How I should be to do for the sqldatasource in the option DefineParameters with the wizard?

Hi dcampo,

Are you trying to define a CookieParameter as a filter to display data?

If so, you can add a CookieParameter directly in SelectParameters of a SqlDataSource.

Here is an example:

<asp:CookieParameter CookieName="name" Name="Name" Type="String" />

HTH. If this does not answer your question, please feel free to mark the post as Not Answered and we will look into it again. Thanks!

No comments:

Post a Comment