----------BOX---------- Sub Page_Load(Sender As Object, E As EventArgs) If Not Page.IsPostBack Then DropDownList1.DataTextField = "flag_id" DropDownList1.DataSource = MyQueryMethod2() DropDownList1.DataBind() End If End Sub ---------end-------- ---------BOX-------- Sub DropDownList1_SelectedIndexChanged(sender As Object, e As EventArgs) End Sub ---------end-------- ---------BOX-------- DataGrid1.DataSource = MyQueryMethod(DropDownList1.Items(DropDownList1.SelectedIndex).Text) DataGrid1.DataBind() ---------end-------- ----------BOX---------- Dim物件變數名稱As New命名空間.類別 ----------end--------- ----------BOX---------- Dim wsProxy As New MtxWs.example() ----------end---------- ----------BOX---------- dim wsProxy as new MtxWs.example() Label1.text=wsProxy.add(cint(TextBox1.text),cint(TextBox2.text)) ----------end---------- ----------BOX---------- dim wsProxy as new MtxWs.example() Label2.text=wsProxy.Subtract(cint(TextBox3.text),cint(TextBox4.text)) ---------end----------