Create a slider with a dial in WPF

Source: Internet
Author: User

Slider in WPF. The value is double and the value is continuously changed between MinValue and MaxValue. To make it a discrete value (such as an integer), you must manually specify the following attributes:

  • TickFrequency: interval between each scale
  • IsSnapToTickEnabled: if it is set to True, It is aligned to the scale.
  • TickPlacement: Which side of the slider is the scale?

The SmallChange and LargeChange columns on the right of the Blend have nothing to do with this function. Never be cheated -_-

For example, if you want to design a slider to pick up integers from 3 to 10, you can set the following settings.

<Slider Margin = "3" x: name = "sliderTimes" Minimum = "3" Value = "5" SmallChange = "1" LargeChange = "2" extends aptotickenabled = "True"> </Slider>

The function of binding to element attributes in WPF is very useful, and it is very powerful for collaboration with this slide ~~

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.