Number picker as same as time picker in alarm app in windows phone 8 (xaml) - xaml

I am new on windows phone development and I need scroll number picker (as time picker in Alarm app) as shown in image how can i get it.....
View Image Here

If you just need a list of numbers similar to the TimePicker then populate the same primitive controls that the TimePicker uses. In this case you're look at LoopingSelector, you still need to NuGet/Install the windows phone toolkit.
Use
<phone:PhoneApplicationPage
xmlns:toolkit_primitives="clr-namespace:Microsoft.Phone.Controls.Primitives;assembly=Microsoft.Phone.Controls.Toolkit">
<toolkit_primitives:LoopingSelector>
<primitives:LoopingSelector.ItemTemplate>
<DataTemplate>
<!-- design your own square box+text -->
</DataTemplate>
</primitives:LoopingSelector.ItemTemplate>
</toolkit_primitives:LoopingSelector>
For more information:
See TimePickerPage.xaml Source Code
See MSDN Forum on LoopingSelector
OLD Solution
If you're using WP 8.0+ SL then see this SO Post: TimePicker 24h Format. It deals with the Windows Phone Toolkit: TimePicker <toolkit:TimePicker>
Else if you're doing a WP8.1 runtime app just set the ClockIdentifier to 24HourClock.
<TimePicker Header="24HourClock" ClockIdentifier="24HourClock"/>

Related

Use Dojo date picker on iOS devices instead of native picker - XPages Feature Pack 8

We have an XPages (web) application which includes a date field. When editable the field gets rendered automatically with a dojo-based date picker popup, which works on a desktop and iPad.
Since installing Feature Pack 8 the default behaviour of the date picker when accessed from an iPad has changed to use the native iOS date picker instead (via the HTML5 attribute). Prior to feature pack 8 it use the dojo-based date picker button/popup.
How do we go back to how it was before and enforce the dojo datepicker on the iPad? There are some comments around date picker behaviour in the feature-pack 8 release notes but they are around the use of the mobile theme which we are not using in this instance.
Thanks.

Xamarin: How do I set a placeholder image in my Image element in XAML?

In Android, it is quite easy to set a image placeholder for development purposes in an imageview.
All one would do is use the tools:src for the placeholder image during development so you could see it in your layout design preview and your actual image you would put into your android:src
. Frequently, you don't set the android:src put would populate that imageview with images that you download off the internet once you connect your app to the net:
<ImageView
android:layout_width="28dp"
android:layout_height="28dp"
android:src=#drawable/activated_icon"
tools:src="#mipmap/white_activated_icon" />
In Xamarin, you have this to display images:
<Image Source="http://lorempixel.com/1920/1080/nature/3" />
Once the app connects, the image is downloaded from the internet and displayed. How do I put in a placeholder image for development purposes (similar to the way you would do it through tools:src in android) so I can see it within the layout design previews?
I'm assuming you want to achieve this with Xamarin Forms, as you referring to XAML in the question title.
Or possibly you are referring to the Xamarin Forms Previewer? In that case, disregard the following answer. You can only use local images in the Previewer as far as I can tell.
Answer in case the question is related to runtime Xamarin Forms
There is no standard option to do this in Xamarin Forms. Take a look at this example suggested by Stephane Delcroix from the Xamarin Forums. The important part of this approach is to stack 2 images on top of each other in a grid. 1 is the placeholder that is placed beneath the image that is being loaded, like this:
var grid = new Grid();
grid.RowDefinitions.Add (new RowDefinition());
grid.Children.Add (image);
grid.Children.Add (placeholderImage);
As an alternative option, WebImage of Xamarin Forms Labs allows an option for a DefaultImage, but I'm not sure if that shows immediately. See this class for the code of the Web Image. Keep in mind that Xamarin Forms Labs is no longer under active maintenance.
Of course you can also write a custom renderer. Maybe based on the Xamarin Forms Labs example.
I use FFImageLoading for this Case.
Just install the Nuget Package and Use the "CachedImage" in XAML.
<ff:CachedImage Source="your url" Placeholder="placeholder while loading"/>
You don´t need to download (and cache) the Image manually then. It will automatically displayed when the download is done.
You can use local files (from Resources or Drawable) and files from HTTP/HTTPS.

Calendar Date Picker for UWP

I'm currently developing a UWP app and I stumbled upon this in google, https://msdn.microsoft.com/en-us/windows/uwp/controls-and-patterns/calendar-date-picker
I'm currently using date picker in selecting dates but I thinks the calendar date picker is more suitable for this. I used date picker back then because I can't find calendar date picker in my toolbox and I believed it is not available for UWP. But referring to the link above, it should be available in my toolbox.
I really really want to use the calendar date picker.
It seems that you’re developing universal windows 8.1 app, not UWP app (windows 10). So you would not use “Calendar date picker” control in your project.
If you want to use it, you would need to update your OS to windows 10, and install windows 10 SDK. More information, please refer to this document about “Get started with Windows apps” for details.
Just use it in your xaml
<CalendarDatePicker />
Since you seem to have the documentation link, and there's no particular question I don't know what else to add.
Note that CalendarDatePicker needs DateTime object to bind but simple DatePicker DateTimeOffset object to bind. If you want to create CalendarDatePicker without any default value you have to use nullable DateTime by
DateTime? date {get;set;}= null;
at code behind and bind it with x:Bind.
On the other hand, i recommend to try use telerik controls. For me RadCallendar looks really great ;)
If you are developing UWP there is Calendar Date Picker Control.
Copy below code into your .xaml file:
<Grid>
<CalendarDatePicker x:Name="myCalendar" Header="Select Date"/>
</Grid>

Custom Slider control in windows store 8 app

I want to edit the default style of Slider control in windows 8 app.
Need to customize the slider as per my requirement.
I want the slider like the following
I tried with the style given in this link , but it only supports windows8.1 app, but mine is windows 8 app.
Can anybody help me to edit the default style.
Thank you.
Noorul.

How to display a Windows 8 metro style tile within an app?

Windows 8 metro style app tiles are created based on pre-defined xml templates (found here).
Is there any way to hook up to Windows' rendering of the tile to allow a tile preview within an app?
In my app I would like to offer the user a subset of the tile templates listed in the above link and let the user customize the tile content. A live preview of the customized tile rendered within my app would greatly improve the user experience.
you should look into HubTile.
I don't know any free control's right now, but Telerik and Syncfusion have HubTile control
You can't get access to real Windows tile rendering, but you can simulate it since all templates are known. It is very unlikely that Microsoft would change the way tiles are rendered and even if they do you should be able to issue app update to keep up with Microsoft.