Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeArchived Discus...Archived Discus...Developing Under Previous Versions of .NETDeveloping Under Previous Versions of .NETASP.Net 2.0ASP.Net 2.0Viewstate Issue w/Custom ModuleViewstate Issue w/Custom Module
Previous
 
Next
New Post
7/28/2006 11:02 AM
 
I have a need to search only the User table so members can look for contact information of other users on the site. I couldn't find any information on if the core search could be modified to search only a specific table as needed.

I would like to have a Search Input on multiple pages that all post to a specific page that shows the results.

So, utilizing my uber beginner skills in .net I created a control that has a textbox and a button. I changed the postbackurl to point to a page that will show the search results. I then converted it into a DNN module, loaded it, etc., placed it on a page.

OK here's where I need help from someone who has much more of a clue..If I have the input posback to the same page I can fill a datalist control just fine- but when I have the input page post to another page - I get the dreaded:

"Failed to load viewstate. The control tree into which viewstate is being loaded must match the control tree that was used to save viewstate during the previous request. For example, when adding controls dynamically, the controls added during a post-back must match the type and position of the controls added during the initial request."

error.

Thanks for reading this far! I hope you can help.

Best.
 
New Post
7/29/2006 11:32 PM
 
Are you using cross page posting technique avaialbe to .NET 2?  What version of DotNetNuke are you developing for?

Robert Tango
www.workcontrol.com
Custom Modules: UserManager|UserDirectory|UserImport|PortalSSO
 
New Post
7/31/2006 9:01 AM
 
Yes, I'm using techniques for 2.0 and I'm using DNN 4.3.

I ended up doing a redirect on the postback. Simple solution, so I'm not sure if I'm giving something up or not!

Thanks for the reply.
 
New Post
7/31/2006 12:11 PM
 
OK, just when I thought the redirect was my answer, I think it's lacking an important piece of code.

Since this is DNN, obviously there are multiple contols on the page. I noticed that when another control (in this case the Survey control) is posted using the 'Results' button, the ISPOSTBACK on my custom module is catching it and redirecting to another page.

Here is my uber beginner code for the postback on my custom module:
-----
If IsPostBack Then
Dim lastName
lastName = frmSearchCriteria.Text
Response.Redirect("~/Members/tabid/56/Default.aspx?lastName=" + lastName)
End If
-----
Should I be checking for the control that is causing the postback, so the redirect only occurs for postback caused by this control? If so, can someone help me on the syntax?

Thank you.
 
Previous
 
Next
HomeHomeArchived Discus...Archived Discus...Developing Under Previous Versions of .NETDeveloping Under Previous Versions of .NETASP.Net 2.0ASP.Net 2.0Viewstate Issue w/Custom ModuleViewstate Issue w/Custom Module


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out