I did. Toke a lot of cat skinning but I got there. Do you want me to post my solution?
Main Topics
Browse All TopicsNot sure if anyone is using Obout and their Ajax features but if you are and you can help me, you are a life saver:
I have 2 panels that have drop downs in both.
I update the drop downs from the server and when I update 1 panel, I loss the values in the other panel. Can anyone explain what I am doing wrong?
I have included attachments and code.
HTML:
<script>
function ChangeGroup() {
ob_post.post(null, "onloadGroup", function(){});
}
function CurrentDate() {
var dStartDay = document.getElementById('d
var dStartMonth = document.getElementById('d
var dStartYear = document.getElementById('d
alert(dStartMonth + "/" + dStartDay + "/" + dStartYear);
ob_post.post(null, "onDate", function(){});
}
</script>
<oajax:CallbackPanel id="cpPanel1" runat="server">
<CONTENT>
<asp:dropdownlist id="ddlDropDown" runat="server" Width="168px" AutoPostBack="false"></asp
</CONTENT>
<LOADING style="HEIGHT: 1px">
<TABLE height="100%" cellSpacing="0" cellPadding="0" width="100%">
<TR>
<TD vAlign="center" align="middle"></TD>
</TR>
</TABLE>
</LOADING>
</oajax:CallbackPanel>
<oajax:CallbackPanel id="cpPanel2" EnableViewState="true" RenderMethod="Always" Visible="true" ShowLoading="true" runat="server">
<CONTENT>
<SELECT id="ddlStartMonth" style="FONT-WEIGHT: bold; FONT-SIZE: xx-small; FONT-FAMILY: Verdana" runat="server" NAME="ddlStartMonth"></SEL
<SELECT id="ddlStartDay" style="FONT-WEIGHT: bold; FONT-SIZE: xx-small; FONT-FAMILY: Verdana" runat="server" NAME="ddlStartDay"></SELEC
<SELECT id="ddlStartYear" style="FONT-WEIGHT: bold; FONT-SIZE: xx-small; FONT-FAMILY: Verdana" runat="server" NAME="ddlStartYear"></SELE
</CONTENT>
<LOADING style="HEIGHT: 1px">
<TABLE height="100%" cellSpacing="0" cellPadding="0" width="100%">
<TR>
<TD vAlign="center" align="middle"></TD>
</TR>
</TABLE>
</LOADING>
</oajax:CallbackPanel>
<asp:button id="btnDate" runat="server" Font-Bold="True" Font-Size="XX-Small" Font-Names="Verdana" Text="What is the date" Width="120px" CausesValidation="False"><
Vb Code behind:
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim i As Integer
If Not Page.IsPostBack Then
'Pop day
For i = 1 To 31
ddlStartDay.Items.Add(i)
ddlStartDay.Items.FindByTe
Next
ddlStartDay.Value = System.DateTime.Today.Day
'Pop month
For i = 1 To 12
ddlStartMonth.Items.Add(i & "-" & MonthName(i, False))
ddlStartMonth.Items.FindBy
Next
ddlStartMonth.Value = System.DateTime.Today.Mont
'PopYear
For i = -2 To 2
ddlStartYear.Items.Add(Sys
ddlStartYear.Items.FindByT
Next
ddlStartYear.Value = System.DateTime.Today.Year
ddlDropDown.Items.Add("Sel
ddlDropDown.Items.Add("Sel
End If
ddlDropDown.Attributes.Add
btnDate.Attributes.Add("on
End Sub
Public Sub onloadGroup()
ShowAlert(ddlDropDown.Sele
ddlDropDown.Items.Clear()
ddlDropDown.Items.Add("Sel
ddlDropDown.Items.Add("Sel
UpdatePanel("cpPanel1")
End Sub
Public Sub onDate()
ShowAlert(ddlStartMonth.Va
UpdatePanel("cpPanel2")
End Sub
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Business Accounts
Answer for Membership
by: TheLearnedOnePosted on 2007-11-21 at 05:19:53ID: 20327304
Did you find a solution?
Bob