473,657 Members | 2,496 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

situation with need to update dropdown on another page

I pop up a Modal form on a web page that allows the user to update the
selections of a dropdownlist via adding a new item to the db (Sql Server).The
only thing is this list is on the page beneath it. So when the user updates
the db with a new selection, and then closes the form, the page below must be
refreshed to see the new option.

Any ideas on adding the new option to the control below the modal form?

thanx.

Nov 19 '05 #1
9 1813
This client side javascript should do the trick:

window.opener.l ocation.reload( true);

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net
"Chris" <Ch***@discussi ons.microsoft.c om> wrote in message
news:A2******** *************** ***********@mic rosoft.com...
I pop up a Modal form on a web page that allows the user to update the
selections of a dropdownlist via adding a new item to the db (Sql
Server).The
only thing is this list is on the page beneath it. So when the user
updates
the db with a new selection, and then closes the form, the page below must
be
refreshed to see the new option.

Any ideas on adding the new option to the control below the modal form?

thanx.

Nov 19 '05 #2
This client side javascript should do the trick:

window.opener.l ocation.reload( true);

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net
"Chris" <Ch***@discussi ons.microsoft.c om> wrote in message
news:A2******** *************** ***********@mic rosoft.com...
I pop up a Modal form on a web page that allows the user to update the
selections of a dropdownlist via adding a new item to the db (Sql
Server).The
only thing is this list is on the page beneath it. So when the user
updates
the db with a new selection, and then closes the form, the page below must
be
refreshed to see the new option.

Any ideas on adding the new option to the control below the modal form?

thanx.

Nov 19 '05 #3
I assume this is for the form that opened the showmodel pop-up?
If so, will this affect any of the fields/values on that form. I'm not
performing a post back so I do not want to reset the fields.
If on the parent page, where should I launch this?

would you know of a code behind method on the form that was popped up? I
know framewrok 2.0 has an option to access prevoius pages controls, but I'm
using 1.1.

thanx.

"Steve C. Orr [MVP, MCSD]" wrote:
This client side javascript should do the trick:

window.opener.l ocation.reload( true);

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net
"Chris" <Ch***@discussi ons.microsoft.c om> wrote in message
news:A2******** *************** ***********@mic rosoft.com...
I pop up a Modal form on a web page that allows the user to update the
selections of a dropdownlist via adding a new item to the db (Sql
Server).The
only thing is this list is on the page beneath it. So when the user
updates
the db with a new selection, and then closes the form, the page below must
be
refreshed to see the new option.

Any ideas on adding the new option to the control below the modal form?

thanx.


Nov 19 '05 #4
I assume this is for the form that opened the showmodel pop-up?
If so, will this affect any of the fields/values on that form. I'm not
performing a post back so I do not want to reset the fields.
If on the parent page, where should I launch this?

would you know of a code behind method on the form that was popped up? I
know framewrok 2.0 has an option to access prevoius pages controls, but I'm
using 1.1.

thanx.

"Steve C. Orr [MVP, MCSD]" wrote:
This client side javascript should do the trick:

window.opener.l ocation.reload( true);

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net
"Chris" <Ch***@discussi ons.microsoft.c om> wrote in message
news:A2******** *************** ***********@mic rosoft.com...
I pop up a Modal form on a web page that allows the user to update the
selections of a dropdownlist via adding a new item to the db (Sql
Server).The
only thing is this list is on the page beneath it. So when the user
updates
the db with a new selection, and then closes the form, the page below must
be
refreshed to see the new option.

Any ideas on adding the new option to the control below the modal form?

thanx.


Nov 19 '05 #5
The two pages do not exist on the server at the same point in time,
therefore you must use client side code for this situation.
The code snippet I gave will cause the parent page to refresh as if the user
had clicked the reload button. Using client side script you could also
submit the parent page from the child page, or alter its controls.

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net

"Chris" <Ch***@discussi ons.microsoft.c om> wrote in message
news:E2******** *************** ***********@mic rosoft.com...
I assume this is for the form that opened the showmodel pop-up?
If so, will this affect any of the fields/values on that form. I'm not
performing a post back so I do not want to reset the fields.
If on the parent page, where should I launch this?

would you know of a code behind method on the form that was popped up? I
know framewrok 2.0 has an option to access prevoius pages controls, but
I'm
using 1.1.

thanx.

"Steve C. Orr [MVP, MCSD]" wrote:
This client side javascript should do the trick:

window.opener.l ocation.reload( true);

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net
"Chris" <Ch***@discussi ons.microsoft.c om> wrote in message
news:A2******** *************** ***********@mic rosoft.com...
>I pop up a Modal form on a web page that allows the user to update the
> selections of a dropdownlist via adding a new item to the db (Sql
> Server).The
> only thing is this list is on the page beneath it. So when the user
> updates
> the db with a new selection, and then closes the form, the page below
> must
> be
> refreshed to see the new option.
>
> Any ideas on adding the new option to the control below the modal form?
>
> thanx.
>


Nov 19 '05 #6
The two pages do not exist on the server at the same point in time,
therefore you must use client side code for this situation.
The code snippet I gave will cause the parent page to refresh as if the user
had clicked the reload button. Using client side script you could also
submit the parent page from the child page, or alter its controls.

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net

"Chris" <Ch***@discussi ons.microsoft.c om> wrote in message
news:E2******** *************** ***********@mic rosoft.com...
I assume this is for the form that opened the showmodel pop-up?
If so, will this affect any of the fields/values on that form. I'm not
performing a post back so I do not want to reset the fields.
If on the parent page, where should I launch this?

would you know of a code behind method on the form that was popped up? I
know framewrok 2.0 has an option to access prevoius pages controls, but
I'm
using 1.1.

thanx.

"Steve C. Orr [MVP, MCSD]" wrote:
This client side javascript should do the trick:

window.opener.l ocation.reload( true);

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net
"Chris" <Ch***@discussi ons.microsoft.c om> wrote in message
news:A2******** *************** ***********@mic rosoft.com...
>I pop up a Modal form on a web page that allows the user to update the
> selections of a dropdownlist via adding a new item to the db (Sql
> Server).The
> only thing is this list is on the page beneath it. So when the user
> updates
> the db with a new selection, and then closes the form, the page below
> must
> be
> refreshed to see the new option.
>
> Any ideas on adding the new option to the control below the modal form?
>
> thanx.
>


Nov 19 '05 #7
mayb eI'm missing something. I still don't see where to trigger this. If what
you say is true then it must be triggered on the parent page. The pop-up is
closed by the user thus returning to that page. I don't know where that
trigger would be since I open the pop-up using:

btnxyz.Attribut es.Add("onclick ", "window.showMod alDialog('../page.aspx',
'Dialog Arguments Value','dialogW idth: 490px; help:0; resizable:no;
center:yes; edge:sunken; status:no')")

also, if you reload on a new form (in my app) you are clearly the options
and field info.

so I'm wondering if there is a way to re-bind the dropdown each time the
dropdown is clicked/touched, thus showing the new option? Or something like
that. I can't do a post back in 1.1 since it will submit the form and I don't
want to do that yet. What I'm trying to do is common in windows forms.

thanx.

"Steve C. Orr [MVP, MCSD]" wrote:
The two pages do not exist on the server at the same point in time,
therefore you must use client side code for this situation.
The code snippet I gave will cause the parent page to refresh as if the user
had clicked the reload button. Using client side script you could also
submit the parent page from the child page, or alter its controls.

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net

"Chris" <Ch***@discussi ons.microsoft.c om> wrote in message
news:E2******** *************** ***********@mic rosoft.com...
I assume this is for the form that opened the showmodel pop-up?
If so, will this affect any of the fields/values on that form. I'm not
performing a post back so I do not want to reset the fields.
If on the parent page, where should I launch this?

would you know of a code behind method on the form that was popped up? I
know framewrok 2.0 has an option to access prevoius pages controls, but
I'm
using 1.1.

thanx.

"Steve C. Orr [MVP, MCSD]" wrote:
This client side javascript should do the trick:

window.opener.l ocation.reload( true);

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net
"Chris" <Ch***@discussi ons.microsoft.c om> wrote in message
news:A2******** *************** ***********@mic rosoft.com...
>I pop up a Modal form on a web page that allows the user to update the
> selections of a dropdownlist via adding a new item to the db (Sql
> Server).The
> only thing is this list is on the page beneath it. So when the user
> updates
> the db with a new selection, and then closes the form, the page below
> must
> be
> refreshed to see the new option.
>
> Any ideas on adding the new option to the control below the modal form?
>
> thanx.
>


Nov 19 '05 #8
mayb eI'm missing something. I still don't see where to trigger this. If what
you say is true then it must be triggered on the parent page. The pop-up is
closed by the user thus returning to that page. I don't know where that
trigger would be since I open the pop-up using:

btnxyz.Attribut es.Add("onclick ", "window.showMod alDialog('../page.aspx',
'Dialog Arguments Value','dialogW idth: 490px; help:0; resizable:no;
center:yes; edge:sunken; status:no')")

also, if you reload on a new form (in my app) you are clearly the options
and field info.

so I'm wondering if there is a way to re-bind the dropdown each time the
dropdown is clicked/touched, thus showing the new option? Or something like
that. I can't do a post back in 1.1 since it will submit the form and I don't
want to do that yet. What I'm trying to do is common in windows forms.

thanx.

"Steve C. Orr [MVP, MCSD]" wrote:
The two pages do not exist on the server at the same point in time,
therefore you must use client side code for this situation.
The code snippet I gave will cause the parent page to refresh as if the user
had clicked the reload button. Using client side script you could also
submit the parent page from the child page, or alter its controls.

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net

"Chris" <Ch***@discussi ons.microsoft.c om> wrote in message
news:E2******** *************** ***********@mic rosoft.com...
I assume this is for the form that opened the showmodel pop-up?
If so, will this affect any of the fields/values on that form. I'm not
performing a post back so I do not want to reset the fields.
If on the parent page, where should I launch this?

would you know of a code behind method on the form that was popped up? I
know framewrok 2.0 has an option to access prevoius pages controls, but
I'm
using 1.1.

thanx.

"Steve C. Orr [MVP, MCSD]" wrote:
This client side javascript should do the trick:

window.opener.l ocation.reload( true);

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net
"Chris" <Ch***@discussi ons.microsoft.c om> wrote in message
news:A2******** *************** ***********@mic rosoft.com...
>I pop up a Modal form on a web page that allows the user to update the
> selections of a dropdownlist via adding a new item to the db (Sql
> Server).The
> only thing is this list is on the page beneath it. So when the user
> updates
> the db with a new selection, and then closes the form, the page below
> must
> be
> refreshed to see the new option.
>
> Any ideas on adding the new option to the control below the modal form?
>
> thanx.
>


Nov 19 '05 #9
Back at this again. Question if I relad the page isn't that the same as
re-submitting it? I've read that if the refresh button is used it might post
the form?

Also, can you please explain how and where to add the Javascript relad you
spoke of. If the form above is model, and I close it. where would the code
run?

thanx.

"Steve C. Orr [MVP, MCSD]" wrote:
The two pages do not exist on the server at the same point in time,
therefore you must use client side code for this situation.
The code snippet I gave will cause the parent page to refresh as if the user
had clicked the reload button. Using client side script you could also
submit the parent page from the child page, or alter its controls.

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net

"Chris" <Ch***@discussi ons.microsoft.c om> wrote in message
news:E2******** *************** ***********@mic rosoft.com...
I assume this is for the form that opened the showmodel pop-up?
If so, will this affect any of the fields/values on that form. I'm not
performing a post back so I do not want to reset the fields.
If on the parent page, where should I launch this?

would you know of a code behind method on the form that was popped up? I
know framewrok 2.0 has an option to access prevoius pages controls, but
I'm
using 1.1.

thanx.

"Steve C. Orr [MVP, MCSD]" wrote:
This client side javascript should do the trick:

window.opener.l ocation.reload( true);

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net
"Chris" <Ch***@discussi ons.microsoft.c om> wrote in message
news:A2******** *************** ***********@mic rosoft.com...
>I pop up a Modal form on a web page that allows the user to update the
> selections of a dropdownlist via adding a new item to the db (Sql
> Server).The
> only thing is this list is on the page beneath it. So when the user
> updates
> the db with a new selection, and then closes the form, the page below
> must
> be
> refreshed to see the new option.
>
> Any ideas on adding the new option to the control below the modal form?
>
> thanx.
>


Nov 19 '05 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
2310
by: jason | last post by:
Is there a way - possibly a disconnected rs? - to update the contents of an existing pulldown on a page without having to re-submit the page for the user to see the pulldown populated with an additional value? I realise there are javascript possibilities (and I am still searching for a usable one) but I thought perhaps it may be possible to allow a user to add a new entry to a drop down box that had been dynamically populated from an...
1
8281
by: Joseph Barron | last post by:
Here is a SIMPLE problem that I'm trying to solve. It works in Netscape 6.2, but IE6 gives ""No such interface supported." Below are page1.htm and page2.htm . In page1.htm, there are two dropdown lists. If you change the selection of the left one (e.g. choose parentoption2), it should open up page2.htm in a popup window.
0
1782
by: Henke | last post by:
Hi, I have done some research about my problem I have when using the "back button" in IE to go back to a page with two dropdown lists. The both dropdown lists are populated with data. The first dropdown lists is redirecting the user to another page (building a querystring for the second page to use) and when the back button
0
2425
by: Nithin | last post by:
My code as an txt attachment. I have 2 drop down list boxes that on selection populate text boxes from my database table. I am able to display the correct values in these text boxes. I have 2 questions: 1) I would like the user update these text fields that get populated with data from the database. For some reason I get the error when I change the textbox value.
0
249
by: Chris | last post by:
I pop up a Modal form on a web page that allows the user to update the selections of a dropdownlist via adding a new item to the db (Sql Server).The only thing is this list is on the page beneath it. So when the user updates the db with a new selection, and then closes the form, the page below must be refreshed to see the new option. Any ideas on adding the new option to the control below the modal form? thanx.
1
4086
by: Oleg | last post by:
Hi, I'm having a problem with page caching and therefore reusing dropdown box contents. Scenerio: user1 has security to see list of three items(.aspx populates it with three items only) in dropdown on page1. user2 has security to see list of two items in dropdown on page1. user1 logs in. when user1 gets to page1, dropdown has three items.
6
2067
by: Hannibal111111 | last post by:
I am getting a strange situation with a .NET 1.1 web application that we have deployed. I have made an update to a code behind page in 1 file, and then made an update to another code behind page. After that I rebuilt everything. This is all on my dev server. Now I move the 1 code behind page and the updated dll to the live server. But I did not move the other code behind page to the live server. Now somehow I am getting an error on...
2
10290
by: William Youngman | last post by:
We are developing an application that presents data to the user in a gridview and we are using the dropdown extender to give the user a SharePoint 2007 type dropdown menu attached to the cells of a given column. We are also using another dropdown menu that the user can use to select data using another quesry using the SelectedIndex change method. Upon initial page load everything works fine and the user is presented with a SharePoint type menu....
16
3488
by: ARC | last post by:
Hello all, So I'm knee deep in this import utility program, and am coming up with all sorts of "gotcha's!". 1st off. On a "Find Duplicates Query", does anyone have a good solution for renaming the duplicate records? My thinking was to take the results of the duplicate query, and somehow have it number each line where there is a duplicate (tried a groups query, but "count" won't work), then do an update query to change the duplicate to...
0
8425
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8326
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8845
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
8522
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
5647
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4333
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2745
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1973
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1736
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.