18057.html
来自「以电子书的形式收集了VB一些常见问题解决方法,可以很方便的查找自己需要解决的问题」· HTML 代码 · 共 23 行
HTML
23 行
<html> <head> <title>Re: ListBox 小问题一问?</title> </head> <body bgcolor="#FFFFFF" vlink="#808080"> <center> <h1>Re: ListBox 小问题一问?</h1> </center><hr size=7 width=75%><hr size=7 width=75%><p>Posted by <a href="mailto:neo725@tomail.com.tw">neo</a> on August 28, 1999 at 18:05:54:<p>In Reply to: <a href="18042.html">Re: ListBox 小问题一问?</a> posted by 小琳 on August 28, 1999 at 14:35:14:<p>: : <br>: : ListBox 小问题一问?<br>: : 请教各位高手:<br>: : 我在Form中布置一个ListBox元件阵列<br>: : 我要取得List(Index)中某一个List 元件中某一项是否被选取<br>: : 程式如何写<br>: : 下列程式会出现错误讯息不知如何写才正确?<br>: : <br>: : If List(Index).ListIndex.Select = True Then<br>: : .......<br>: : ..............<br>: : .................<br>: : End If <p>: : 请各位高手解答感激不尽<p>: :::程式如下:<br>: Option Explicit<p>: Private Sub Command1_Click() <br>: MsgBox List1.Selected(2)<br>: End Sub<p>: Private Sub Form_Load()<br>: With List1<br>: .AddItem "a"<br>: .AddItem "b"<br>: .AddItem "c"<br>: End With<br>: End Sub<br>好像这样也可以吧???<br>If List1.ListIndex <> -1 Then '判断 ListBox 是否有项目被选取 (-1 = 没有任何项目被选取)<br> .....<br> .....<br>End If<p><br><br><hr size=7 width=75%><p><a name="followups">Follow Ups:</a><br><ul><!--insert: 18057--></ul><!--end: 18057--><br><hr size=7 width=75%><p></body></html>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?