Forums

This topic is locked

dataset ?

Posted 30 Nov 2005 02:20:56
1
has voted
30 Nov 2005 02:20:56 paul kilroy posted:
Hi Forum, I have a search/query that fills a dataset with users info. This all works fine if details are correct, if username is not found however dataset displays empty. I would like to redirect back to search page with an error message so they can try again. Really need some help adding userability here thanks Paul

<MMataSet
id="DataSet1"
runat="Server"
IsStoredProcedure="false"
ConnectionString='<%# System.Configuration.ConfigurationSettings.AppSettings["MM_CONNECTION_STRING_portal1"] %>'
DatabaseType='<%# System.Configuration.ConfigurationSettings.AppSettings["MM_CONNECTION_DATABASETYPE_portal1"] %>'
CommandText='<%# "SELECT * FROM Table1 WHERE Username = ?" %>'
FailureURL='<%# "Search.aspx" %>'
>
<Parameters>
<Parameter Name="@Username" Value='<%# ((Request.QueryString["Username"] != null) && (Request.QueryString["Username"].Length > 0)) ? Request.QueryString["Username"] : "" %>' Type="WChar" />
</Parameters>
</MMataSet>
&lt;MM<img src=../images/dmxzone/forum/icon_smile_tongue.gif border=0 align=middle>ageBind runat="server" PostBackBind="true" /&gt;

Reply to this topic