Solved

Restore page session state on postback

Posted on 2009-07-08
45
541 Views
Last Modified: 2012-05-07
Another newbie question.... Please HELP!!! =)

I have built an online health questionnaire for our clients with about 49 questions divided into steps 1 - 8 with the steps hidden until its turn to become visible. Everything is working great, expect a problem with the asp button postback. The problem is under each step I have a asp button that continues to the next step, if a user clicks on the back button and then goes back to hit the continue button the values that he/she entered for the next step has been removed.  I have session state enabled. is there a restore page session state function?

Example:

1. user enters data on step 1
2. hits continue
3. user enters data on step 2
4. hits the back button to step 1
5. after fixing their mistake on step 1, they then click on continue to step 2
6. back at step 2, all the data entered in is gone

Most of my questions are radiobuttonlist and checkboxlist

All of these steps are on the same page, just hidden until called upon from the asp button.

By the way on page load event I have

if page.ispostback() then
'do nothing
else
step1.visible = false
step2. visible = false
etc.
etc.
0
Comment
Question by:jml12906
  • 23
  • 22
45 Comments
 
LVL 19

Expert Comment

by:daveamour
ID: 24813415
This is nothing to do with sessions
How are you hiding sections?
0
 

Author Comment

by:jml12906
ID: 24813457
Thanks for responding, I am using control.visible = true or false... Attached is my code if this helps.

Imports System.Data.SqlClient

Imports System.Data
 

Partial Class _Default
 

    Inherits System.Web.UI.Page
 
 
 

    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
 

        '' Hide fields on Page Load
 
 

        If Page.IsPostBack Then
 

        Else
 

            step2.Visible = False

            step3.Visible = False

            step4.Visible = False

            step5.Visible = False

            step6.Visible = False

            step7.Visible = False

            step8.Visible = False

            smoking1.Visible = False

            smoking2.Visible = False

            smoking3.Visible = False

            smoking4.Visible = False

            txt_lcother.Visible = False

            pregnant1.Visible = False

            pregnant2.Visible = False

            pap1.Visible = False

            pap2.Visible = False

            mammogram1.Visible = False

            mammogram2.Visible = False

            prostate1.Visible = False

            prostate2.Visible = False
 

        End If
 
 

    End Sub
 

    Protected Sub btn_Continue1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btn_Continue1.Click
 
 

        step1.Visible = False

        step2.Visible = True
 

        ' Show pregnant question if condition
 

        If dd_gender.Text = "F" Then

            pregnant1.Visible = True

            pregnant2.Visible = True

            pap1.Visible = True

            pap2.Visible = True

            mammogram1.Visible = True

            mammogram2.Visible = True
 

        End If
 

        If dd_gender.Text = "M" Then

            prostate1.Visible = True

            prostate2.Visible = True
 

        End If
 

    End Sub
 

    Protected Sub btn_continue2_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btn_continue2.Click
 

        If cbl_gh1.SelectedIndex = -1 Then
 

            ClientScript.RegisterStartupScript(Me.GetType(), "Key", "alert('Please answer: Have you ever been told by your health provider that you have or had the following?');", True)
 

            step2.Visible = True

            step3.Visible = False
 

        ElseIf cbl_gh2.SelectedIndex = -1 Then

            ClientScript.RegisterStartupScript(Me.GetType(), "Key", "alert('Please answer: Are you currently prescribed medication for any of the following?');", True)
 

            step2.Visible = True

            step3.Visible = False

           

        Else
 

            step2.Visible = False

            step3.Visible = True

        

        End If
 

    End Sub
 

    Protected Sub btn_continue3_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btn_continue3.Click
 

        If cbl_fh1.SelectedIndex = -1 Then
 

            ClientScript.RegisterStartupScript(Me.GetType(), "Key", "alert('Please answer: My immediate family (parents, brothers, sisters) has had one of the following?');", True)
 

            step3.Visible = True

            step4.Visible = False
 

        Else
 

            step3.Visible = False

            step4.Visible = True
 

        End If
 

    End Sub
 

    Protected Sub btn_continue4_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btn_continue4.Click

        step4.Visible = False

        step5.Visible = True
 

    End Sub
 

    Protected Sub btn_continue5_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btn_continue5.Click

        step5.Visible = False

        step6.Visible = True
 

    End Sub
 

    Protected Sub btn_continue6_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btn_continue6.Click

        step6.Visible = False

        step7.Visible = True
 

    End Sub

    Protected Sub btn_continue7_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btn_continue7.Click

        step7.Visible = False

        step8.Visible = True

    End Sub
 

    Protected Sub step8_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles step8.Load
 

        ' Checkbox list Events
 

        Dim item As String

        Dim lcresult1 As String
 

        If cbl_lc1.Items(0).Selected Then item = item & cbl_lc1.Items(0).Text & ","

        If cbl_lc1.Items(1).Selected Then item = item & cbl_lc1.Items(1).Text & ","

        If cbl_lc1.Items(2).Selected Then item = item & cbl_lc1.Items(2).Text & ","

        If cbl_lc1.Items(3).Selected Then item = item & cbl_lc1.Items(3).Text & ","

        If cbl_lc1.Items(4).Selected Then item = item & cbl_lc1.Items(4).Text & ","

        If cbl_lc1.Items(5).Selected Then item = item & cbl_lc1.Items(5).Text & ","

        If cbl_lc1.Items(6).Selected Then item = item & cbl_lc1.Items(6).Text & ","

        If cbl_lc1.Items(7).Selected Then item = item & cbl_lc1.Items(7).Text & ","

        If cbl_lc1.Items(8).Selected Then item = item & cbl_lc1.Items(8).Text & ","

        If cbl_lc1.Items(9).Selected Then item = item & cbl_lc1.Items(9).Text
 

        lcresult1 = item
 

        Try
 

            If cbl_lc1.Items(9).Selected Then
 

                txt_lcother.Visible = True

            ElseIf lcresult1 = "" Then

                'do nothing

            Else

                txt_lcother.Visible = False
 

            End If
 

        Catch ex As Exception

            Throw New Exception(ex.Message)
 

        End Try

    End Sub
 

    Protected Sub btn_submit_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btn_submit.Click

        ' Validate Checkboxes are selected
 

        If cbl_lc1.SelectedIndex = -1 Then
 

            ClientScript.RegisterStartupScript(Me.GetType(), "Key", "alert('Please answer: What are your major barriers to making lifestyle changes?');", True)
 

        ElseIf cbl_lc2.SelectedIndex = -1 Then
 

            ClientScript.RegisterStartupScript(Me.GetType(), "Key", "alert('Please answer: What areas would you be interested in receiving information on if available?');", True)
 

        Else
 
 

            ' Checkbox to String General Health 

            Dim qa2 As String

            Dim ghealth As String
 

            If cbl_gh1.Items(0).Selected Then qa2 = qa2 & cbl_gh1.Items(0).Text & ","

            If cbl_gh1.Items(1).Selected Then qa2 = qa2 & cbl_gh1.Items(1).Text & ","

            If cbl_gh1.Items(2).Selected Then qa2 = qa2 & cbl_gh1.Items(2).Text & ","

            If cbl_gh1.Items(3).Selected Then qa2 = qa2 & cbl_gh1.Items(3).Text & ","

            If cbl_gh1.Items(4).Selected Then qa2 = qa2 & cbl_gh1.Items(4).Text & ","

            If cbl_gh1.Items(5).Selected Then qa2 = qa2 & cbl_gh1.Items(5).Text & ","

            If cbl_gh1.Items(6).Selected Then qa2 = qa2 & cbl_gh1.Items(6).Text & ","

            If cbl_gh1.Items(7).Selected Then qa2 = qa2 & cbl_gh1.Items(7).Text & ","

            If cbl_gh1.Items(8).Selected Then qa2 = qa2 & cbl_gh1.Items(8).Text & ","

            If cbl_gh1.Items(9).Selected Then qa2 = qa2 & cbl_gh1.Items(9).Text & ","

            If cbl_gh1.Items(10).Selected Then qa2 = qa2 & cbl_gh1.Items(10).Text & ","

            If cbl_gh1.Items(11).Selected Then qa2 = qa2 & cbl_gh1.Items(11).Text & ","

            If cbl_gh1.Items(12).Selected Then qa2 = qa2 & cbl_gh1.Items(12).Text & ","

            If cbl_gh1.Items(13).Selected Then qa2 = qa2 & cbl_gh1.Items(13).Text & ","

            If cbl_gh1.Items(14).Selected Then qa2 = qa2 & cbl_gh1.Items(14).Text & ","

            If cbl_gh1.Items(15).Selected Then qa2 = qa2 & cbl_gh1.Items(15).Text & ","

            If cbl_gh1.Items(16).Selected Then qa2 = qa2 & cbl_gh1.Items(16).Text & ","

            If cbl_gh1.Items(17).Selected Then qa2 = qa2 & cbl_gh1.Items(17).Text
 

            ghealth = qa2
 

            Dim qa3 As String

            Dim ghealth2 As String
 

            If cbl_gh2.Items(0).Selected Then qa3 = qa3 & cbl_gh2.Items(0).Text & ","

            If cbl_gh2.Items(1).Selected Then qa3 = qa3 & cbl_gh2.Items(1).Text & ","

            If cbl_gh2.Items(2).Selected Then qa3 = qa3 & cbl_gh2.Items(2).Text & ","

            If cbl_gh2.Items(3).Selected Then qa3 = qa3 & cbl_gh2.Items(3).Text & ","

            If cbl_gh2.Items(4).Selected Then qa3 = qa3 & cbl_gh2.Items(4).Text & ","

            If cbl_gh2.Items(5).Selected Then qa3 = qa3 & cbl_gh2.Items(5).Text
 

            ghealth2 = qa3
 

            ' Checkbox to String Family History
 
 

            Dim qa17 As String

            Dim fhistory As String
 

            If cbl_fh1.Items(0).Selected Then qa17 = qa17 & cbl_fh1.Items(0).Text & ","

            If cbl_fh1.Items(1).Selected Then qa17 = qa17 & cbl_fh1.Items(1).Text & ","

            If cbl_fh1.Items(2).Selected Then qa17 = qa17 & cbl_fh1.Items(2).Text & ","

            If cbl_fh1.Items(3).Selected Then qa17 = qa17 & cbl_fh1.Items(3).Text & ","

            If cbl_fh1.Items(4).Selected Then qa17 = qa17 & cbl_fh1.Items(4).Text & ","

            If cbl_fh1.Items(5).Selected Then qa17 = qa17 & cbl_fh1.Items(5).Text & ","

            If cbl_fh1.Items(6).Selected Then qa17 = qa17 & cbl_fh1.Items(6).Text & ","

            If cbl_fh1.Items(7).Selected Then qa17 = qa17 & cbl_fh1.Items(7).Text & ","

            If cbl_fh1.Items(8).Selected Then qa17 = qa17 & cbl_fh1.Items(8).Text
 
 

            fhistory = qa17
 

            ' Checkbox to String Lifestyle Changes

            Dim qa48 As String

            Dim lchanges As String
 

            If cbl_lc1.Items(0).Selected Then qa48 = qa48 & cbl_lc1.Items(0).Text & ","

            If cbl_lc1.Items(1).Selected Then qa48 = qa48 & cbl_lc1.Items(1).Text & ","

            If cbl_lc1.Items(2).Selected Then qa48 = qa48 & cbl_lc1.Items(2).Text & ","

            If cbl_lc1.Items(3).Selected Then qa48 = qa48 & cbl_lc1.Items(3).Text & ","

            If cbl_lc1.Items(4).Selected Then qa48 = qa48 & cbl_lc1.Items(4).Text & ","

            If cbl_lc1.Items(5).Selected Then qa48 = qa48 & cbl_lc1.Items(5).Text & ","

            If cbl_lc1.Items(6).Selected Then qa48 = qa48 & cbl_lc1.Items(6).Text & ","

            If cbl_lc1.Items(7).Selected Then qa48 = qa48 & cbl_lc1.Items(7).Text & ","

            If cbl_lc1.Items(8).Selected Then qa48 = qa48 & cbl_lc1.Items(8).Text & ","

            If cbl_lc1.Items(9).Selected Then qa48 = qa48 & cbl_lc1.Items(9).Text
 

            lchanges = qa48
 

            Dim qa49 As String

            Dim lchanges2 As String
 

            If cbl_lc2.Items(0).Selected Then qa49 = qa49 & cbl_lc2.Items(0).Text & ","

            If cbl_lc2.Items(1).Selected Then qa49 = qa49 & cbl_lc2.Items(1).Text & ","

            If cbl_lc2.Items(2).Selected Then qa49 = qa49 & cbl_lc2.Items(2).Text & ","

            If cbl_lc2.Items(3).Selected Then qa49 = qa49 & cbl_lc2.Items(3).Text & ","

            If cbl_lc2.Items(4).Selected Then qa49 = qa49 & cbl_lc2.Items(4).Text & ","

            If cbl_lc2.Items(5).Selected Then qa49 = qa49 & cbl_lc2.Items(5).Text & ","

            If cbl_lc2.Items(6).Selected Then qa49 = qa49 & cbl_lc2.Items(6).Text & ","

            If cbl_lc2.Items(7).Selected Then qa49 = qa49 & cbl_lc2.Items(7).Text & ","

            If cbl_lc2.Items(8).Selected Then qa49 = qa49 & cbl_lc2.Items(8).Text & ","

            If cbl_lc2.Items(9).Selected Then qa49 = qa49 & cbl_lc2.Items(9).Text & ","

            If cbl_lc2.Items(10).Selected Then qa49 = qa49 & cbl_lc2.Items(10).Text & ","

            If cbl_lc2.Items(11).Selected Then qa49 = qa49 & cbl_lc2.Items(11).Text
 

            lchanges2 = qa49
 
 

            ' Start Database Insert
 

            Dim DBConnect As SqlConnection = New SqlConnection("Server string")

            Dim Cmd As New SqlCommand("usp_HQ_Insert", DBConnect)

            Cmd.Connection = DBConnect

            Cmd.CommandType = CommandType.StoredProcedure

            Cmd.CommandText = "usp_HQ_Insert"
 

            ' Parameters to Add

            Cmd.Parameters.AddWithValue("@First_Name", Trim(txt_fname.Text))

            Cmd.Parameters.AddWithValue("@Last_Name", Trim(txt_lname.Text()))

            Cmd.Parameters.AddWithValue("@Birth_Date", Trim(txt_DOB.Text()))

            Cmd.Parameters.AddWithValue("@Gender_Code", Trim(dd_gender.Text()))

            Cmd.Parameters.AddWithValue("@SSN", Trim(txt_ssn.Text()))

            Cmd.Parameters.AddWithValue("@Has_Ins", Trim(rbl_pi1.Text()))

            Cmd.Parameters.AddWithValue("@Addr_1", Trim(txt_address.Text()))

            Cmd.Parameters.AddWithValue("@City", Trim(txt_city.Text()))

            Cmd.Parameters.AddWithValue("@State", Trim(dd_state.Text()))

            Cmd.Parameters.AddWithValue("@Zip_Code", Trim(txt_zip.Text))

            Cmd.Parameters.AddWithValue("@Email", Trim(txt_email.Text()))

            Cmd.Parameters.AddWithValue("@QA1", Trim(rbl_gh1.Text()))

            Cmd.Parameters.AddWithValue("@QA2", Trim(ghealth))

            Cmd.Parameters.AddWithValue("@QA3", Trim(ghealth2))

            Cmd.Parameters.AddWithValue("@QA4", Trim(rbl_gh2.Text()))

            Cmd.Parameters.AddWithValue("@QA5", Trim(rbl_gh3.Text()))

            Cmd.Parameters.AddWithValue("@QA6", Trim(rbl_gh4.Text()))

            Cmd.Parameters.AddWithValue("@QA7", Trim(rbl_gh5.Text()))

            Cmd.Parameters.AddWithValue("@QA8", Trim(rbl_gh6.Text()))

            Cmd.Parameters.AddWithValue("@QA9", Trim(rbl_gh7.Text()))

            Cmd.Parameters.AddWithValue("@QA10", Trim(rbl_gh8.Text()))

            Cmd.Parameters.AddWithValue("@QA11", Trim(rbl_gh9.Text()))

            Cmd.Parameters.AddWithValue("@QA12", Trim(rbl_gh10.Text()))

            Cmd.Parameters.AddWithValue("@QA13", Trim(rbl_gh11.Text()))

            Cmd.Parameters.AddWithValue("@QA14", Trim(rbl_gh12.Text()))

            Cmd.Parameters.AddWithValue("@QA15", Trim(rbl_gh13.Text()))

            Cmd.Parameters.AddWithValue("@QA16", Trim(rbl_gh14.Text()))

            Cmd.Parameters.AddWithValue("@QA17", Trim(fhistory))

            Cmd.Parameters.AddWithValue("@QA18", Trim(rbl_smk1.Text()))

            Cmd.Parameters.AddWithValue("@QA19", Trim(rbl_smk2.Text()))

            Cmd.Parameters.AddWithValue("@QA20", Trim(rbl_smk3.SelectedValue()))

            Cmd.Parameters.AddWithValue("@QA21", Trim(rbl_nt1.Text()))

            Cmd.Parameters.AddWithValue("@QA22", Trim(rbl_nt2.Text()))

            Cmd.Parameters.AddWithValue("@QA23", Trim(rbl_nt3.Text()))

            Cmd.Parameters.AddWithValue("@QA24", Trim(rbl_nt4.Text()))

            Cmd.Parameters.AddWithValue("@QA25", Trim(rbl_nt5.Text()))

            Cmd.Parameters.AddWithValue("@QA26", Trim(rbl_nt6.Text()))

            Cmd.Parameters.AddWithValue("@QA27", Trim(rbl_nt7.Text()))

            Cmd.Parameters.AddWithValue("@QA28", Trim(rbl_nt8.Text()))

            Cmd.Parameters.AddWithValue("@QA29", Trim(rbl_ex1.Text()))

            Cmd.Parameters.AddWithValue("@QA30", Trim(rbl_ex2.Text()))

            Cmd.Parameters.AddWithValue("@QA31", Trim(rbl_ex3.Text()))

            Cmd.Parameters.AddWithValue("@QA32", Trim(rbl_ex4.Text()))

            Cmd.Parameters.AddWithValue("@QA33", Trim(rbl_ex5.Text()))

            Cmd.Parameters.AddWithValue("@QA34", Trim(rbl_ex6.Text()))

            Cmd.Parameters.AddWithValue("@QA35", Trim(rbl_wb1.Text()))

            Cmd.Parameters.AddWithValue("@QA36", Trim(rbl_wb2.Text()))

            Cmd.Parameters.AddWithValue("@QA37", Trim(rbl_wb3.Text()))

            Cmd.Parameters.AddWithValue("@QA38", Trim(rbl_wb4.Text()))

            Cmd.Parameters.AddWithValue("@QA39", Trim(rbl_wb5.Text()))

            Cmd.Parameters.AddWithValue("@QA40", dd_diet.SelectedValue)

            Cmd.Parameters.AddWithValue("@QA41", dd_weight.SelectedValue)

            Cmd.Parameters.AddWithValue("@QA42", dd_exercise.SelectedValue)

            Cmd.Parameters.AddWithValue("@QA43", dd_tobacco.SelectedValue)

            Cmd.Parameters.AddWithValue("@QA44", dd_stress.SelectedValue)

            Cmd.Parameters.AddWithValue("@QA45", dd_backpain.SelectedValue)

            Cmd.Parameters.AddWithValue("@QA46", dd_bloodpressure.SelectedValue)

            Cmd.Parameters.AddWithValue("@QA47", dd_cholesterol.SelectedValue)

            Cmd.Parameters.AddWithValue("@QA48", Trim(lchanges))

            Cmd.Parameters.AddWithValue("@QA49", Trim(lchanges2))

            Cmd.Parameters.AddWithValue("@Other_text", Trim(txt_lcother.Text()))
 

            Try

                DBConnect.Open()
 

                Cmd.ExecuteNonQuery()

            Catch ex As Exception

                Throw New Exception(ex.Message)

            Finally

                If DBConnect Is Nothing Then

                    ClientScript.RegisterStartupScript(Me.GetType(), "Key", "alert('Please Contact Your Administrator.');", True)
 

                Else

                    ClientScript.RegisterStartupScript(Me.GetType(), "Key", "alert('Thank you for submitting your Health Questionnaire.');", True)
 

                    DBConnect.Close()

                End If

            End Try
 

            ' Carry SSN number to Report using Session

            Session("ssn") = txt_ssn.Text
 

            ' Once SSN number has been stored in the session page will redirect to Report.
 

            Try

                Response.Redirect("~/report.aspx")

            Catch ex As Exception
 

            End Try
 

        End If
 
 
 
 

    End Sub
 

    Protected Sub rbl_smk1_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles rbl_smk1.SelectedIndexChanged

        If rbl_smk1.Text = "Never" Then

            'do nothing

        Else

            smoking1.Visible = True

            smoking2.Visible = True

            smoking3.Visible = True

            smoking4.Visible = True

        End If

    End Sub
 

   

End Class

Open in new window

0
 
LVL 19

Expert Comment

by:daveamour
ID: 24813508
step1, step2 etc - what are they - panels?
0
 

Author Comment

by:jml12906
ID: 24813547
<table id="step1" runat="server">
etc.
etc.
At the bottom of each step have a continue to step (#)  
that button then says
step(#).visible = false
step(next step #).visible = true
 
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24813569
Ok well all sounds ok.
Are you able to post the aspx part of your page?
 
0
 

Author Comment

by:jml12906
ID: 24813652
Yeah no problem with postback, here is the senerio I am running into......
user answers questions on step 1 hits the continue button
goes to step 2 answers questions, hits the continue button
goes to step 3 answers questions, and then realizes he/she has messed up on step1
so they hit the back button going back to step1.... when user fixes problem and then hits the continue button to step2, he/she answers that they have already filled out on step2 are now gone.
 
does that help?
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24813687
Yes that helps. I meant could you show me the aspx part of your page so I can recreate it here and try it out.
0
 

Author Comment

by:jml12906
ID: 24813793
Sure thing.... BTW.... I use a third party masked textbox you will see <ew something something  from eWorld.ui here is a piece up to step 3

<%@ Page Language="VB" AutoEventWireup="false" CodeFile="hq.aspx.vb" Inherits="_Default" EnableSessionState="True" %>
<%@ Register assembly="eWorld.UI, Version=2.0.6.2393, Culture=neutral, PublicKeyToken=24d65337282035f2" namespace="eWorld.UI" tagprefix="ew" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>HealthScreen Health Questionnaire</title>

</head>
<body style="font-size: 12pt; background-position: left top; background-repeat: no-repeat;">
<form id="form1" runat="server">
<span style="font-family: Verdana"><strong>
<asp:Image ID="LOGO" runat="server" ImageUrl="~/Images/hsdm_logo_sm.jpg" />&nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp;&nbsp; <span style="font-family: Arial"><span><span style="font-size: 12pt"><span style="color: #990000; font-family: Verdana;">Individual Health Questionnaire</span><span
style="color: #000000"> &nbsp;</span></span></span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #990000">&nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;</span></span></strong></span><div id="step1" runat="server">
<table id="Step1_table" runat="server" style="width: 718px; border-top-width: thin; border-left-width: thin; border-bottom-width: thin; border-right-width: thin; font-size: 9pt; font-family: Verdana;">
<tr>
<td colspan="4" style="height: 20px; text-align: right">
<strong><span style="color: #ff9966"><span style="font-family: Arial"><span style="font-size: 11pt">
<span style="color: #990000"></span><span style="color: #000000">&nbsp; </span></span>
<span style="color: #000000">&nbsp; &nbsp; &nbsp; &nbsp;</span><span style="font-size: 8pt;
color: #000000"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;</span></span> &nbsp; &nbsp;
&nbsp; Step 1 of 8</span></strong>
</td>
</tr>
<tr>
<td colspan="4" style="background-color:#1e3c7b; text-align: center; height: 20px;">
<span style="color: #ffffff; font-family: Verdana; font-size: 11pt;"><strong>
Step 1 - Personal Information</strong></span></td>
</tr>
<tr>
<td style="height: 21px; width: 128px; background-color:#ebf0f9">
<asp:Label ID="lbl_fname" runat="server" Text="First Name" Font-Bold="True"></asp:Label></td>
<td style="height: 21px; width: 107px;">
<asp:TextBox ID="txt_fname" runat="server" MaxLength="30"></asp:TextBox>
<asp:RequiredFieldValidator ID="rfv_pi1" runat="server" Display="None" ErrorMessage='Please enter "First Name"'
Controltovalidate="txt_fname"></asp:RequiredFieldValidator></td>
<td style="height: 21px; width: 139px; background-color:#ebf0f9">
<asp:Label ID="lbl_lname" runat="server" Text="Last Name" Font-Bold="True"></asp:Label></td>
<td style="width: 104px; height: 21px">
<asp:TextBox ID="txt_lname" runat="server" MaxLength="30"></asp:TextBox>
<asp:RequiredFieldValidator ID="rfv_pi2" runat="server" Display="None" ErrorMessage='Please enter "Last Name"'
Controltovalidate="txt_lname"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 128px; height: 21px; background-color:#ebf0f9">
<asp:Label ID="lbl_dob" runat="server" Text="Date of Birth" Font-Bold="True"></asp:Label><br />
<asp:Label ID="Label1" runat="server" ForeColor="Maroon" Text="mm/dd/yyyy"></asp:Label></td>
<td style="width: 107px; height: 21px">
<ew:MaskedTextBox ID="txt_DOB" runat="server" Mask="99/99/9999">
</ew:MaskedTextBox>
<asp:RequiredFieldValidator ID="rfv_pi3" runat="server" Display="None" ErrorMessage='Please enter "Date of Birth"'
Controltovalidate="txt_dob"></asp:RequiredFieldValidator>
<asp:RangeValidator ID="RangeValidator1" runat="server" ControlToValidate="txt_DOB"
MinimumValue="01/01/1900"
MaximumValue="12/31/2050"
Type="Date" ErrorMessage= "Date of Birth must be between 01/01/1900 and 12/31/2008" Display="None">
</asp:RangeValidator></td>
<td style="width: 139px; height: 21px; background-color:#ebf0f9">
<asp:Label ID="lbl_Gender" runat="server" Text="Gender" Font-Bold="True"></asp:Label></td>
<td style="width: 104px; height: 21px">
<asp:DropDownList ID="dd_gender" runat="server">
<asp:ListItem></asp:ListItem>
<asp:ListItem>M</asp:ListItem>
<asp:ListItem>F</asp:ListItem>
</asp:DropDownList>
<asp:RequiredFieldValidator ID="rfv_pi4" runat="server" Display="None" ErrorMessage='Please select "Gender"'
Controltovalidate="dd_gender"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 128px; height: 21px; background-color:#ebf0f9">
<asp:Label ID="lbl_SSN" runat="server" Text="Social Security #" Font-Bold="True"></asp:Label></td>
<td style="width: 107px; height: 21px">
<ew:MaskedTextBox ID="txt_ssn" runat="server" Mask="999-99-9999">
</ew:MaskedTextBox>
<asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ControlToValidate="txt_ssn"
Display="None" ErrorMessage='Please enter valid "Social security #"' ValidationExpression="^((?!000)(?!666)(?!772-799)(?!800-899)(?!900-999)([0-6]\d{2}|[0-7]{2}[0-2]))-((?!00)\d{2})-((?!0000)\d{4})$"></asp:RegularExpressionValidator>
<asp:RequiredFieldValidator ID="rfv_pi5" runat="server" Display="None" ErrorMessage='Please enter "Social Security #"'
Controltovalidate="txt_ssn"></asp:RequiredFieldValidator></td>
<td style="width: 139px; height: 21px; background-color:#ebf0f9">
<asp:Label ID="lbl_cinsured" runat="server" Text="Currently Insured" Font-Bold="True"></asp:Label></td>
<td style="width: 104px; height: 21px">
<asp:RadioButtonList ID="rbl_pi1" runat="server" RepeatDirection="Horizontal">
<asp:ListItem>Yes</asp:ListItem>
<asp:ListItem>No</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="rfv_pi6" runat="server" Display="None" ErrorMessage='Please select "Currently Insured" Status'
Controltovalidate="rbl_pi1"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 128px; background-color:#ebf0f9">
<asp:Label ID="lbl_address" runat="server" Text="Address" Font-Bold="True"></asp:Label></td>
<td colspan="3">
<asp:TextBox ID="txt_address" runat="server" Width="405px" MaxLength="255"></asp:TextBox>&nbsp;
<asp:RequiredFieldValidator ID="rfv_pi7" runat="server" Display="None" ErrorMessage='Please enter "Mailing Address"'
Controltovalidate="txt_address"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 128px; background-color:#ebf0f9">
<asp:Label ID="lbl_City" runat="server" Text="City" Font-Bold="True"></asp:Label></td>
<td style="width: 107px">
<asp:TextBox ID="txt_city" runat="server" MaxLength="50"></asp:TextBox>
<asp:RequiredFieldValidator ID="rfv_pi8" runat="server" Display="None" ErrorMessage='Please enter "City"'
Controltovalidate="txt_city"></asp:RequiredFieldValidator></td>
<td style="width: 139px; background-color:#ebf0f9">
<asp:Label ID="lbl_state" runat="server" Text="State" Font-Bold="True"></asp:Label></td>
<td style="width: 104px">
<asp:DropDownList ID="dd_state" runat="server" DataSourceID="States" DataTextField="name" DataValueField="name">
</asp:DropDownList>
<asp:RequiredFieldValidator ID="rfv_pi9" runat="server" Display="None" ErrorMessage='Please select "State"'
Controltovalidate="dd_state"></asp:RequiredFieldValidator>
<asp:XmlDataSource ID="States" runat="server" DataFile="~/LIST OF STATES.xml">
</asp:XmlDataSource>
</td>
</tr>
<tr>
<td style="width: 128px; background-color:#ebf0f9">
<asp:Label ID="lbl_email" runat="server" Text="E-Mail" Font-Bold="True"></asp:Label></td>
<td style="width: 107px">
<asp:TextBox ID="txt_email" runat="server" MaxLength="100"></asp:TextBox>
<asp:RegularExpressionValidator ID="RegularExpressionValidator2" runat="server" ControlToValidate="txt_email"
Display="None" ErrorMessage='Please enter valid "E-Mail Address"' ValidationExpression="\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"></asp:RegularExpressionValidator>
</td>
<td style="width: 139px; background-color:#ebf0f9">
<asp:Label ID="lbl_zip" runat="server" Text="Zip Code" Font-Bold="True"></asp:Label></td>
<td style="width: 104px">
<asp:TextBox ID="txt_zip" runat="server" MaxLength="10"></asp:TextBox>
<asp:RegularExpressionValidator ID="RegularExpressionValidator3" runat="server" ControlToValidate="txt_zip"
Display="None" ErrorMessage='Please enter valid "Zip Code"' ValidationExpression="\d{5}(-\d{4})?"></asp:RegularExpressionValidator>
<asp:RequiredFieldValidator ID="rfv_pi10" runat="server" Display="None" ErrorMessage='Please enter "Zip Code"'
Controltovalidate="txt_zip"></asp:RequiredFieldValidator></td>
</tr>
</table>
<br />
<asp:Button ID="btn_Continue1" runat="server" Text="Continue to Step 2" OnClientClick="DisplayRecords()" />
<asp:ValidationSummary ID="vs_pi" runat="server" ShowMessageBox="True" ShowSummary="False" />
&nbsp;<br />
&nbsp;</div>
<div id="step2" runat="server">
<table id="step2_table" runat="server" style="font-size: 9pt; font-family: Verdana; width: 719px;">
<tr>
<td colspan="1" style="width: 641px; height: 20px; text-align: right">
<strong><span style="color: #ff9966">&nbsp;Step 2 of 8</span></strong></td>
</tr>
<tr>
<td colspan="1" style="width: 641px;background-color:#1e3c7b; text-align: center; height: 20px;">
<span style="color: #ffffff; font-family: Verdana; font-size: 11pt;"><strong>
Step 2 - General Health</strong></span></td>
</tr>
<tr>

<td id="pregnant1" runat="server" style="width: 641px; height: 21px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh1" runat="server" Text="Are you pregnant (female only)?" Font-Bold="True"></asp:Label></td>
</tr>
<tr>
<td id="pregnant2" runat="server" style="width: 641px">
<asp:RadioButtonList ID="rbl_gh1" runat="server" RepeatDirection="Horizontal">
<asp:ListItem>Yes</asp:ListItem>
<asp:ListItem>No</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="rfv_gh1" runat="server" ControlToValidate="rbl_gh1"
Display="None" ErrorMessage='Please answer "Are you pregnant?"'></asp:RequiredFieldValidator></td>
</tr>

<tr>
<td style="width: 641px; height: 21px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh2" runat="server" Text="Have you ever been told by your health provider that you have or had the following? Check all that apply:" Font-Bold="True" Width="638px"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px; height: 100px;">
<asp:CheckBoxList ID="cbl_gh1" runat="server" RepeatColumns="4" RepeatDirection="Horizontal" Width="639px">
<asp:ListItem>None</asp:ListItem>
<asp:ListItem>Cancer</asp:ListItem>
<asp:ListItem>Stroke</asp:ListItem>
<asp:ListItem>COPD</asp:ListItem>
<asp:ListItem>Type 1 Diabetes</asp:ListItem>
<asp:ListItem>Type 2 Diabetes</asp:ListItem>
<asp:ListItem>High Blood Pressure</asp:ListItem>
<asp:ListItem>Chronic Back Pain</asp:ListItem>
<asp:ListItem>Heart Attack</asp:ListItem>
<asp:ListItem>High Cholesterol</asp:ListItem>
<asp:ListItem>Heart Disease</asp:ListItem>
<asp:ListItem>Anxiety</asp:ListItem>
<asp:ListItem>Stress</asp:ListItem>
<asp:ListItem>GERD</asp:ListItem>
<asp:ListItem>Depression</asp:ListItem>
<asp:ListItem>Asthma</asp:ListItem>
<asp:ListItem>Chronic Lung Conditions</asp:ListItem>
<asp:ListItem>Chronic Musculoskeletal</asp:ListItem>
</asp:CheckBoxList></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh3" runat="server" Text="Are you currently prescribed medication for any of the following? Check all that apply:" Font-Bold="True"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px">
<asp:CheckBoxList ID="cbl_gh2" runat="server" RepeatDirection="Horizontal"
Width="611px">
<asp:ListItem>Diabetes</asp:ListItem>
<asp:ListItem>Asthma</asp:ListItem>
<asp:ListItem>High Blood Pressure</asp:ListItem>
<asp:ListItem>High Cholesterol</asp:ListItem>
<asp:ListItem>GERD</asp:ListItem>
<asp:ListItem>None</asp:ListItem>
</asp:CheckBoxList></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh4" runat="server" Font-Bold="True" Text="When was the last time you had a complete physical? In the last:"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px; height: 21px;">
<asp:RadioButtonList ID="rbl_gh2" runat="server" RepeatDirection="Horizontal"
Width="518px">
<asp:ListItem>1 year</asp:ListItem>
<asp:ListItem>2 years</asp:ListItem>
<asp:ListItem>3 years</asp:ListItem>
<asp:ListItem>4 years</asp:ListItem>
<asp:ListItem>5 or more years</asp:ListItem>
<asp:ListItem>Never</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="rbl_gh2"
Display="None" ErrorMessage='Please answer "When was the last time you had a complete physical?"'
SetFocusOnError="True"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9; height: 18px;">
<asp:Label ID="lbl_gh5" runat="server" Font-Bold="True" Text="When was the last time you had a flu vaccine?"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px; height: 21px;">
<asp:RadioButtonList ID="rbl_gh3" runat="server" RepeatDirection="Horizontal"
Width="520px">
<asp:ListItem>1 year</asp:ListItem>
<asp:ListItem>2 years</asp:ListItem>
<asp:ListItem>3 years</asp:ListItem>
<asp:ListItem>4 years</asp:ListItem>
<asp:ListItem>5 or more years</asp:ListItem>
<asp:ListItem>Never</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" ControlToValidate="rbl_gh3"
Display="None" ErrorMessage='Please answer "When was the last time you had a flu vaccine?"'
SetFocusOnError="True"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh6" runat="server" Font-Bold="True" Text="When was the last time you had a dental exam?"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px; height: 21px;">
<asp:RadioButtonList ID="rbl_gh4" runat="server" RepeatDirection="Horizontal"
Width="521px">
<asp:ListItem>1 year</asp:ListItem>
<asp:ListItem>2 years</asp:ListItem>
<asp:ListItem>3 years</asp:ListItem>
<asp:ListItem>4 years</asp:ListItem>
<asp:ListItem>5 or more years</asp:ListItem>
<asp:ListItem>Never</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="rbl_gh4"
Display="None" ErrorMessage='Please answer "When was the last time you had a dental exam?"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh7" runat="server" Font-Bold="True" Text="When was the last time you had a vision exam?"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px; height: 21px;">
<asp:RadioButtonList ID="rbl_gh5" runat="server" RepeatDirection="Horizontal"
Width="521px">
<asp:ListItem>1 year</asp:ListItem>
<asp:ListItem>2 years</asp:ListItem>
<asp:ListItem>3 years</asp:ListItem>
<asp:ListItem>4 years</asp:ListItem>
<asp:ListItem>5 or more years</asp:ListItem>
<asp:ListItem>Never</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="rbl_gh5"
Display="None" ErrorMessage='Please answer "When was the last time you had a vision exam?"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td id="pap1" runat="server" style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh8" runat="server" Font-Bold="True" Text="When was the last time you had a pap test (female only)?"></asp:Label></td>
</tr>
<tr>
<td id="pap2" runat="server" style="width: 641px; height: 21px;">
<asp:RadioButtonList ID="rbl_gh6" runat="server" RepeatDirection="Horizontal"
Width="518px">
<asp:ListItem>1 year</asp:ListItem>
<asp:ListItem>2 years</asp:ListItem>
<asp:ListItem>3 years</asp:ListItem>
<asp:ListItem>4 years</asp:ListItem>
<asp:ListItem>5 or more years</asp:ListItem>
<asp:ListItem>Never</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" ControlToValidate="rbl_gh6"
Display="None" ErrorMessage='Please answer "When was the last time you had a pap test?"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td id="mammogram1" runat="server" style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh9" runat="server" Font-Bold="True" Text="When was the last time you had a mammogram (female only)?"></asp:Label></td>
</tr>
<tr>
<td id="mammogram2" runat="server" style="width: 641px; height: 21px;">
<asp:RadioButtonList ID="rbl_gh7" runat="server" RepeatDirection="Horizontal"
Width="513px">
<asp:ListItem>1 year</asp:ListItem>
<asp:ListItem>2 years</asp:ListItem>
<asp:ListItem>3 years</asp:ListItem>
<asp:ListItem>4 years</asp:ListItem>
<asp:ListItem>5 or more years</asp:ListItem>
<asp:ListItem>Never</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator6" runat="server" ControlToValidate="rbl_gh7"
Display="None" ErrorMessage='Please answer "When was the last time you had a mammogram?"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td id="prostate1" runat="server" style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh10" runat="server" Font-Bold="True" Text="When was the last time you had a prostate test (male only)?"></asp:Label></td>
</tr>
<tr>
<td id="prostate2" runat="server" style="width: 641px; height: 21px;">
<asp:RadioButtonList ID="rbl_gh8" runat="server" RepeatDirection="Horizontal"
Width="514px">
<asp:ListItem>1 year</asp:ListItem>
<asp:ListItem>2 years</asp:ListItem>
<asp:ListItem>3 years</asp:ListItem>
<asp:ListItem>4 years</asp:ListItem>
<asp:ListItem>5 or more years</asp:ListItem>
<asp:ListItem>Never</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator7" runat="server" ControlToValidate="rbl_gh8"
Display="None" ErrorMessage='Please answer "When was the last time you had a prostate test?"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh11" runat="server" Font-Bold="True" Text="When was the last time you had a colonoscopy?"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px; height: 21px;">
<asp:RadioButtonList ID="rbl_gh9" runat="server" RepeatDirection="Horizontal"
Width="515px">
<asp:ListItem>1 year</asp:ListItem>
<asp:ListItem>2 years</asp:ListItem>
<asp:ListItem>3 years</asp:ListItem>
<asp:ListItem>4 years</asp:ListItem>
<asp:ListItem>5 or more years</asp:ListItem>
<asp:ListItem>Never</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator8" runat="server" ControlToValidate="rbl_gh9"
Display="None" ErrorMessage='Please answer "When was the last time you had a colonoscopy?"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9; height: 18px;">
<asp:Label ID="lbl_gh12" runat="server" Font-Bold="True" Text="I would rate my current health status as:"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px">
<asp:RadioButtonList ID="rbl_gh10" runat="server" RepeatDirection="Horizontal"
Width="515px">
<asp:ListItem>Excellent</asp:ListItem>
<asp:ListItem>Good</asp:ListItem>
<asp:ListItem>Average</asp:ListItem>
<asp:ListItem>Poor</asp:ListItem>
<asp:ListItem>Extremely Poor</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator9" runat="server" ControlToValidate="rbl_gh10"
Display="None" ErrorMessage='Please answer "I would rate my current health status as:"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh13" runat="server" Font-Bold="True" Text="The number of prescription medications that I currently take:"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px">
<asp:RadioButtonList ID="rbl_gh11" runat="server" RepeatDirection="Horizontal"
Width="434px">
<asp:ListItem>None</asp:ListItem>
<asp:ListItem>1 - 2</asp:ListItem>
<asp:ListItem>3 - 5</asp:ListItem>
<asp:ListItem>More than 5</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator10" runat="server" ControlToValidate="rbl_gh11"
Display="None" ErrorMessage='Please answer "The number of prescription medications that I currently take:"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh14" runat="server" Text="The number of ER or Urgent Care visits in the last year:" Font-Bold="True"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px">
<asp:RadioButtonList ID="rbl_gh12" runat="server" RepeatDirection="Horizontal"
Width="430px">
<asp:ListItem>None</asp:ListItem>
<asp:ListItem>1</asp:ListItem>
<asp:ListItem>2</asp:ListItem>
<asp:ListItem>3</asp:ListItem>
<asp:ListItem>4 or more</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator11" runat="server" ControlToValidate="rbl_gh12"
Display="None" ErrorMessage='Please answer "The number of ER or Urgent Care visits in the last year:"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh15" runat="server" Text="The number of hospitalizations in the last year:" Font-Bold="True"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px; height: 42px;">
<asp:RadioButtonList ID="rbl_gh13" runat="server" RepeatDirection="Horizontal"
Width="427px">
<asp:ListItem>None</asp:ListItem>
<asp:ListItem>1</asp:ListItem>
<asp:ListItem>2</asp:ListItem>
<asp:ListItem>3</asp:ListItem>
<asp:ListItem>4 or more</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator12" runat="server" ControlToValidate="rbl_gh13"
Display="None" ErrorMessage='Please answer "The number of hospitalizations in the last year:"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9; height: 16px;">
<asp:Label ID="lbl_gh16" runat="server" Font-Bold="True" Text="How many days did you miss work (or unable to perform daily activities) in the past 12 months due to sickness or injury:"
Width="600px"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px; height: 23px;">
<asp:RadioButtonList ID="rbl_gh14" runat="server" RepeatDirection="Horizontal"
Width="428px">
<asp:ListItem>None</asp:ListItem>
<asp:ListItem>1 - 4</asp:ListItem>
<asp:ListItem>5 - 9</asp:ListItem>
<asp:ListItem>10 - 14</asp:ListItem>
<asp:ListItem>15 - 19</asp:ListItem>
<asp:ListItem>20 or more</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator13" runat="server" ControlToValidate="rbl_gh14"
Display="None" ErrorMessage='Please answer "How many days did you miss work ( or unable to perform daily activities) in the past 12 months due to sickness or injury:"'></asp:RequiredFieldValidator></td>
</tr>
</table>
<br />
<input type=button value="Previous Step" onClick="history.go(-1)">&nbsp;
<asp:Button ID="btn_continue2" runat="server" Text="Continue to Step 3" OnClientClick="DisplayRecords()" />
<asp:ValidationSummary ID="vs_gh1" runat="server" ShowMessageBox="True" ShowSummary="False" />
&nbsp; &nbsp;
<br />
<br />
</div>
<div id="step3" runat="server">
<table id="step3_table" runat="server" style="font-size: 9pt; font-family: Verdana; width: 724px;">
<tr>
<td style="width: 671px; text-align: right">
<strong><span style="color: #ff9966">&nbsp;Step 3 of 8</span></strong></td>
</tr>
<tr>
<td style="width: 671px; background-color:#1e3c7b; text-align: center;">
<span style="color: #ffffff; font-family: Verdana; font-size: 11pt;"><strong>
Step 3 - Family History</strong></span></td>
</tr>
<tr>
<td style="width: 671px; background-color:#ebf0f9">
<asp:Label ID="lbl_fh1" runat="server" Font-Bold="True" Text="My immediate family (parents, brothers, sisters) has had one of the following. Check those that apply:" Width="641px"></asp:Label></td>
</tr>
<tr>
<td style="width: 671px">
<asp:CheckBoxList ID="cbl_fh1" runat="server" RepeatColumns="5" RepeatDirection="Horizontal"
Width="638px">
<asp:ListItem>None</asp:ListItem>
<asp:ListItem>Cancer</asp:ListItem>
<asp:ListItem>Diabetes</asp:ListItem>
<asp:ListItem>Heart Attack</asp:ListItem>
<asp:ListItem>Heart Disease</asp:ListItem>
<asp:ListItem>Stroke</asp:ListItem>
<asp:ListItem>High Blood Pressure</asp:ListItem>
<asp:ListItem>High Cholesterol</asp:ListItem>
<asp:ListItem>Mental Health Problems</asp:ListItem>
</asp:CheckBoxList></td>
</tr>
</table>
<br />
<input type=button value="Previous Step" onClick="history.go(-1)">&nbsp;
<asp:Button ID="btn_continue3" runat="server" Text="Continue to Step 4" />&nbsp;
<br />
</div>
</form>

</body>
</html>
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24813826
Ok well I won't be able to run this without that component.
Can you make a copy of your page with say just 3 steps and no 3rd party controls.
If that still gives you the same problem then I will be able to recreate it and debug it here.
 
0
 

Author Comment

by:jml12906
ID: 24813892
Appreciate the Help.... here is one without the 3rd party component
 

<%@ Page Language="VB" AutoEventWireup="false" CodeFile="hq.aspx.vb" Inherits="_Default" EnableSessionState="True" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
<title>HealthScreen Health Questionnaire</title>

</head>
<body style="font-size: 12pt; background-position: left top; background-repeat: no-repeat;">
<form id="form1" runat="server">
<span style="font-family: Verdana"><strong>
<asp:Image ID="LOGO" runat="server" ImageUrl="~/Images/hsdm_logo_sm.jpg" />&nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp;&nbsp; <span style="font-family: Arial"><span><span style="font-size: 12pt"><span style="color: #990000; font-family: Verdana;">Individual Health Questionnaire</span><span
style="color: #000000"> &nbsp;</span></span></span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #990000">&nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;</span></span></strong></span><div id="step1" runat="server">
<table id="Step1_table" runat="server" style="width: 718px; border-top-width: thin; border-left-width: thin; border-bottom-width: thin; border-right-width: thin; font-size: 9pt; font-family: Verdana;">
<tr>
<td colspan="4" style="height: 20px; text-align: right">
<strong><span style="color: #ff9966"><span style="font-family: Arial"><span style="font-size: 11pt">
<span style="color: #990000"></span><span style="color: #000000">&nbsp; </span></span>
<span style="color: #000000">&nbsp; &nbsp; &nbsp; &nbsp;</span><span style="font-size: 8pt;
color: #000000"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;</span></span> &nbsp; &nbsp;
&nbsp; Step 1 of 8</span></strong>
</td>
</tr>
<tr>
<td colspan="4" style="background-color:#1e3c7b; text-align: center; height: 20px;">
<span style="color: #ffffff; font-family: Verdana; font-size: 11pt;"><strong>
Step 1 - Personal Information</strong></span></td>
</tr>
<tr>
<td style="height: 21px; width: 128px; background-color:#ebf0f9">
<asp:Label ID="lbl_fname" runat="server" Text="First Name" Font-Bold="True"></asp:Label></td>
<td style="height: 21px; width: 107px;">
<asp:TextBox ID="txt_fname" runat="server" MaxLength="30"></asp:TextBox>
<asp:RequiredFieldValidator ID="rfv_pi1" runat="server" Display="None" ErrorMessage='Please enter "First Name"'
Controltovalidate="txt_fname"></asp:RequiredFieldValidator></td>
<td style="height: 21px; width: 139px; background-color:#ebf0f9">
<asp:Label ID="lbl_lname" runat="server" Text="Last Name" Font-Bold="True"></asp:Label></td>
<td style="width: 104px; height: 21px">
<asp:TextBox ID="txt_lname" runat="server" MaxLength="30"></asp:TextBox>
<asp:RequiredFieldValidator ID="rfv_pi2" runat="server" Display="None" ErrorMessage='Please enter "Last Name"'
Controltovalidate="txt_lname"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 128px; height: 21px; background-color:#ebf0f9">
<asp:Label ID="lbl_dob" runat="server" Text="Date of Birth" Font-Bold="True"></asp:Label><br />
<asp:Label ID="Label1" runat="server" ForeColor="Maroon" Text="mm/dd/yyyy"></asp:Label></td>
<td style="width: 107px; height: 21px">
<asp:TextBox ID="txt_dob" runat="server"></asp:TextBox>
<asp:RequiredFieldValidator ID="rfv_pi3" runat="server" Display="None" ErrorMessage='Please enter "Date of Birth"'
Controltovalidate="txt_dob"></asp:RequiredFieldValidator>
<asp:RangeValidator ID="RangeValidator1" runat="server" ControlToValidate="txt_DOB"
MinimumValue="01/01/1900"
MaximumValue="12/31/2050"
Type="Date" ErrorMessage= "Date of Birth must be between 01/01/1900 and 12/31/2008" Display="None">
</asp:RangeValidator></td>
<td style="width: 139px; height: 21px; background-color:#ebf0f9">
<asp:Label ID="lbl_Gender" runat="server" Text="Gender" Font-Bold="True"></asp:Label></td>
<td style="width: 104px; height: 21px">
<asp:DropDownList ID="dd_gender" runat="server">
<asp:ListItem></asp:ListItem>
<asp:ListItem>M</asp:ListItem>
<asp:ListItem>F</asp:ListItem>
</asp:DropDownList>
<asp:RequiredFieldValidator ID="rfv_pi4" runat="server" Display="None" ErrorMessage='Please select "Gender"'
Controltovalidate="dd_gender"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 128px; height: 21px; background-color:#ebf0f9">
<asp:Label ID="lbl_SSN" runat="server" Text="Social Security #" Font-Bold="True"></asp:Label></td>
<td style="width: 107px; height: 21px">
<asp:TextBox ID="txt_ssn" runat="server"></asp:TextBox>
<asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ControlToValidate="txt_ssn"
Display="None" ErrorMessage='Please enter valid "Social security #"' ValidationExpression="^((?!000)(?!666)(?!772-799)(?!800-899)(?!900-999)([0-6]\d{2}|[0-7]{2}[0-2]))-((?!00)\d{2})-((?!0000)\d{4})$"></asp:RegularExpressionValidator>
<asp:RequiredFieldValidator ID="rfv_pi5" runat="server" Display="None" ErrorMessage='Please enter "Social Security #"'
Controltovalidate="txt_ssn"></asp:RequiredFieldValidator></td>
<td style="width: 139px; height: 21px; background-color:#ebf0f9">
<asp:Label ID="lbl_cinsured" runat="server" Text="Currently Insured" Font-Bold="True"></asp:Label></td>
<td style="width: 104px; height: 21px">
<asp:RadioButtonList ID="rbl_pi1" runat="server" RepeatDirection="Horizontal">
<asp:ListItem>Yes</asp:ListItem>
<asp:ListItem>No</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="rfv_pi6" runat="server" Display="None" ErrorMessage='Please select "Currently Insured" Status'
Controltovalidate="rbl_pi1"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 128px; background-color:#ebf0f9">
<asp:Label ID="lbl_address" runat="server" Text="Address" Font-Bold="True"></asp:Label></td>
<td colspan="3">
<asp:TextBox ID="txt_address" runat="server" Width="405px" MaxLength="255"></asp:TextBox>&nbsp;
<asp:RequiredFieldValidator ID="rfv_pi7" runat="server" Display="None" ErrorMessage='Please enter "Mailing Address"'
Controltovalidate="txt_address"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 128px; background-color:#ebf0f9">
<asp:Label ID="lbl_City" runat="server" Text="City" Font-Bold="True"></asp:Label></td>
<td style="width: 107px">
<asp:TextBox ID="txt_city" runat="server" MaxLength="50"></asp:TextBox>
<asp:RequiredFieldValidator ID="rfv_pi8" runat="server" Display="None" ErrorMessage='Please enter "City"'
Controltovalidate="txt_city"></asp:RequiredFieldValidator></td>
<td style="width: 139px; background-color:#ebf0f9">
<asp:Label ID="lbl_state" runat="server" Text="State" Font-Bold="True"></asp:Label></td>
<td style="width: 104px">
<asp:DropDownList ID="dd_state" runat="server" DataSourceID="States" DataTextField="name" DataValueField="name">
<asp:ListItem>FL</asp:ListItem>
<asp:ListItem>GA</asp:ListItem>
</asp:DropDownList>
<asp:RequiredFieldValidator ID="rfv_pi9" runat="server" Display="None" ErrorMessage='Please select "State"'
Controltovalidate="dd_state"></asp:RequiredFieldValidator>&nbsp;
</td>
</tr>
<tr>
<td style="width: 128px; background-color:#ebf0f9">
<asp:Label ID="lbl_email" runat="server" Text="E-Mail" Font-Bold="True"></asp:Label></td>
<td style="width: 107px">
<asp:TextBox ID="txt_email" runat="server" MaxLength="100"></asp:TextBox>
<asp:RegularExpressionValidator ID="RegularExpressionValidator2" runat="server" ControlToValidate="txt_email"
Display="None" ErrorMessage='Please enter valid "E-Mail Address"' ValidationExpression="\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"></asp:RegularExpressionValidator>
</td>
<td style="width: 139px; background-color:#ebf0f9">
<asp:Label ID="lbl_zip" runat="server" Text="Zip Code" Font-Bold="True"></asp:Label></td>
<td style="width: 104px">
<asp:TextBox ID="txt_zip" runat="server" MaxLength="10"></asp:TextBox>
<asp:RegularExpressionValidator ID="RegularExpressionValidator3" runat="server" ControlToValidate="txt_zip"
Display="None" ErrorMessage='Please enter valid "Zip Code"' ValidationExpression="\d{5}(-\d{4})?"></asp:RegularExpressionValidator>
<asp:RequiredFieldValidator ID="rfv_pi10" runat="server" Display="None" ErrorMessage='Please enter "Zip Code"'
Controltovalidate="txt_zip"></asp:RequiredFieldValidator></td>
</tr>
</table>
<br />
<asp:Button ID="btn_Continue1" runat="server" Text="Continue to Step 2" OnClientClick="DisplayRecords()" />
<asp:ValidationSummary ID="vs_pi" runat="server" ShowMessageBox="True" ShowSummary="False" />
&nbsp;<br />
&nbsp;</div>
<div id="step2" runat="server">
<table id="step2_table" runat="server" style="font-size: 9pt; font-family: Verdana; width: 719px;">
<tr>
<td colspan="1" style="width: 641px; height: 20px; text-align: right">
<strong><span style="color: #ff9966">&nbsp;Step 2 of 8</span></strong></td>
</tr>
<tr>
<td colspan="1" style="width: 641px;background-color:#1e3c7b; text-align: center; height: 20px;">
<span style="color: #ffffff; font-family: Verdana; font-size: 11pt;"><strong>
Step 2 - General Health</strong></span></td>
</tr>
<tr>

<td id="pregnant1" runat="server" style="width: 641px; height: 21px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh1" runat="server" Text="Are you pregnant (female only)?" Font-Bold="True"></asp:Label></td>
</tr>
<tr>
<td id="pregnant2" runat="server" style="width: 641px">
<asp:RadioButtonList ID="rbl_gh1" runat="server" RepeatDirection="Horizontal">
<asp:ListItem>Yes</asp:ListItem>
<asp:ListItem>No</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="rfv_gh1" runat="server" ControlToValidate="rbl_gh1"
Display="None" ErrorMessage='Please answer "Are you pregnant?"'></asp:RequiredFieldValidator></td>
</tr>

<tr>
<td style="width: 641px; height: 21px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh2" runat="server" Text="Have you ever been told by your health provider that you have or had the following? Check all that apply:" Font-Bold="True" Width="638px"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px; height: 100px;">
<asp:CheckBoxList ID="cbl_gh1" runat="server" RepeatColumns="4" RepeatDirection="Horizontal" Width="639px">
<asp:ListItem>None</asp:ListItem>
<asp:ListItem>Cancer</asp:ListItem>
<asp:ListItem>Stroke</asp:ListItem>
<asp:ListItem>COPD</asp:ListItem>
<asp:ListItem>Type 1 Diabetes</asp:ListItem>
<asp:ListItem>Type 2 Diabetes</asp:ListItem>
<asp:ListItem>High Blood Pressure</asp:ListItem>
<asp:ListItem>Chronic Back Pain</asp:ListItem>
<asp:ListItem>Heart Attack</asp:ListItem>
<asp:ListItem>High Cholesterol</asp:ListItem>
<asp:ListItem>Heart Disease</asp:ListItem>
<asp:ListItem>Anxiety</asp:ListItem>
<asp:ListItem>Stress</asp:ListItem>
<asp:ListItem>GERD</asp:ListItem>
<asp:ListItem>Depression</asp:ListItem>
<asp:ListItem>Asthma</asp:ListItem>
<asp:ListItem>Chronic Lung Conditions</asp:ListItem>
<asp:ListItem>Chronic Musculoskeletal</asp:ListItem>
</asp:CheckBoxList></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh3" runat="server" Text="Are you currently prescribed medication for any of the following? Check all that apply:" Font-Bold="True"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px">
<asp:CheckBoxList ID="cbl_gh2" runat="server" RepeatDirection="Horizontal"
Width="611px">
<asp:ListItem>Diabetes</asp:ListItem>
<asp:ListItem>Asthma</asp:ListItem>
<asp:ListItem>High Blood Pressure</asp:ListItem>
<asp:ListItem>High Cholesterol</asp:ListItem>
<asp:ListItem>GERD</asp:ListItem>
<asp:ListItem>None</asp:ListItem>
</asp:CheckBoxList></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh4" runat="server" Font-Bold="True" Text="When was the last time you had a complete physical? In the last:"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px; height: 21px;">
<asp:RadioButtonList ID="rbl_gh2" runat="server" RepeatDirection="Horizontal"
Width="518px">
<asp:ListItem>1 year</asp:ListItem>
<asp:ListItem>2 years</asp:ListItem>
<asp:ListItem>3 years</asp:ListItem>
<asp:ListItem>4 years</asp:ListItem>
<asp:ListItem>5 or more years</asp:ListItem>
<asp:ListItem>Never</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="rbl_gh2"
Display="None" ErrorMessage='Please answer "When was the last time you had a complete physical?"'
SetFocusOnError="True"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9; height: 18px;">
<asp:Label ID="lbl_gh5" runat="server" Font-Bold="True" Text="When was the last time you had a flu vaccine?"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px; height: 21px;">
<asp:RadioButtonList ID="rbl_gh3" runat="server" RepeatDirection="Horizontal"
Width="520px">
<asp:ListItem>1 year</asp:ListItem>
<asp:ListItem>2 years</asp:ListItem>
<asp:ListItem>3 years</asp:ListItem>
<asp:ListItem>4 years</asp:ListItem>
<asp:ListItem>5 or more years</asp:ListItem>
<asp:ListItem>Never</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" ControlToValidate="rbl_gh3"
Display="None" ErrorMessage='Please answer "When was the last time you had a flu vaccine?"'
SetFocusOnError="True"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh6" runat="server" Font-Bold="True" Text="When was the last time you had a dental exam?"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px; height: 21px;">
<asp:RadioButtonList ID="rbl_gh4" runat="server" RepeatDirection="Horizontal"
Width="521px">
<asp:ListItem>1 year</asp:ListItem>
<asp:ListItem>2 years</asp:ListItem>
<asp:ListItem>3 years</asp:ListItem>
<asp:ListItem>4 years</asp:ListItem>
<asp:ListItem>5 or more years</asp:ListItem>
<asp:ListItem>Never</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="rbl_gh4"
Display="None" ErrorMessage='Please answer "When was the last time you had a dental exam?"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh7" runat="server" Font-Bold="True" Text="When was the last time you had a vision exam?"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px; height: 21px;">
<asp:RadioButtonList ID="rbl_gh5" runat="server" RepeatDirection="Horizontal"
Width="521px">
<asp:ListItem>1 year</asp:ListItem>
<asp:ListItem>2 years</asp:ListItem>
<asp:ListItem>3 years</asp:ListItem>
<asp:ListItem>4 years</asp:ListItem>
<asp:ListItem>5 or more years</asp:ListItem>
<asp:ListItem>Never</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="rbl_gh5"
Display="None" ErrorMessage='Please answer "When was the last time you had a vision exam?"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td id="pap1" runat="server" style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh8" runat="server" Font-Bold="True" Text="When was the last time you had a pap test (female only)?"></asp:Label></td>
</tr>
<tr>
<td id="pap2" runat="server" style="width: 641px; height: 21px;">
<asp:RadioButtonList ID="rbl_gh6" runat="server" RepeatDirection="Horizontal"
Width="518px">
<asp:ListItem>1 year</asp:ListItem>
<asp:ListItem>2 years</asp:ListItem>
<asp:ListItem>3 years</asp:ListItem>
<asp:ListItem>4 years</asp:ListItem>
<asp:ListItem>5 or more years</asp:ListItem>
<asp:ListItem>Never</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" ControlToValidate="rbl_gh6"
Display="None" ErrorMessage='Please answer "When was the last time you had a pap test?"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td id="mammogram1" runat="server" style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh9" runat="server" Font-Bold="True" Text="When was the last time you had a mammogram (female only)?"></asp:Label></td>
</tr>
<tr>
<td id="mammogram2" runat="server" style="width: 641px; height: 21px;">
<asp:RadioButtonList ID="rbl_gh7" runat="server" RepeatDirection="Horizontal"
Width="513px">
<asp:ListItem>1 year</asp:ListItem>
<asp:ListItem>2 years</asp:ListItem>
<asp:ListItem>3 years</asp:ListItem>
<asp:ListItem>4 years</asp:ListItem>
<asp:ListItem>5 or more years</asp:ListItem>
<asp:ListItem>Never</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator6" runat="server" ControlToValidate="rbl_gh7"
Display="None" ErrorMessage='Please answer "When was the last time you had a mammogram?"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td id="prostate1" runat="server" style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh10" runat="server" Font-Bold="True" Text="When was the last time you had a prostate test (male only)?"></asp:Label></td>
</tr>
<tr>
<td id="prostate2" runat="server" style="width: 641px; height: 21px;">
<asp:RadioButtonList ID="rbl_gh8" runat="server" RepeatDirection="Horizontal"
Width="514px">
<asp:ListItem>1 year</asp:ListItem>
<asp:ListItem>2 years</asp:ListItem>
<asp:ListItem>3 years</asp:ListItem>
<asp:ListItem>4 years</asp:ListItem>
<asp:ListItem>5 or more years</asp:ListItem>
<asp:ListItem>Never</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator7" runat="server" ControlToValidate="rbl_gh8"
Display="None" ErrorMessage='Please answer "When was the last time you had a prostate test?"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh11" runat="server" Font-Bold="True" Text="When was the last time you had a colonoscopy?"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px; height: 21px;">
<asp:RadioButtonList ID="rbl_gh9" runat="server" RepeatDirection="Horizontal"
Width="515px">
<asp:ListItem>1 year</asp:ListItem>
<asp:ListItem>2 years</asp:ListItem>
<asp:ListItem>3 years</asp:ListItem>
<asp:ListItem>4 years</asp:ListItem>
<asp:ListItem>5 or more years</asp:ListItem>
<asp:ListItem>Never</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator8" runat="server" ControlToValidate="rbl_gh9"
Display="None" ErrorMessage='Please answer "When was the last time you had a colonoscopy?"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9; height: 18px;">
<asp:Label ID="lbl_gh12" runat="server" Font-Bold="True" Text="I would rate my current health status as:"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px">
<asp:RadioButtonList ID="rbl_gh10" runat="server" RepeatDirection="Horizontal"
Width="515px">
<asp:ListItem>Excellent</asp:ListItem>
<asp:ListItem>Good</asp:ListItem>
<asp:ListItem>Average</asp:ListItem>
<asp:ListItem>Poor</asp:ListItem>
<asp:ListItem>Extremely Poor</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator9" runat="server" ControlToValidate="rbl_gh10"
Display="None" ErrorMessage='Please answer "I would rate my current health status as:"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh13" runat="server" Font-Bold="True" Text="The number of prescription medications that I currently take:"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px">
<asp:RadioButtonList ID="rbl_gh11" runat="server" RepeatDirection="Horizontal"
Width="434px">
<asp:ListItem>None</asp:ListItem>
<asp:ListItem>1 - 2</asp:ListItem>
<asp:ListItem>3 - 5</asp:ListItem>
<asp:ListItem>More than 5</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator10" runat="server" ControlToValidate="rbl_gh11"
Display="None" ErrorMessage='Please answer "The number of prescription medications that I currently take:"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh14" runat="server" Text="The number of ER or Urgent Care visits in the last year:" Font-Bold="True"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px">
<asp:RadioButtonList ID="rbl_gh12" runat="server" RepeatDirection="Horizontal"
Width="430px">
<asp:ListItem>None</asp:ListItem>
<asp:ListItem>1</asp:ListItem>
<asp:ListItem>2</asp:ListItem>
<asp:ListItem>3</asp:ListItem>
<asp:ListItem>4 or more</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator11" runat="server" ControlToValidate="rbl_gh12"
Display="None" ErrorMessage='Please answer "The number of ER or Urgent Care visits in the last year:"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9">
<asp:Label ID="lbl_gh15" runat="server" Text="The number of hospitalizations in the last year:" Font-Bold="True"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px; height: 42px;">
<asp:RadioButtonList ID="rbl_gh13" runat="server" RepeatDirection="Horizontal"
Width="427px">
<asp:ListItem>None</asp:ListItem>
<asp:ListItem>1</asp:ListItem>
<asp:ListItem>2</asp:ListItem>
<asp:ListItem>3</asp:ListItem>
<asp:ListItem>4 or more</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator12" runat="server" ControlToValidate="rbl_gh13"
Display="None" ErrorMessage='Please answer "The number of hospitalizations in the last year:"'></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 641px; background-color:#ebf0f9; height: 16px;">
<asp:Label ID="lbl_gh16" runat="server" Font-Bold="True" Text="How many days did you miss work (or unable to perform daily activities) in the past 12 months due to sickness or injury:"
Width="600px"></asp:Label></td>
</tr>
<tr>
<td style="width: 641px; height: 23px;">
<asp:RadioButtonList ID="rbl_gh14" runat="server" RepeatDirection="Horizontal"
Width="428px">
<asp:ListItem>None</asp:ListItem>
<asp:ListItem>1 - 4</asp:ListItem>
<asp:ListItem>5 - 9</asp:ListItem>
<asp:ListItem>10 - 14</asp:ListItem>
<asp:ListItem>15 - 19</asp:ListItem>
<asp:ListItem>20 or more</asp:ListItem>
</asp:RadioButtonList>
<asp:RequiredFieldValidator ID="RequiredFieldValidator13" runat="server" ControlToValidate="rbl_gh14"
Display="None" ErrorMessage='Please answer "How many days did you miss work ( or unable to perform daily activities) in the past 12 months due to sickness or injury:"'></asp:RequiredFieldValidator></td>
</tr>
</table>
<br />
<input type=button value="Previous Step" onClick="history.go(-1)">&nbsp;
<asp:Button ID="btn_continue2" runat="server" Text="Continue to Step 3" OnClientClick="DisplayRecords()" />
<asp:ValidationSummary ID="vs_gh1" runat="server" ShowMessageBox="True" ShowSummary="False" />
&nbsp; &nbsp;
<br />
<br />
</div>
<div id="step3" runat="server">
<table id="step3_table" runat="server" style="font-size: 9pt; font-family: Verdana; width: 724px;">
<tr>
<td style="width: 671px; text-align: right">
<strong><span style="color: #ff9966">&nbsp;Step 3 of 8</span></strong></td>
</tr>
<tr>
<td style="width: 671px; background-color:#1e3c7b; text-align: center;">
<span style="color: #ffffff; font-family: Verdana; font-size: 11pt;"><strong>
Step 3 - Family History</strong></span></td>
</tr>
<tr>
<td style="width: 671px; background-color:#ebf0f9">
<asp:Label ID="lbl_fh1" runat="server" Font-Bold="True" Text="My immediate family (parents, brothers, sisters) has had one of the following. Check those that apply:" Width="641px"></asp:Label></td>
</tr>
<tr>
<td style="width: 671px">
<asp:CheckBoxList ID="cbl_fh1" runat="server" RepeatColumns="5" RepeatDirection="Horizontal"
Width="638px">
<asp:ListItem>None</asp:ListItem>
<asp:ListItem>Cancer</asp:ListItem>
<asp:ListItem>Diabetes</asp:ListItem>
<asp:ListItem>Heart Attack</asp:ListItem>
<asp:ListItem>Heart Disease</asp:ListItem>
<asp:ListItem>Stroke</asp:ListItem>
<asp:ListItem>High Blood Pressure</asp:ListItem>
<asp:ListItem>High Cholesterol</asp:ListItem>
<asp:ListItem>Mental Health Problems</asp:ListItem>
</asp:CheckBoxList></td>
</tr>
</table>
<br />
<input type=button value="Previous Step" onClick="history.go(-1)">&nbsp;
<asp:Button ID="btn_continue3" runat="server" Text="Continue to Step 4" />&nbsp;
<br />
</div>
<div id="step4" runat="server">
&nbsp;</div>
<span style="color: #990000">
<br />
<br />
<br />
<span style="font-size: 9pt"></span></span>
</form>

</body>
</html>
0
 

Author Comment

by:jml12906
ID: 24813898
BTW, I had a xml form for the states, I just took that out and manually listed two states for testing purposes
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24813961
No probs, quiet at work.
Can you give me the code behind for this new, slimmed down version?
Thanks
0
 

Author Comment

by:jml12906
ID: 24814018
As requested:

Imports System.Data.SqlClient
Imports System.Data
Partial Class _Default
Inherits System.Web.UI.Page


Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
'' Hide fields on Page Load

If Page.IsPostBack Then
Else
step2.Visible = False
step3.Visible = False
pregnant1.Visible = False
pregnant2.Visible = False
pap1.Visible = False
pap2.Visible = False
mammogram1.Visible = False
mammogram2.Visible = False
prostate1.Visible = False
prostate2.Visible = False
End If

End Sub
Protected Sub btn_Continue1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btn_Continue1.Click

step1.Visible = False
step2.Visible = True
' Show pregnant question if condition
If dd_gender.Text = "F" Then
pregnant1.Visible = True
pregnant2.Visible = True
pap1.Visible = True
pap2.Visible = True
mammogram1.Visible = True
mammogram2.Visible = True
End If
If dd_gender.Text = "M" Then
prostate1.Visible = True
prostate2.Visible = True
End If
End Sub
Protected Sub btn_continue2_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btn_continue2.Click
If cbl_gh1.SelectedIndex = -1 Then
ClientScript.RegisterStartupScript(Me.GetType(), "Key", "alert('Please answer: Have you ever been told by your health provider that you have or had the following?');", True)
step2.Visible = True
step3.Visible = False
ElseIf cbl_gh2.SelectedIndex = -1 Then
ClientScript.RegisterStartupScript(Me.GetType(), "Key", "alert('Please answer: Are you currently prescribed medication for any of the following?');", True)
step2.Visible = True
step3.Visible = False

Else
step2.Visible = False
step3.Visible = True

End If
End Sub
Protected Sub btn_continue3_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btn_continue3.Click
If cbl_fh1.SelectedIndex = -1 Then
ClientScript.RegisterStartupScript(Me.GetType(), "Key", "alert('Please answer: My immediate family (parents, brothers, sisters) has had one of the following?');", True)
step3.Visible = True
step4.Visible = False
Else
step3.Visible = False
step4.Visible = True
End If
End Sub





End Class
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24814071
Whats happening with the onclick event of the submit button:

DisplayRecords();WebForm_DoPostBackWithOptions(new WebForm_PostBackOptions(&quot;btn_Continue1&quot;, &quot;&quot;, true, &quot;&quot;, &quot;&quot;, false, false))
What's that all about?
0
 

Author Comment

by:jml12906
ID: 24814137
ohh ignore it, I got rid of it....... I was playing just trying things
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24814196
Ok well I set this up and its working ok for me.
Can you test this on yours - I removed a bit of stuff including some validators to make it easier to test.
See attahced aspx and code behind.
 
 
 

<%@ Page Language="vb" AutoEventWireup="false" CodeBehind="Default.aspx.vb" Inherits="hq._Default" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 

<html xmlns="http://www.w3.org/1999/xhtml" > 

<head id="Head1" runat="server"> 

<title>HealthScreen Health Questionnaire</title> 
 

</head> 

<body style="font-size: 12pt; background-position: left top; background-repeat: no-repeat;"> 

<form id="form1" runat="server"> 

<span style="font-family: Verdana"><strong> 

<asp:Image ID="LOGO" runat="server" ImageUrl="~/Images/hsdm_logo_sm.jpg" />&nbsp; &nbsp; 

&nbsp; &nbsp; &nbsp; &nbsp;&nbsp; <span style="font-family: Arial"><span><span style="font-size: 12pt"><span style="color: #990000; font-family: Verdana;">Individual Health Questionnaire</span><span 

style="color: #000000"> &nbsp;</span></span></span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 

&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 

&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 

&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 

&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #990000">&nbsp; &nbsp; &nbsp; 

&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;</span></span></strong></span><div id="step1" runat="server"> 

<table id="Step1_table" runat="server" style="width: 718px; border-top-width: thin; border-left-width: thin; border-bottom-width: thin; border-right-width: thin; font-size: 9pt; font-family: Verdana;"> 

<tr> 

<td colspan="4" style="height: 20px; text-align: right"> 

<strong><span style="color: #ff9966"><span style="font-family: Arial"><span style="font-size: 11pt"> 

<span style="color: #990000"></span><span style="color: #000000">&nbsp; </span></span> 

<span style="color: #000000">&nbsp; &nbsp; &nbsp; &nbsp;</span><span style="font-size: 8pt; 

color: #000000"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;</span></span> &nbsp; &nbsp; 

&nbsp; Step 1 of 8</span></strong> 

</td> 

</tr> 

<tr> 

<td colspan="4" style="background-color:#1e3c7b; text-align: center; height: 20px;"> 

<span style="color: #ffffff; font-family: Verdana; font-size: 11pt;"><strong> 

Step 1 - Personal Information</strong></span></td> 

</tr> 

<tr> 

<td style="height: 21px; width: 128px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_fname" runat="server" Text="First Name" Font-Bold="True"></asp:Label></td> 

<td style="height: 21px; width: 107px;"> 

<asp:TextBox ID="txt_fname" runat="server" MaxLength="30"></asp:TextBox> 

<asp:RequiredFieldValidator ID="rfv_pi1" runat="server" Display="None" ErrorMessage='Please enter "First Name"' 

Controltovalidate="txt_fname"></asp:RequiredFieldValidator></td> 

<td style="height: 21px; width: 139px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_lname" runat="server" Text="Last Name" Font-Bold="True"></asp:Label></td> 

<td style="width: 104px; height: 21px"> 

<asp:TextBox ID="txt_lname" runat="server" MaxLength="30"></asp:TextBox> 

<asp:RequiredFieldValidator ID="rfv_pi2" runat="server" Display="None" ErrorMessage='Please enter "Last Name"' 

Controltovalidate="txt_lname"></asp:RequiredFieldValidator></td> 

</tr> 

<tr> 

<td style="width: 128px; height: 21px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_dob" runat="server" Text="Date of Birth" Font-Bold="True"></asp:Label><br /> 

<asp:Label ID="Label1" runat="server" ForeColor="Maroon" Text="mm/dd/yyyy"></asp:Label></td> 

<td style="width: 107px; height: 21px"> 

<asp:TextBox ID="txt_dob" runat="server"></asp:TextBox> 

<asp:RequiredFieldValidator ID="rfv_pi3" runat="server" Display="None" ErrorMessage='Please enter "Date of Birth"' 

Controltovalidate="txt_dob"></asp:RequiredFieldValidator> 

</td> 

<td style="width: 139px; height: 21px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_Gender" runat="server" Text="Gender" Font-Bold="True"></asp:Label></td> 

<td style="width: 104px; height: 21px"> 

<asp:DropDownList ID="dd_gender" runat="server"> 

<asp:ListItem></asp:ListItem> 

<asp:ListItem>M</asp:ListItem> 

<asp:ListItem>F</asp:ListItem> 

</asp:DropDownList> 

<asp:RequiredFieldValidator ID="rfv_pi4" runat="server" Display="None" ErrorMessage='Please select "Gender"' 

Controltovalidate="dd_gender"></asp:RequiredFieldValidator></td> 

</tr> 

<tr> 

<td style="width: 128px; height: 21px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_SSN" runat="server" Text="Social Security #" Font-Bold="True"></asp:Label></td> 

<td style="width: 107px; height: 21px"> 

<asp:TextBox ID="txt_ssn" runat="server"></asp:TextBox> 

<asp:RequiredFieldValidator ID="rfv_pi5" runat="server" Display="None" ErrorMessage='Please enter "Social Security #"' 

Controltovalidate="txt_ssn"></asp:RequiredFieldValidator></td> 

<td style="width: 139px; height: 21px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_cinsured" runat="server" Text="Currently Insured" Font-Bold="True"></asp:Label></td> 

<td style="width: 104px; height: 21px"> 

<asp:RadioButtonList ID="rbl_pi1" runat="server" RepeatDirection="Horizontal"> 

<asp:ListItem>Yes</asp:ListItem> 

<asp:ListItem>No</asp:ListItem> 

</asp:RadioButtonList> 

<asp:RequiredFieldValidator ID="rfv_pi6" runat="server" Display="None" ErrorMessage='Please select "Currently Insured" Status' 

Controltovalidate="rbl_pi1"></asp:RequiredFieldValidator></td> 

</tr> 

<tr> 

<td style="width: 128px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_address" runat="server" Text="Address" Font-Bold="True"></asp:Label></td> 

<td colspan="3"> 

<asp:TextBox ID="txt_address" runat="server" Width="405px" MaxLength="255"></asp:TextBox>&nbsp; 

<asp:RequiredFieldValidator ID="rfv_pi7" runat="server" Display="None" ErrorMessage='Please enter "Mailing Address"' 

Controltovalidate="txt_address"></asp:RequiredFieldValidator></td> 

</tr> 

<tr> 

<td style="width: 128px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_City" runat="server" Text="City" Font-Bold="True"></asp:Label></td> 

<td style="width: 107px"> 

<asp:TextBox ID="txt_city" runat="server" MaxLength="50"></asp:TextBox> 

<asp:RequiredFieldValidator ID="rfv_pi8" runat="server" Display="None" ErrorMessage='Please enter "City"' 

Controltovalidate="txt_city"></asp:RequiredFieldValidator></td> 

<td style="width: 139px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_state" runat="server" Text="State" Font-Bold="True"></asp:Label></td> 

<td style="width: 104px"> 

<asp:DropDownList ID="dd_state" runat="server"> 

<asp:ListItem>FL</asp:ListItem> 

<asp:ListItem>GA</asp:ListItem> 

</asp:DropDownList> 

<asp:RequiredFieldValidator ID="rfv_pi9" runat="server" Display="None" ErrorMessage='Please select "State"' 

Controltovalidate="dd_state"></asp:RequiredFieldValidator>&nbsp; 

</td> 

</tr> 

<tr> 

<td style="width: 128px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_email" runat="server" Text="E-Mail" Font-Bold="True"></asp:Label></td> 

<td style="width: 107px"> 

<asp:TextBox ID="txt_email" runat="server" MaxLength="100"></asp:TextBox> 

</td> 

<td style="width: 139px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_zip" runat="server" Text="Zip Code" Font-Bold="True"></asp:Label></td> 

<td style="width: 104px"> 

<asp:TextBox ID="txt_zip" runat="server" MaxLength="10"></asp:TextBox> 

<asp:RequiredFieldValidator ID="rfv_pi10" runat="server" Display="None" ErrorMessage='Please enter "Zip Code"' 

Controltovalidate="txt_zip"></asp:RequiredFieldValidator></td> 

</tr> 

</table> 

<br /> 

<asp:Button ID="btn_Continue1" runat="server" Text="Continue to Step 2" /> 

<asp:ValidationSummary ID="vs_pi" runat="server" ShowMessageBox="True" ShowSummary="False" /> 

&nbsp;<br /> 

&nbsp;</div> 

<div id="step2" runat="server"> 

<table id="step2_table" runat="server" style="font-size: 9pt; font-family: Verdana; width: 719px;"> 

<tr> 

<td colspan="1" style="width: 641px; height: 20px; text-align: right"> 

<strong><span style="color: #ff9966">&nbsp;Step 2 of 8</span></strong></td> 

</tr> 

<tr> 

<td colspan="1" style="width: 641px;background-color:#1e3c7b; text-align: center; height: 20px;"> 

<span style="color: #ffffff; font-family: Verdana; font-size: 11pt;"><strong> 

Step 2 - General Health</strong></span></td> 

</tr> 

<tr> 
 

<td id="pregnant1" runat="server" style="width: 641px; height: 21px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_gh1" runat="server" Text="Are you pregnant (female only)?" Font-Bold="True"></asp:Label></td> 

</tr> 

<tr> 

<td id="pregnant2" runat="server" style="width: 641px"> 

<asp:RadioButtonList ID="rbl_gh1" runat="server" RepeatDirection="Horizontal"> 

<asp:ListItem>Yes</asp:ListItem> 

<asp:ListItem>No</asp:ListItem> 

</asp:RadioButtonList> 

<asp:RequiredFieldValidator ID="rfv_gh1" runat="server" ControlToValidate="rbl_gh1" 

Display="None" ErrorMessage='Please answer "Are you pregnant?"'></asp:RequiredFieldValidator></td> 

</tr> 
 

<tr> 

<td style="width: 641px; height: 21px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_gh2" runat="server" Text="Have you ever been told by your health provider that you have or had the following? Check all that apply:" Font-Bold="True" Width="638px"></asp:Label></td> 

</tr> 

<tr> 

<td style="width: 641px; height: 100px;"> 

<asp:CheckBoxList ID="cbl_gh1" runat="server" RepeatColumns="4" RepeatDirection="Horizontal" Width="639px"> 

<asp:ListItem>None</asp:ListItem> 

<asp:ListItem>Cancer</asp:ListItem> 

<asp:ListItem>Stroke</asp:ListItem> 

<asp:ListItem>COPD</asp:ListItem> 

<asp:ListItem>Type 1 Diabetes</asp:ListItem> 

<asp:ListItem>Type 2 Diabetes</asp:ListItem> 

<asp:ListItem>High Blood Pressure</asp:ListItem> 

<asp:ListItem>Chronic Back Pain</asp:ListItem> 

<asp:ListItem>Heart Attack</asp:ListItem> 

<asp:ListItem>High Cholesterol</asp:ListItem> 

<asp:ListItem>Heart Disease</asp:ListItem> 

<asp:ListItem>Anxiety</asp:ListItem> 

<asp:ListItem>Stress</asp:ListItem> 

<asp:ListItem>GERD</asp:ListItem> 

<asp:ListItem>Depression</asp:ListItem> 

<asp:ListItem>Asthma</asp:ListItem> 

<asp:ListItem>Chronic Lung Conditions</asp:ListItem> 

<asp:ListItem>Chronic Musculoskeletal</asp:ListItem> 

</asp:CheckBoxList></td> 

</tr> 

<tr> 

<td style="width: 641px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_gh3" runat="server" Text="Are you currently prescribed medication for any of the following? Check all that apply:" Font-Bold="True"></asp:Label></td> 

</tr> 

<tr> 

<td style="width: 641px"> 

<asp:CheckBoxList ID="cbl_gh2" runat="server" RepeatDirection="Horizontal" 

Width="611px"> 

<asp:ListItem>Diabetes</asp:ListItem> 

<asp:ListItem>Asthma</asp:ListItem> 

<asp:ListItem>High Blood Pressure</asp:ListItem> 

<asp:ListItem>High Cholesterol</asp:ListItem> 

<asp:ListItem>GERD</asp:ListItem> 

<asp:ListItem>None</asp:ListItem> 

</asp:CheckBoxList></td> 

</tr> 

<tr> 

<td style="width: 641px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_gh4" runat="server" Font-Bold="True" Text="When was the last time you had a complete physical? In the last:"></asp:Label></td> 

</tr> 

<tr> 

<td style="width: 641px; height: 21px;"> 

<asp:RadioButtonList ID="rbl_gh2" runat="server" RepeatDirection="Horizontal" 

Width="518px"> 

<asp:ListItem>1 year</asp:ListItem> 

<asp:ListItem>2 years</asp:ListItem> 

<asp:ListItem>3 years</asp:ListItem> 

<asp:ListItem>4 years</asp:ListItem> 

<asp:ListItem>5 or more years</asp:ListItem> 

<asp:ListItem>Never</asp:ListItem> 

</asp:RadioButtonList> 

<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="rbl_gh2" 

Display="None" ErrorMessage='Please answer "When was the last time you had a complete physical?"' 

SetFocusOnError="True"></asp:RequiredFieldValidator></td> 

</tr> 

<tr> 

<td style="width: 641px; background-color:#ebf0f9; height: 18px;"> 

<asp:Label ID="lbl_gh5" runat="server" Font-Bold="True" Text="When was the last time you had a flu vaccine?"></asp:Label></td> 

</tr> 

<tr> 

<td style="width: 641px; height: 21px;"> 

<asp:RadioButtonList ID="rbl_gh3" runat="server" RepeatDirection="Horizontal" 

Width="520px"> 

<asp:ListItem>1 year</asp:ListItem> 

<asp:ListItem>2 years</asp:ListItem> 

<asp:ListItem>3 years</asp:ListItem> 

<asp:ListItem>4 years</asp:ListItem> 

<asp:ListItem>5 or more years</asp:ListItem> 

<asp:ListItem>Never</asp:ListItem> 

</asp:RadioButtonList> 

<asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" ControlToValidate="rbl_gh3" 

Display="None" ErrorMessage='Please answer "When was the last time you had a flu vaccine?"' 

SetFocusOnError="True"></asp:RequiredFieldValidator></td> 

</tr> 

<tr> 

<td style="width: 641px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_gh6" runat="server" Font-Bold="True" Text="When was the last time you had a dental exam?"></asp:Label></td> 

</tr> 

<tr> 

<td style="width: 641px; height: 21px;"> 

<asp:RadioButtonList ID="rbl_gh4" runat="server" RepeatDirection="Horizontal" 

Width="521px"> 

<asp:ListItem>1 year</asp:ListItem> 

<asp:ListItem>2 years</asp:ListItem> 

<asp:ListItem>3 years</asp:ListItem> 

<asp:ListItem>4 years</asp:ListItem> 

<asp:ListItem>5 or more years</asp:ListItem> 

<asp:ListItem>Never</asp:ListItem> 

</asp:RadioButtonList> 

<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="rbl_gh4" 

Display="None" ErrorMessage='Please answer "When was the last time you had a dental exam?"'></asp:RequiredFieldValidator></td> 

</tr> 

<tr> 

<td style="width: 641px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_gh7" runat="server" Font-Bold="True" Text="When was the last time you had a vision exam?"></asp:Label></td> 

</tr> 

<tr> 

<td style="width: 641px; height: 21px;"> 

<asp:RadioButtonList ID="rbl_gh5" runat="server" RepeatDirection="Horizontal" 

Width="521px"> 

<asp:ListItem>1 year</asp:ListItem> 

<asp:ListItem>2 years</asp:ListItem> 

<asp:ListItem>3 years</asp:ListItem> 

<asp:ListItem>4 years</asp:ListItem> 

<asp:ListItem>5 or more years</asp:ListItem> 

<asp:ListItem>Never</asp:ListItem> 

</asp:RadioButtonList> 

<asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="rbl_gh5" 

Display="None" ErrorMessage='Please answer "When was the last time you had a vision exam?"'></asp:RequiredFieldValidator></td> 

</tr> 

<tr> 

<td id="pap1" runat="server" style="width: 641px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_gh8" runat="server" Font-Bold="True" Text="When was the last time you had a pap test (female only)?"></asp:Label></td> 

</tr> 

<tr> 

<td id="pap2" runat="server" style="width: 641px; height: 21px;"> 

<asp:RadioButtonList ID="rbl_gh6" runat="server" RepeatDirection="Horizontal" 

Width="518px"> 

<asp:ListItem>1 year</asp:ListItem> 

<asp:ListItem>2 years</asp:ListItem> 

<asp:ListItem>3 years</asp:ListItem> 

<asp:ListItem>4 years</asp:ListItem> 

<asp:ListItem>5 or more years</asp:ListItem> 

<asp:ListItem>Never</asp:ListItem> 

</asp:RadioButtonList> 

<asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" ControlToValidate="rbl_gh6" 

Display="None" ErrorMessage='Please answer "When was the last time you had a pap test?"'></asp:RequiredFieldValidator></td> 

</tr> 

<tr> 

<td id="mammogram1" runat="server" style="width: 641px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_gh9" runat="server" Font-Bold="True" Text="When was the last time you had a mammogram (female only)?"></asp:Label></td> 

</tr> 

<tr> 

<td id="mammogram2" runat="server" style="width: 641px; height: 21px;"> 

<asp:RadioButtonList ID="rbl_gh7" runat="server" RepeatDirection="Horizontal" 

Width="513px"> 

<asp:ListItem>1 year</asp:ListItem> 

<asp:ListItem>2 years</asp:ListItem> 

<asp:ListItem>3 years</asp:ListItem> 

<asp:ListItem>4 years</asp:ListItem> 

<asp:ListItem>5 or more years</asp:ListItem> 

<asp:ListItem>Never</asp:ListItem> 

</asp:RadioButtonList> 

<asp:RequiredFieldValidator ID="RequiredFieldValidator6" runat="server" ControlToValidate="rbl_gh7" 

Display="None" ErrorMessage='Please answer "When was the last time you had a mammogram?"'></asp:RequiredFieldValidator></td> 

</tr> 

<tr> 

<td id="prostate1" runat="server" style="width: 641px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_gh10" runat="server" Font-Bold="True" Text="When was the last time you had a prostate test (male only)?"></asp:Label></td> 

</tr> 

<tr> 

<td id="prostate2" runat="server" style="width: 641px; height: 21px;"> 

<asp:RadioButtonList ID="rbl_gh8" runat="server" RepeatDirection="Horizontal" 

Width="514px"> 

<asp:ListItem>1 year</asp:ListItem> 

<asp:ListItem>2 years</asp:ListItem> 

<asp:ListItem>3 years</asp:ListItem> 

<asp:ListItem>4 years</asp:ListItem> 

<asp:ListItem>5 or more years</asp:ListItem> 

<asp:ListItem>Never</asp:ListItem> 

</asp:RadioButtonList> 

<asp:RequiredFieldValidator ID="RequiredFieldValidator7" runat="server" ControlToValidate="rbl_gh8" 

Display="None" ErrorMessage='Please answer "When was the last time you had a prostate test?"'></asp:RequiredFieldValidator></td> 

</tr> 

<tr> 

<td style="width: 641px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_gh11" runat="server" Font-Bold="True" Text="When was the last time you had a colonoscopy?"></asp:Label></td> 

</tr> 

<tr> 

<td style="width: 641px; height: 21px;"> 

<asp:RadioButtonList ID="rbl_gh9" runat="server" RepeatDirection="Horizontal" 

Width="515px"> 

<asp:ListItem>1 year</asp:ListItem> 

<asp:ListItem>2 years</asp:ListItem> 

<asp:ListItem>3 years</asp:ListItem> 

<asp:ListItem>4 years</asp:ListItem> 

<asp:ListItem>5 or more years</asp:ListItem> 

<asp:ListItem>Never</asp:ListItem> 

</asp:RadioButtonList> 

<asp:RequiredFieldValidator ID="RequiredFieldValidator8" runat="server" ControlToValidate="rbl_gh9" 

Display="None" ErrorMessage='Please answer "When was the last time you had a colonoscopy?"'></asp:RequiredFieldValidator></td> 

</tr> 

<tr> 

<td style="width: 641px; background-color:#ebf0f9; height: 18px;"> 

<asp:Label ID="lbl_gh12" runat="server" Font-Bold="True" Text="I would rate my current health status as:"></asp:Label></td> 

</tr> 

<tr> 

<td style="width: 641px"> 

<asp:RadioButtonList ID="rbl_gh10" runat="server" RepeatDirection="Horizontal" 

Width="515px"> 

<asp:ListItem>Excellent</asp:ListItem> 

<asp:ListItem>Good</asp:ListItem> 

<asp:ListItem>Average</asp:ListItem> 

<asp:ListItem>Poor</asp:ListItem> 

<asp:ListItem>Extremely Poor</asp:ListItem> 

</asp:RadioButtonList> 

<asp:RequiredFieldValidator ID="RequiredFieldValidator9" runat="server" ControlToValidate="rbl_gh10" 

Display="None" ErrorMessage='Please answer "I would rate my current health status as:"'></asp:RequiredFieldValidator></td> 

</tr> 

<tr> 

<td style="width: 641px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_gh13" runat="server" Font-Bold="True" Text="The number of prescription medications that I currently take:"></asp:Label></td> 

</tr> 

<tr> 

<td style="width: 641px"> 

<asp:RadioButtonList ID="rbl_gh11" runat="server" RepeatDirection="Horizontal" 

Width="434px"> 

<asp:ListItem>None</asp:ListItem> 

<asp:ListItem>1 - 2</asp:ListItem> 

<asp:ListItem>3 - 5</asp:ListItem> 

<asp:ListItem>More than 5</asp:ListItem> 

</asp:RadioButtonList> 

<asp:RequiredFieldValidator ID="RequiredFieldValidator10" runat="server" ControlToValidate="rbl_gh11" 

Display="None" ErrorMessage='Please answer "The number of prescription medications that I currently take:"'></asp:RequiredFieldValidator></td> 

</tr> 

<tr> 

<td style="width: 641px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_gh14" runat="server" Text="The number of ER or Urgent Care visits in the last year:" Font-Bold="True"></asp:Label></td> 

</tr> 

<tr> 

<td style="width: 641px"> 

<asp:RadioButtonList ID="rbl_gh12" runat="server" RepeatDirection="Horizontal" 

Width="430px"> 

<asp:ListItem>None</asp:ListItem> 

<asp:ListItem>1</asp:ListItem> 

<asp:ListItem>2</asp:ListItem> 

<asp:ListItem>3</asp:ListItem> 

<asp:ListItem>4 or more</asp:ListItem> 

</asp:RadioButtonList> 

<asp:RequiredFieldValidator ID="RequiredFieldValidator11" runat="server" ControlToValidate="rbl_gh12" 

Display="None" ErrorMessage='Please answer "The number of ER or Urgent Care visits in the last year:"'></asp:RequiredFieldValidator></td> 

</tr> 

<tr> 

<td style="width: 641px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_gh15" runat="server" Text="The number of hospitalizations in the last year:" Font-Bold="True"></asp:Label></td> 

</tr> 

<tr> 

<td style="width: 641px; height: 42px;"> 

<asp:RadioButtonList ID="rbl_gh13" runat="server" RepeatDirection="Horizontal" 

Width="427px"> 

<asp:ListItem>None</asp:ListItem> 

<asp:ListItem>1</asp:ListItem> 

<asp:ListItem>2</asp:ListItem> 

<asp:ListItem>3</asp:ListItem> 

<asp:ListItem>4 or more</asp:ListItem> 

</asp:RadioButtonList> 

<asp:RequiredFieldValidator ID="RequiredFieldValidator12" runat="server" ControlToValidate="rbl_gh13" 

Display="None" ErrorMessage='Please answer "The number of hospitalizations in the last year:"'></asp:RequiredFieldValidator></td> 

</tr> 

<tr> 

<td style="width: 641px; background-color:#ebf0f9; height: 16px;"> 

<asp:Label ID="lbl_gh16" runat="server" Font-Bold="True" Text="How many days did you miss work (or unable to perform daily activities) in the past 12 months due to sickness or injury:" 

Width="600px"></asp:Label></td> 

</tr> 

<tr> 

<td style="width: 641px; height: 23px;"> 

<asp:RadioButtonList ID="rbl_gh14" runat="server" RepeatDirection="Horizontal" 

Width="428px"> 

<asp:ListItem>None</asp:ListItem> 

<asp:ListItem>1 - 4</asp:ListItem> 

<asp:ListItem>5 - 9</asp:ListItem> 

<asp:ListItem>10 - 14</asp:ListItem> 

<asp:ListItem>15 - 19</asp:ListItem> 

<asp:ListItem>20 or more</asp:ListItem> 

</asp:RadioButtonList> 

<asp:RequiredFieldValidator ID="RequiredFieldValidator13" runat="server" ControlToValidate="rbl_gh14" 

Display="None" ErrorMessage='Please answer "How many days did you miss work ( or unable to perform daily activities) in the past 12 months due to sickness or injury:"'></asp:RequiredFieldValidator></td> 

</tr> 

</table> 

<br /> 

<input type=button value="Previous Step" onClick="history.go(-1)">&nbsp; 

<asp:Button ID="btn_continue2" runat="server" Text="Continue to Step 3" /> 

<asp:ValidationSummary ID="vs_gh1" runat="server" ShowMessageBox="True" ShowSummary="False" /> 

&nbsp; &nbsp; 

<br /> 

<br /> 

</div> 

<div id="step3" runat="server"> 

<table id="step3_table" runat="server" style="font-size: 9pt; font-family: Verdana; width: 724px;"> 

<tr> 

<td style="width: 671px; text-align: right"> 

<strong><span style="color: #ff9966">&nbsp;Step 3 of 8</span></strong></td> 

</tr> 

<tr> 

<td style="width: 671px; background-color:#1e3c7b; text-align: center;"> 

<span style="color: #ffffff; font-family: Verdana; font-size: 11pt;"><strong> 

Step 3 - Family History</strong></span></td> 

</tr> 

<tr> 

<td style="width: 671px; background-color:#ebf0f9"> 

<asp:Label ID="lbl_fh1" runat="server" Font-Bold="True" Text="My immediate family (parents, brothers, sisters) has had one of the following. Check those that apply:" Width="641px"></asp:Label></td> 

</tr> 

<tr> 

<td style="width: 671px"> 

<asp:CheckBoxList ID="cbl_fh1" runat="server" RepeatColumns="5" RepeatDirection="Horizontal" 

Width="638px"> 

<asp:ListItem>None</asp:ListItem> 

<asp:ListItem>Cancer</asp:ListItem> 

<asp:ListItem>Diabetes</asp:ListItem> 

<asp:ListItem>Heart Attack</asp:ListItem> 

<asp:ListItem>Heart Disease</asp:ListItem> 

<asp:ListItem>Stroke</asp:ListItem> 

<asp:ListItem>High Blood Pressure</asp:ListItem> 

<asp:ListItem>High Cholesterol</asp:ListItem> 

<asp:ListItem>Mental Health Problems</asp:ListItem> 

</asp:CheckBoxList></td> 

</tr> 

</table> 

<br /> 

<input type=button value="Previous Step" onClick="history.go(-1)">&nbsp; 

<asp:Button ID="btn_continue3" runat="server" Text="Continue to Step 4" />&nbsp; 

<br /> 

</div> 

<div id="step4" runat="server"> 

&nbsp;</div> 

<span style="color: #990000"> 

<br /> 

<br /> 

<br /> 

<span style="font-size: 9pt"></span></span> 

</form> 
 

</body> 

</html> 
 
 

Imports System.Data.SqlClient

Imports System.Data

Partial Class _Default

    Inherits System.Web.UI.Page
 
 

    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load

        '' Hide fields on Page Load 
 

        If Page.IsPostBack Then

        Else

            step2.Visible = False

            step3.Visible = False

            pregnant1.Visible = False

            pregnant2.Visible = False

            pap1.Visible = False

            pap2.Visible = False

            mammogram1.Visible = False

            mammogram2.Visible = False

            prostate1.Visible = False

            prostate2.Visible = False

        End If
 

    End Sub

    Protected Sub btn_Continue1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btn_Continue1.Click
 

        step1.Visible = False

        step2.Visible = True

        ' Show pregnant question if condition 

        If dd_gender.Text = "F" Then

            pregnant1.Visible = True

            pregnant2.Visible = True

            pap1.Visible = True

            pap2.Visible = True

            mammogram1.Visible = True

            mammogram2.Visible = True

        End If

        If dd_gender.Text = "M" Then

            prostate1.Visible = True

            prostate2.Visible = True

        End If

    End Sub

    Protected Sub btn_continue2_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btn_continue2.Click

        If cbl_gh1.SelectedIndex = -1 Then

            ClientScript.RegisterStartupScript(Me.GetType(), "Key", "alert('Please answer: Have you ever been told by your health provider that you have or had the following?');", True)

            step2.Visible = True

            step3.Visible = False

        ElseIf cbl_gh2.SelectedIndex = -1 Then

            ClientScript.RegisterStartupScript(Me.GetType(), "Key", "alert('Please answer: Are you currently prescribed medication for any of the following?');", True)

            step2.Visible = True

            step3.Visible = False
 

        Else

            step2.Visible = False

            step3.Visible = True
 

        End If

    End Sub

    Protected Sub btn_continue3_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btn_continue3.Click

        If cbl_fh1.SelectedIndex = -1 Then

            ClientScript.RegisterStartupScript(Me.GetType(), "Key", "alert('Please answer: My immediate family (parents, brothers, sisters) has had one of the following?');", True)

            step3.Visible = True

            step4.Visible = False

        Else

            step3.Visible = False

            step4.Visible = True

        End If

    End Sub
 
 
 
 
 

End Class

Open in new window

0
 

Author Comment

by:jml12906
ID: 24814376
Unfortuntately, still not working... it's not the back and forward button on top of IE thats the problem
if you hit the back button and then hit continue to step(1,2,3) button the page values are blank again.
0
 

Author Comment

by:jml12906
ID: 24819961
no solution
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24820816
I have done the same thing in the past and it has been fine for me.
I used panels though - can you try putting a panel round each table and hiding/shoiwng the panels rather than the tables and see if that works?
 
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24820822
Why are you closing the question?
Don't you want to get this working?
0
 

Author Comment

by:jml12906
ID: 24823112
Please keep open.... I am getting closer to a solution
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24823124
Ok - did you try using panels?
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 

Author Comment

by:jml12906
ID: 24823159
Hi daveamour,
I apologize... I defintely do want to get this going. I did try the panels but with no luck either.  I am currently enclosing each table with a div tag.  < div id="step1" runat="server">
I opened a similar question to try and get more heads in on it, and I am leaning more towards a viewstate problem. basically the viewstate is getting lost, so now I am trying to store the values via a session and reload the values on step# load event.
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24823174
Panels just render as divs anyway.
I am bulding a very simple example to test.....
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24823370
Ok I made a brand new simple example and it does behave the same as yours.
When you use the back button you are going to a part of the page wheh the controls on the later questiondon't exist on the page and that's causing the problem.
Yo solve this you cannot use ViewState since that is stored within the page as a hidden field so using the back button would lose that.
I'm thinking of a solution.....
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24823433
Are you happy to use ajax to solve this?
0
 

Author Comment

by:jml12906
ID: 24823435
Great thank you for your work! I will be thinking on my end as well..... I keep leaning towards session variables. what do you think?
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24823503
Session variables are not good for this problem.  I think Ajax would solve it really well as long as you are happy to use AJax?
0
 

Author Comment

by:jml12906
ID: 24823628
If I use ajax that would require me to pretty much rewrite the health questionnaire right? I am not familar with ajax at all. I've just started developing in asp.net.  
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24823719
No you don't have to rewrite it - Ajax is really easy
0
 

Author Comment

by:jml12906
ID: 24825007
cool, I will check that out then.. Could you give me an example of how to make an existing control say a textbox ajax ready?
 
thanks again for all your help.
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24837647
Sure I can do that.  I am a C# developer thouhg - for a simple example that should be ok though do you think?
0
 

Author Comment

by:jml12906
ID: 24839155
most defintely.... Just need an idea on "how to" and then I can translate that into vb.net
thanks again
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24839168
Ok no pronbs - which version of Visual Studio and .net are you using?
0
 

Author Comment

by:jml12906
ID: 24839175
VS 2005 Team Edition
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24839233
Does that have the Ajax Extensions (In your toolbox when in design view of a web form)?
0
 

Author Comment

by:jml12906
ID: 24839493
Sure do.
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24839542
Ok well lets look at before and after.
Attached is a page with a text box on and a button on.
Clicking the button posts back and code places the current time in the text box and resends the html back to the browser.
This is the before state and then we will look at Ajax enabling this.

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="AjaxExample._Default" %>
 

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
 

<html xmlns="http://www.w3.org/1999/xhtml" >

<head runat="server">

    <title>Untitled Page</title>

</head>

<body>

    <form id="form1" runat="server">

    <div>

        <asp:TextBox ID="Test" runat="server"></asp:TextBox><br /><br />

        <asp:Button ID="ClickME" runat="server" Text="Click Me" OnClick="ClickME_Click" />

    </div>

    </form>

</body>

</html>
 
 

using System;

using System.Data;

using System.Configuration;

using System.Collections;

using System.Web;

using System.Web.Security;

using System.Web.UI;

using System.Web.UI.WebControls;

using System.Web.UI.WebControls.WebParts;

using System.Web.UI.HtmlControls;
 

namespace AjaxExample

{

    public partial class _Default : System.Web.UI.Page

    {

        protected void Page_Load(object sender, EventArgs e)

        {
 

        }
 

        protected void ClickME_Click(object sender, EventArgs e)

        {

            Test.Text = DateTime.Now.ToString();

        }

    }

}

Open in new window

0
 
LVL 19

Expert Comment

by:daveamour
ID: 24839612
Next you need to add a script manager object and an update panel object to your page.
The resulting aspx should look like the atached.
This should then run and when you click the button then the page will not post back, rather it will use Ajax (Asynchronous javascript and xml) to talk to the server and update the page client side so no postback - all very smooth.
I'm hoping that this approach will fix your issues.
Let me know if this Ajax works first of all - you can get some errors concerning Sys with VS 2005 - if you do I'll show you how to fix them but lets see first.

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="AjaxExample._Default" %>
 

<%@ Register Assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"

    Namespace="System.Web.UI" TagPrefix="asp" %>
 

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
 

<html xmlns="http://www.w3.org/1999/xhtml" >

<head runat="server">

    <title>Untitled Page</title>

</head>

<body>

    <form id="form1" runat="server">

    <asp:scriptmanager ID="Scriptmanager1" runat="server"></asp:scriptmanager>

    <div>

        <asp:UpdatePanel ID="UpdatePanel1" runat="server">

            <ContentTemplate>

                <asp:TextBox ID="Test" runat="server"></asp:TextBox><br /><br />

                <asp:Button ID="ClickME" runat="server" Text="Click Me" OnClick="ClickME_Click" />            

            </ContentTemplate>

        </asp:UpdatePanel>

    </div>

    </form>

</body>

</html>

Open in new window

0
 

Author Comment

by:jml12906
ID: 24840298
hmm well I implemented the update panels and scriptmanager, but was getting the sys error so I followed a microsoft doc on how to implement in the web.config, but now I lose values even on page refresh?
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24846832
Can you show me your new web.config - will save me reading the article - then I'll have a look.
0
 

Author Comment

by:jml12906
ID: 24848987
Sure thing:

<?xml version="1.0"?>
<!--
Note: As an alternative to hand editing this file you can use the
web admin tool to configure settings for your application. Use
the Website->Asp.Net Configuration option in Visual Studio.
A full list of settings and comments can be found in
machine.config.comments usually located in
\Windows\Microsoft.Net\Framework\v2.x\Config
-->
<configuration>
<appSettings/>
<connectionStrings/>
<system.web>
<!--
Set compilation debug="true" to insert debugging
symbols into the compiled page. Because this
affects performance, set this value to true only
during development.
Visual Basic options:
Set strict="true" to disallow all data type conversions
where data loss can occur.
Set explicit="true" to force declaration of all variables.
-->
<compilation debug="true" strict="false" explicit="true">
<assemblies>
<add assembly="eWorld.UI, Version=2.0.6.2393, Culture=neutral, PublicKeyToken=24D65337282035F2"/>
<add assembly="System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
<add assembly="System.Design, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/></assemblies></compilation>
<pages enableViewState="true">
<namespaces>
<clear/>
<add namespace="System"/>
<add namespace="System.Collections"/>
<add namespace="System.Collections.Specialized"/>
<add namespace="System.Configuration"/>
<add namespace="System.Text"/>
<add namespace="System.Text.RegularExpressions"/>
<add namespace="System.Web"/>
<add namespace="System.Web.Caching"/>
<add namespace="System.Web.SessionState"/>
<add namespace="System.Web.Security"/>
<add namespace="System.Web.Profile"/>
<add namespace="System.Web.UI"/>
<add namespace="System.Web.UI.WebControls"/>
<add namespace="System.Web.UI.WebControls.WebParts"/>
<add namespace="System.Web.UI.HtmlControls"/>
</namespaces>
</pages>
<!--
The <authentication> section enables configuration
of the security authentication mode used by
ASP.NET to identify an incoming user.
-->
<authentication mode="Windows"/>
<!--
The <customErrors> section enables configuration
of what to do if/when an unhandled error occurs
during the execution of a request. Specifically,
it enables developers to configure html error pages
to be displayed in place of a error stack trace.
<customErrors mode="RemoteOnly" defaultRedirect="GenericErrorPage.htm">
<error statusCode="403" redirect="NoAccess.htm" />
<error statusCode="404" redirect="FileNotFound.htm" />
</customErrors>
-->

</system.web>


</configuration>
0
 
LVL 19

Accepted Solution

by:
daveamour earned 500 total points
ID: 24856830
Hmm still can't get my Ajax to work :(
I normally use VS 2008 so don't normally have these problems.
Will keep trying...
 
0
 

Author Comment

by:jml12906
ID: 24864819
no problem..... I appreciate you trying with me..... I perfer 2008 VS ( split view design / code) love it!!! But the other developers are still on 2005 so I am kinda stuck!
0
 

Author Closing Comment

by:jml12906
ID: 31601361
appreciate the help
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

ASP.Net to Oracle Connectivity Recently I had to develop an ASP.NET application connecting to an Oracle database.As I am doing it first time ,I had to solve several problems. This article will help to such developers  to develop an ASP.NET client…
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now