M
Matthias S.
Hi there,
first of all, sorry for the lengthy post, but restrictions in my languages
skills and the nature of the problem account for it.
I've got the following situation: I'm creating a control which will be
placed on most of my pages. The control contains a country dropdown, a city
dropdown and a street dropdown. When a country is selected, I have to repost
the page in order to load the cities. Same for a selection made in the
cities dropdown, but there I have to reload the streets respectively. The
reposting is required due to a massive amount of data. So far so good. I can
implement this without a problem.
The control should be aware of query string values send with the URL and
adjust the values in the dropdowns accordingly (and only if they make sense:
getting the id of a city which is not located in the selected country
wouldn't make sense, so in this case we fail). I can implement this as well,
no problem here.
But here goes the tricky part: Consider the following scenario: A user opens
a page from the bookmarks with the url
'http://blah.com/listsome.aspx?countryid=12&cityid=4&streetid=43'. Then
(s)he selects a different value in the street dropdown. The page is (due to
the eventhandler of the dropdowns indexchanged) posted back to itself.
Problem here: The url in the adresse bar has identical values as the initial
request.
And here we are, facing the problem with only one control. It is likely that
there will be more then one control on a single form, some of which might
want to load their settings from the querystring (and change the url if
changes in selections occur).
I'm out of ideas, so any suggestions would be greatly appreciated.
Matthias
first of all, sorry for the lengthy post, but restrictions in my languages
skills and the nature of the problem account for it.
I've got the following situation: I'm creating a control which will be
placed on most of my pages. The control contains a country dropdown, a city
dropdown and a street dropdown. When a country is selected, I have to repost
the page in order to load the cities. Same for a selection made in the
cities dropdown, but there I have to reload the streets respectively. The
reposting is required due to a massive amount of data. So far so good. I can
implement this without a problem.
The control should be aware of query string values send with the URL and
adjust the values in the dropdowns accordingly (and only if they make sense:
getting the id of a city which is not located in the selected country
wouldn't make sense, so in this case we fail). I can implement this as well,
no problem here.
But here goes the tricky part: Consider the following scenario: A user opens
a page from the bookmarks with the url
'http://blah.com/listsome.aspx?countryid=12&cityid=4&streetid=43'. Then
(s)he selects a different value in the street dropdown. The page is (due to
the eventhandler of the dropdowns indexchanged) posted back to itself.
Problem here: The url in the adresse bar has identical values as the initial
request.
And here we are, facing the problem with only one control. It is likely that
there will be more then one control on a single form, some of which might
want to load their settings from the querystring (and change the url if
changes in selections occur).
I'm out of ideas, so any suggestions would be greatly appreciated.
Matthias