Xamarin.Forms Swipe to change between CollectionViews - c#

Hi there:) So that's my problem:
I've got two CollectionViews in my app and I want to be able to change between them by swiping side to side. Is there a good way to implement this?
Thanks in advance:)

At first, you can try to put the two CollectionViews in two Contentpages and set the two pages as the TabbedPage's child page. Then you can try to select different ColectionView by selecting different page when user swipes on the screen. For more information, you can check the official document about the TabbedPage.
In addition, I suggest you use the Community Toolkit's control named TabView, because it can put the two CollectionViews in the same page and there is a sample on the github, you can refer to it.

Related

How to display an entry alert in xamarin forms

I'm trying to show an alert with an entry inside it, as I can see it in a lot of apps, but I could'n t find a solution for now (neither custom renders)
Any suggestions?
You can use UserDialogs libary
After initialization simply use:
UserDialogs.Instance.Alert("message")
You can do that in multiple ways. Lets say if you have your own UI and the Entry field. Then you can create the Popup Page and Display that Popup Page whenever necessary for the User Input. If you want to use Popup Page (best - only if you have requirements to have your own style of prompt):
https://github.com/rotorgames/Rg.Plugins.Popup
If you have very simple requirement of only Showing the Entry Field the use :
https://github.com/aritchie/userdialogs
Since this is very common question and have all the resources online. Please go through the websites above have all the examples you can look into. Please let me know if you still need any more help.

Navigation to another page using swipe gesture (Windows Phone 8)

I've searched quite a lot on the Internet but haven't been able to found the exact thing that I want.
I now that I should be using the Manipulation events such as Manipulation Started, Delta, Completed.
As I said I managed to navigate to another page using swipe combining these three events, but what I actually want is to see THE MOTION when moving from the actual page to another like for example when you swipe from the Official Windows Phone 8 page to the Apps page using a left swipe. Can you please point out on how to achieve such a thing.
http://agilemobility.net/2014/07/windows-phone-8-swipe-gesture/
This page shows an example on how to that, but the motion of moving the current page and bringing the second one is displayed.
I wasn't aware of the following, and yes, Pivot is the answer to my question.
Taken from: https://msdn.microsoft.com/en-us/library/windows/apps/ff941103(v=vs.105).aspx
You can use a custom template named Windows Phone Pivot App when creating a new project. This template will come pre-populated with content and you can modify the template accordingly.
List itemThe Pivot control can be added to the Toolbox in Visual Studio and can be easily dropped into your project.
You can add a Windows Phone Pivot Page to an existing project.

Simpler Breadcrumb Bar Sample

my question is very simple. I am building an app(WPF CSharp) and I need user to give me paths that my app is going to use. Previously I added textboxes to show pathways, however, later I decided that it would be cool to use a Win 7 style Explorer navigation bar, which is a Breadcrumb bar. I found a great open source component for it here (http://www.codeproject.com/KB/tree/WPFBreadcrumbBar.aspx) however, I could not use it in my app. I added references both to Toolbox section and Project>References section. I can also add the control to my WPF window from Toolbox, yet I could not figure out how to fill it, how to change and show items in it etc. With respect to component author, I think article on Codeproject is not very 'understandable'(XAML? I want C# code please) and also PopulateItems event, for instance, did not work for me. So, if someone give me a basic example on how to add items to this bar easily, change items, or shortly, shows me how to make it work, I will appreciate for that,
Thanks.
I Guess it depends on how you want to present it. If you want to use a tab control to simulate the functionality you could go this route:
http://www.wpfblogger.com/post/BreadCrumb-TabControl-Style-for-WPF-40.aspx

Creating xaml 'template' for multiple pages

I'm developing a Silverlight application for the first time. I've gone through some tutorials, but I can't seem to find anything that helps me with this particular problem. I would like a set of buttons to be present on all of my pages (like a template). When a button is pressed, I would like the ContentGrid to slide out and a new ContentGrid slide in (with the relevant .xaml file being loaded).
Are there any tutorials showing the best way to do this? From samples I've seen, they only seem to transition between two pages, so copy-pasting the group of buttons on each xaml page isn't too much of a problem. However, with more pages, it would be inefficient to copy-paste the base layout each time.
Thanks for any suggestions
I used to create a master view and create each page content as a user control; that way, I can swap out/in the user control for the appropriate page, and I would have a consistent header that way... similar to a master page in ASP.NET. I'm sure there are other templates too; I'm not aware of everything available for Silverlight...
The one answer I cannot provide is the transition; the only thing I can offer is Telerik has a control for that purpose, the transition control: http://demos.telerik.com/silverlight/#Controls I understand if you can't drop a couple of hundred bucks to get it though :-)
HTH.
Have you tried the Silverlight Business Application Visual Studio Project template?

List of buttons?

I've been working on a small program which gets a list of url's from the web server ( latest forum topics ) and warns the user whenever a new topic is created.
So the main form of my program have a list of buttons. Each button has the text of the forum topic and extra information below. Opens the browser with the topics url when user presses.
The problem is, creating buttons for every topic doesn't feel right. I'm sure there is a better way to create a user interface for this program. I tried listview but I need space for some extra information so one line and one text-size isn't good for it.
edit: I'm sorry, it's a windows form app.
Try ObjectListView. Here's what can be done with it:
(source: sourceforge.net)
For this sort of thing I would look at WPF and style my own controls.
You can loop through them and add the buttons and labels programmatically. Placing them vertically below eachother is simple math.
Probably not best practice, but it has always worked for me.

Categories