I am having a problem converting a simple ASP.NET site to a DotNetNuke site.
On my ASP.NET site I have a form with a text box, 4 drop down boxes and a submit button. When submitted it then builds a query string and opens another page. The next page accesses a database and displays the results in a gridview.
I want to do the same thing in DNN.
I have created 2 modules: one with the original form (submit button) and one for the results (gridview).
Problem:
I cannot consistently navigate to the results tab (page). It seems like I can navigate to it after the page has been loaded for more than 30 seconds but before that it just reloads the page and clears the form.
Here is my code for the button:
protected void btSubmit_Click(object sender, EventArgs e)
{
string sKey1 = "", sKey2 = "";
sKey1 = "Key1=" + ddlKey1.SelectedValue;
sKey2 = "Key2=" + ddlKey2.SelectedValue;
sItemName = "ItemName=" + tbItemName.Text;
string[] aString = new string[] { "322", sKey1, sKey2, sItemName };
HttpContext.Current.Response.Redirect(DotNetNuke.Common.Globals.NavigateURL(73, "", aString), true);
return;
}
A few notes:
* I am completely new to DNN.
* I found out after doing more research that I could have probably used one module for this but I am more interested in figuring this out then changing the module at this point.
* I removed the form tag from the original form.
* I changed default cache time to 0 on the submit module.
* I know I can make the page more dynamic but I am just trying to do a proof of concept.
* I used http://www.adefwebserver.com/DotNetNukeHELP/NavigateURL/ as a reference.
* If I use “mid=322” in my string array the correct tab (page) does not display.