⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 defaultvb.aspx.vb

📁 Telerik是很大的第三方软件制造商
💻 VB
字号:
Imports System
Imports System.Collections
Imports System.ComponentModel
Imports System.Data
Imports System.Drawing
Imports System.Web
Imports System.Web.SessionState
Imports System.Web.UI
Imports System.Web.UI.WebControls
Imports System.Web.UI.HtmlControls
Imports Telerik.QuickStart
Imports Telerik.WebControls


Namespace Telerik.CallbackExamplesVB.Controls.CheckBox
    '/ <summary>
    '/ Summary description for _Default.
    '/ </summary>

    Public Class DefaultVB
        Inherits XhtmlPage
        Protected outerPanel As System.Web.UI.WebControls.Panel
        Protected innerPanel As System.Web.UI.WebControls.Panel
        Protected TextBox1 As System.Web.UI.WebControls.TextBox
        Protected TextBox2 As System.Web.UI.WebControls.TextBox
        Protected Label1 As System.Web.UI.WebControls.Label
        Protected Label2 As System.Web.UI.WebControls.Label
        Protected tbName As System.Web.UI.WebControls.TextBox
        Protected tbLastName As System.Web.UI.WebControls.TextBox
        Protected Label4 As System.Web.UI.WebControls.Label
        Protected Label3 As System.Web.UI.WebControls.Label
        Protected btnSubmit As System.Web.UI.WebControls.Button
        Protected panelLA As System.Web.UI.WebControls.Panel
        Protected WithEvents cbAdditionaInformation As Telerik.WebControls.CallbackCheckBox
        Protected WithEvents cbLicenseAgreement As Telerik.WebControls.CallbackCheckBox
        Protected WithEvents cbIAgree As Telerik.WebControls.CallbackCheckBox
        Protected tbLA As System.Web.UI.WebControls.TextBox


        Private Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Load
            If Page.IsPostBack Then
                If Not (cbAdditionaInformation.IsCallback OrElse cbLicenseAgreement.IsCallback OrElse cbIAgree.IsCallback) Then
                    ResetControlsState()
                End If
            End If
        End Sub 'Page_Load

#Region "Web Form Designer generated code"

        Protected Overrides Sub OnInit(ByVal e As EventArgs)
            '
            ' CODEGEN: This call is required by the ASP.NET Web Form Designer.
            '
            InitializeComponent()
            MyBase.OnInit(e)
        End Sub 'OnInit


        '/ <summary>
        '/		Required method for Designer support - do not modify
        '/		the contents of this method with the code editor.
        '/ </summary>
        Private Sub InitializeComponent()
        End Sub 'InitializeComponent

#End Region


        Private Sub ResetControlsState()
            cbAdditionaInformation.Checked = False
            cbLicenseAgreement.Checked = False
            cbIAgree.Checked = False
            innerPanel.Visible = False
            tbLA.Visible = False
            cbIAgree.Visible = False
            btnSubmit.Enabled = False
        End Sub 'ResetControlsState


        Private Sub CallbackCheckBox1_CheckedChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles cbAdditionaInformation.CheckedChanged
            ShowAdditionalInformation()
        End Sub 'CallbackCheckBox1_CheckedChanged




        Private Sub cbShowLA_CheckedChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles cbLicenseAgreement.CheckedChanged
            ShowLicenseAgreement()
        End Sub 'cbShowLA_CheckedChanged


        Private Sub CheckBox1_CheckedChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles cbIAgree.CheckedChanged
            btnSubmit.Enabled = cbIAgree.Checked
        End Sub 'CheckBox1_CheckedChanged


        Private Sub cbAdditionaInformation_KeyPress(ByVal sender As Object, ByVal args As Telerik.WebControls.CallbackControls.KeyEventArgs) Handles cbAdditionaInformation.KeyPress
            ShowAdditionalInformation()
        End Sub 'cbAdditionaInformation_KeyPress


        Private Sub ShowAdditionalInformation()
            innerPanel.Visible = Not innerPanel.Visible
        End Sub 'ShowAdditionalInformation


        Private Sub ShowLicenseAgreement()
            tbLA.Visible = cbLicenseAgreement.Checked
            cbIAgree.Visible = cbLicenseAgreement.Checked
            If Not cbLicenseAgreement.Checked Then
                btnSubmit.Enabled = False
            Else
                btnSubmit.Enabled = cbIAgree.Checked
            End If
        End Sub 'ShowLicenseAgreement


        Private Sub cbLicenseAgreement_KeyPress(ByVal sender As Object, ByVal args As Telerik.WebControls.CallbackControls.KeyEventArgs) Handles cbLicenseAgreement.KeyPress
            ShowLicenseAgreement()
        End Sub 'cbLicenseAgreement_KeyPress
    End Class 'DefaultVB 
End Namespace 'Telerik.CallbackExamplesVB.Controls.CheckBox

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -