2010年6月29日 星期二

動態函式取值


如圖示,是採用函式方式取回值;這運用面就看各位怎去發揮了.
可大可小,會強化的;包好用!!
比如:
1.醫療數據類
2.單一會員基本檔
3...等等

這 code 很簡單,就慢慢品嚐這樣的作法和回饋的簡便性取值了
----
Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
ListBox1.Items.Clear()
For i As Integer = 0 To UBound(arr_func)
ListBox1.Items.Add(arr_func(i).ToString)
Next
End Sub

Private Function arr_func() As Integer()
Dim arrint(9) As Integer
arrint(0) = 10
arrint(1) = 9
arrint(2) = 8
arrint(3) = 7
arrint(4) = 6
arrint(5) = 5
arrint(6) = 4
arrint(7) = 3
arrint(8) = 2
arrint(9) = 1
Return arrint
End Function
End Class

沒有留言:

張貼留言