D
David
Hi all,
I need to be able to 'lock' a page. It doesn't need to be a full lock, but
just to stop some actions if someone else is in a page.
I was thinking of using the application state and putting a List<T> into it,
but I am not sure how to do this. Any ideas?
In fact, the whole scenario is making my head hurt. Here is what I need to
do...
1. Add the page user and what querystring value he is looking at.
2. if someone else is in the same page and querystring value, show the
original page user.
3. If a different page, then reset the page the user to the new querystring
or make it null if away from the page.
The application[] space is probably the best place to put this to share
across multiple pages, but I am not sure how to put a key/value pair (and
more than one key/value pair) into the application[].
An example of how I am visualising it, but I don't think it will work like
this...
Application["users_in_page"].add("david", "123.234.345.456");
(I know the above is not valid, but I need it to work like an array)
and then in each page check if 123.234.345.456 is in the array and show
david as in the page.
Now, if I put "david" and "123.234.345.456" in a List, then added it to the
array, when I have another user, "john" and "132.432.543.372" to add, I
think I need to read the list, add john to it, then add the List to the
Application["users_in_page"], but that will also give me issues due to
timing.
Hhhmmm. Any ideas on how to get around this would be very much appreciated.
--
Best regards,
Dave Colliver.
http://www.AshfieldFOCUS.com
~~
http://www.FOCUSPortals.com - Local franchises available
I need to be able to 'lock' a page. It doesn't need to be a full lock, but
just to stop some actions if someone else is in a page.
I was thinking of using the application state and putting a List<T> into it,
but I am not sure how to do this. Any ideas?
In fact, the whole scenario is making my head hurt. Here is what I need to
do...
1. Add the page user and what querystring value he is looking at.
2. if someone else is in the same page and querystring value, show the
original page user.
3. If a different page, then reset the page the user to the new querystring
or make it null if away from the page.
The application[] space is probably the best place to put this to share
across multiple pages, but I am not sure how to put a key/value pair (and
more than one key/value pair) into the application[].
An example of how I am visualising it, but I don't think it will work like
this...
Application["users_in_page"].add("david", "123.234.345.456");
(I know the above is not valid, but I need it to work like an array)
and then in each page check if 123.234.345.456 is in the array and show
david as in the page.
Now, if I put "david" and "123.234.345.456" in a List, then added it to the
array, when I have another user, "john" and "132.432.543.372" to add, I
think I need to read the list, add john to it, then add the List to the
Application["users_in_page"], but that will also give me issues due to
timing.
Hhhmmm. Any ideas on how to get around this would be very much appreciated.
--
Best regards,
Dave Colliver.
http://www.AshfieldFOCUS.com
~~
http://www.FOCUSPortals.com - Local franchises available