简体   繁体   English

在WP7中实现下拉框的正确方法?

[英]Proper way to implement a dropdownbox in WP7 ?

I have seen 2 ways. 我看过两种方法。

  1. Fake a ASP.NET stlye and have the options appear over a textbox on the same screen. 伪造一个ASP.NET样式,并使选项显示在同一屏幕上的文本框中。

  2. When the box is touched open a new screen that lets you scroll through all options and pick one. 触摸该框后,打开一个新屏幕,使您可以滚动浏览所有选项并选择一个。 When one is selected that value is copied to the placeholder on the orginal screen. 选择一个后,该值将复制到原始屏幕上的占位符。

I am working on a project where we are doing #1 and I am thinking #2 is the proper way ? 我正在做一个正在做#1的项目,我在想#2是正确的方法?

Use ListPicker from the silverlight toolkit if you're looking to match the WP7 paradigm (which you should want to :) ) 如果您要匹配WP7范例(您应该这样做),请使用silverlight工具箱中的ListPicker :)

Silverlight Toolkit Silverlight工具包

These other stackoverflow questions may provide some insight (possible duplicate?): 这些其他stackoverflow问题可能会提供一些见解(可能重复吗?):

How to get dropdown like menu in wp7? 如何在wp7中获得类似于菜单的下拉菜单?

Windows Phone Dropdown Windows Phone下拉菜单

Don't forget to use the search function at the top right hand before asking a question! 提出问题之前,请不要忘记使用右上角的搜索功能!

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM