troubleshooting Question

respond.redirect

Avatar of jaws1021
jaws1021 asked on
JavaScript.NET ProgrammingASP.NET
12 Comments1 Solution403 ViewsLast Modified:
This is correct code for what I need for different requirements, that panel 1 shows at the beginning, but now for the save button

clicked when I am on panel 2 and button2 also, after my below response .redirect, I need to be come back to panel2 and button2, this code brings button1 and panel1 which is correct for different times.
Do I need to add something to respond.redirect or ??

<input type="button" id="B1" style="background-color:lightgrey;" value="Claim" onclick='ButtonChange("B1","lightgrey","Panel1");' />
... have two more button just like that..


<script language="JavaScript">
   function ButtonChange(sender,color,id) {

    document.getElementById(findByPartOfID("Panel1", 'DIV')).style.visibility = "hidden";
    document.getElementById(findByPartOfID("Panel1", 'DIV')).style.position = "absolute";
   
   
    document.getElementById(findByPartOfID("Panel2", 'DIV')).style.visibility = "hidden";
    document.getElementById(findByPartOfID("Panel2", 'DIV')).style.position = "absolute";
   
   
    document.getElementById(findByPartOfID("Panel3", 'DIV')).style.visibility = "hidden";
    document.getElementById(findByPartOfID("Panel3", 'DIV')).style.position = "absolute";
   
   
    document.getElementById(findByPartOfID(id, 'DIV')).style.visibility = "";
    document.getElementById(findByPartOfID(id, 'DIV')).style.position = "";
   
   
    // set button color here

document.getElementById(findByPartOfID("B1", 'INPUT')).style.backgroundColor = "";
document.getElementById(findByPartOfID("B2", 'INPUT')).style.backgroundColor = "";

document.getElementById(findByPartOfID("B3", 'INPUT')).style.backgroundColor = "";
document.getElementById(sender).style.backgroundColor = color;

}

<asp:Panel ID="Panel1" style="" runat="server">
<asp:Panel ID="Panel2" style="visibility:hidden;position:absolute;" runat="server">
<asp:Panel ID="Panel3" style="visibility:hidden;position:absolute;" runat="server">


 Response.Redirect("mypage.aspx?id=" & CInt(Request.QueryString("iclaimid")) & "&Type=" & Request.QueryString("type"))
 
 
ASKER CERTIFIED SOLUTION
DropZone

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 12 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 12 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros