var obj = document.getElementByIdx_x(”testSelect”); //定位idvar index = obj.selectedIndex; // 选中索引var text = obj.options[index].text; // 选中文本var value =...
分类:
Web程序 时间:
2015-12-01 12:48:12
阅读次数:
147
就想找个设置html combobox或者select默认选项的代码,百度搜了半小时不知所云的内容,其实很简单,代码如下js的方式:var index = 你的下标getElementById("id").selectedIndex=index ;jqurey的方式:var index = 你的下标...
分类:
Web程序 时间:
2015-11-30 20:27:40
阅读次数:
132
index.cshtml Username:password:password1:sex:level:sportwritelevel:12@section scripts{} index.js $().ready(function () {$("#formLogin").validate({rul....
分类:
Web程序 时间:
2015-11-03 17:22:41
阅读次数:
245
1 检测是否有选中if(objSelect.selectedIndex > -1) {//说明选中}else{//说明没有选中}2.动态创建selectfunctioncreateSelect(){varmySelect = document.createElement("select");mySe...
分类:
其他好文 时间:
2015-11-03 11:59:00
阅读次数:
151
一、select对象 HEML中的下拉列表 属性: 1.options获得当前select下所有option 2.options[i]获得当前select下i位置的option 3.selectedIndex获得当前选中的option的下标 4.size设置或返回下拉列表...
分类:
其他好文 时间:
2015-10-25 22:21:34
阅读次数:
221
最近在做列表头部的Carousel展示,Carousel使用的是FlipView展示,另外使用ListBox显示当前页,如下图我们先设置一个绑定的数据源 public class GlobalResource : INotifyPropertyChanged { priva...
分类:
其他好文 时间:
2015-10-17 23:43:59
阅读次数:
572
探讨C#.NET下DropDownList的一个有趣的bug及其解决办法摘要:本文就C#.Net 环境下Web开发中经常使用的DropDownList控件的SelectedIndex属性进行了详细的探讨,发现了这一属性在使用中存在的问题,并经过测试,提出了回避和解决的办法。关键词:DropDownL...
分类:
其他好文 时间:
2015-09-30 00:58:29
阅读次数:
218
UITabBarController一:UITabBarController的基本属性 //设置初识时显示第几个视图控制器 tabbar.selectedViewController=second;或 tabbar.selectedIndex=2;二:简单的TabBarController创建 //...
分类:
其他好文 时间:
2015-09-13 15:52:59
阅读次数:
257
selectedIndex 属性可设置或返回下拉列表中被选选项的索引号。options[]返回包含下拉列表中的所有选项的一个数组。add()向下拉列表添加一个选项。blur()从下拉列表移开焦点。focus()在下拉列表上设置焦点。remove()从下拉列表中删除一个选项。
分类:
其他好文 时间:
2015-09-07 00:38:25
阅读次数:
144
A、ShowMessage(IntToStr(Column.Index)); B、ShowMessage(IntToStr(dbgrid1.SelectedField.Index));1、得到当前格子中的内容:DBGrid1.Fields[DBGrid1.SelectedIndex].Displa....
分类:
数据库 时间:
2015-09-05 17:41:36
阅读次数:
171