radiobuttons on windows phone applicationbar? - c#

Hey guys I have this page :
PS: this is temp data, so it don't look so good ;P
Now if I click on that filter button, I want a popup window or radio buttons to show in the application bar, is that even possible? Or should I try another way of doing this?
As you choose a radio button I am going to have the page filter on the choice made, so I can't leave the page to go make a choice. Any help/link/tutorial will be appreciated :)
Thanks in advance,
Working on windows phone 8/ silverlight / c# ...

You can't have a radio button in the app bar.
I would implement this as a separate page and update your filter when you navigate back to this page. The page instance and view model will be still in memory so it should be a matter of detecting the back navigation in OnNavigatedTo and applying your filter at that point. Sharing a ViewModel between this page and your filter page would be the best way of communicating the filter value, but that's not the only way.

Related

Universal Windows 8.1 App Page Change

I am trying to change pages when a text block is selected but I don't know how to get my app to go to the next page.
Figured out the answer to my question. In order to navigate between pages, you need to make the following call when the event you want the transition to happens:
this.Frame.Navigate(typeof(/*name of page you want to transition to*/));

windows phone skipping frames in navigation

I have an app where you could go through in views like;
play -> normal or custom -> select map -> summary -> start
I would like to make a shortcut option from play to summary, but I also want navigation back to select map page with the back button functionality.
So the normal workflow p->noc->sm->summary but I want to implement p->sm with the noc<-sm<-summary back functionality too (with the windows phone back button).
I saw how can I delete items from the backstack, but google not helped me how can I navigate through a couple of windows without showing that to the user.
Am I need to override the back button or there is a "better" way to do that?
It's a WP8 project.
Edit:
I didnt need the exact codesnippet for this just a design concept in this patform. (just for the is it duplicated guy)
My normal or custom and select map page should be randomized when I do the shortcut, both of these pages has a "button" which can randomize those settings, I just want a swipe->press->swipe->press->swipe actions shortened to a button press without loosing the 'post modification after randomized' feature.
After I read your comments I think I will handle the back button all of the mentioned views so the backstack will not be getting inconsistent at any state. If I understand well I can tell it in every page what is the "backed" page.
You can't inject pages into the backstack. You can override the back button and do a forward navigation with the animations you would normally do when going backward (and then remove the page you just came from off the stack), but honestly, this all gets complicated and for good reason. One of the few hard truths of Windows Phone design is that you shouldn't mess with the backstack.
Instead, I would rethink your flow. It seems like your second page is a setting of some sort (Normal or Custom). If that is changeable, maybe make a button that can float a modal popup on top of the page and move things around according to the new decision.
Looking again at your flow, it seems like several of the pages may be settings. Can you combine those into one page, maybe on a pivot or panorama? That way making changes is just a swipe away.
Regardless, while it is possible to do what you are looking to achieve, I would look long and hard at whether it is actually the best experience for your users.

Silverlight Browser back button to work

In my Silverlight app how can I determine if the Back button is pressed and to not logout, as it is currently doing. I may have a problem as the app is primarily a grid with drill down but at least if it could return to the start page, would be great.
I think the only way to trap that is with javascript. And the only thing you can do that way is to get an OK Cancel standard messagebox.
Or what you can do if you want to manage different pages with silvelight; create a Silverlight Navigation application (with the appropritate template).

Correct way to move to another page in my app

I a new to Silverlight and I want to make sure I do this in the "correct" way (if there is one).
Say I am showing MainPage.xaml and I want to have a button click move me to ADifferentPage.xaml (after the OnButtonClick is run).
What is the correct way to do that?
Use the Silverlight Navigation Application Project Template. And use the Navigation frame to navigate to other pages.
Please have a look at the UriMapper too in the main page.
So, on the button click event you can use the NavigationService.Navigate() method.

Display gridview in new window

Just a bit of advice needed really in terms of how I should handle my current scenario:
I have a web page that searches for products/category information the results of which are at present displayed in a gridview on the same page.
However, said gridview is a bit of a beast and as such, I would like to have a page that the user searches for, a button is pressed and the subsequent gridview is displayed in a new window.
Ultimately, I would like the user to be able to make multiple searches so that new windows can have multiple gridviews containing different data sets.
My current thinking is to create session variables that can be pulled through onto 'the gridview page'. Having said that, I'm not sure that would work if multiple searches are created?
I am also thinking I might be able to create said 'gridview window' using javascript but my concern here is the potential loss of functionality of the gridview i.e. paging, sorting, editing, etc.
Does anyone have any thoughts or theories on this? What would be "best practise"? Any thoughts greatly appreciated and taken on board.
PS: This is being developed in .net, using c# and LINQ.
PPS: I'm a noob so be gentle!!
There is no need of sessions here right ? well on your first page where you enter search query, when user clicks on the button open the search result page in a new window with a query string may be search.aspx?keyword=foo.
so everytime user clicks on search button it keeps on opening new windows. u can javascript to open the new popup window and set "target" attribute to "Blank" so it will open in new window

Categories