Hi,
I am trying to create a toolbar item and if I add an icon it crashes.
Can someone guide me on this?. If possible I would like to position
this on the left and application logo on right. Is there any sample or
documentation on this?
<ContentPage.ToolbarItems>
<ToolbarItem Activated="OnToolbarButtonClick" Text="Open SideDrawer" Icon="hamburgerbuttonicon.png" >
<ToolbarItem.Icon>
<OnPlatform x:TypeArguments="FileImageSource"
iOS="hamburgerButtonIcon.png"
Android="hamburgerbuttonicon.png"
WinPhone="Assets/hamburgerButtonIcon.png" />
</ToolbarItem.Icon>
</ToolbarItem>
</ContentPage.ToolbarItems>
Thanks,
Prava
6 Answers, 1 is accepted
Please note that you have reached Telerik forums. The XamarinForms ContentPage is not part of our UI for XamarinFomrs suite this is why we cannot give you an answer of your question.
However, you can take a look at the source code of our QSF application. In it we created our own navigation bar that serves our needs. And more importantly it looks identical throughout all platforms.
Regards,
Pavel R. Pavlov
Telerik by Progress
This isn't supported at the moment in Forms.
There's enhancements coming in Forms 2.3 & 2.4 which may make this possible. You'd have to explore custom renderers if you want to achieve this with Forms 2.3.2 or earlier.
As Pavel says, this is the forum you want.
https://forums.xamarin.com/categories/xamarin-forms
Here is a link to the application in the Google Play store. The application goes with the same name in the Apple's store as well.
However, you may not want to install it on your device. If you want to explore the code on your PC you can take a look at the source of the application. We ship it with our installation. You can navigate to the installation directory on your PC and you will be able to find a folder named QSF. It holds the whole solution of the application. If you have not changed the default installation path you will be able to find the solution here:
C:\Program Files (x86)\Telerik\[release version]\QSF
I hope this information is helpful.
Regards,
Pavel R. Pavlov
Telerik by Progress
Also can't use this pattern if you have to push a modal tabbed page.