T
|
Tim 7/19/2019 |
Hi Deb, |
D
|
DebZ author 7/19/2019 |
Thanks, that almost works. The only issue now is that the list returns many pages worth of data. when you click the (2,3,4, etc...) buttons on the bottom of the page to get the next page, it does not provide the link with the ptclr=x parameter, and so pages 2-xxxx fail. Hi Deb, I assume you are using the "Menu Item Editor", clicking the "..." button and adding 0 or 1 in the "Edit Page Link" text box. If so, this shows up as a query string in the URL, like so: mysite.com/myapp/mypage/list?ptclr=0 You can access query strings this way: if (HttpContext.Current.Request.QueryString["ptclr"].ToString() == "0") { Do Something } Good luck! Tim |
T
|
Tim 7/19/2019 |
Ah yes, that will only be there when you click the link from the menu. What if you put a button at the top of your list page that toggled a session variable? I usually do this by adding 2 buttons and just showing the one that is opposite of how the session is currently set. So something like: |
D
|
DebZ author 7/19/2019 |
OH! That sounds much more elegant. I'm going to give it a try. Ah yes, that will only be there when you click the link from the menu. What if you put a button at the top of your list page that toggled a session variable? I usually do this by adding 2 buttons and just showing the one that is opposite of how the session is currently set. So something like: button 1 "View BW" server code: XSession.Session["bw"]=1; button 2 "View Color" server code: XSessoin.Session["bw"]=0; Then show/hide buttons based on how session is set, and also apply background color based on session. Just a thought. Tim |
D
|
DebZ author 7/19/2019 |
This works pretty well. The only 2 items I need to do now are
|
D
|
DebZ author 7/19/2019 |
I figured out how to refresh. |
T
|
Tim 7/19/2019 |
How about, on List page, Before display event |
D
|
DebZ author 7/19/2019 |
Beautiful! I put it in the "Before Processing" event, the Before display didn't work on the initial load. How about, on List page, Before display event if (!XSession.Session["bw"]) { XSession.Session["bw"]=0; } |
T
|
Tim 7/19/2019 |
Great stuff! And thank you for the diversion. I was able to procrastinate my work while still feeling like I was accomplishing something! <img src='https://asprunner.com/forums/file.php?topicimage=1&fieldname=reply&id=88248&image=1&table=forumreplies' class='bbc_emoticon' alt=':D' /> <img src='https://asprunner.com/forums/file.php?topicimage=1&fieldname=reply&id=88248&image=2&table=forumreplies' class='bbc_emoticon' alt=':D' /> |