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

📄 freqform.vb

📁 使用研华DAQ和VB.net实现研华数据采集卡的多种功能.包括数据输入输出。内含多个源码
💻 VB
📖 第 1 页 / 共 2 页
字号:
Public Class frmFreq
    Inherits System.Windows.Forms.Form
    Dim isInitializing As Boolean

#Region " Windows Form Designer generated code "

    Public Sub New()
        MyBase.New()

        'This call is required by the Windows Form Designer.
        isInitializing = True
        InitializeComponent()
        isInitializing = False

        'Add any initialization after the InitializeComponent() call

    End Sub

    'Form overrides dispose to clean up the component list.
    Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
        If disposing Then
            If Not (components Is Nothing) Then
                components.Dispose()
            End If
        End If
        MyBase.Dispose(disposing)
    End Sub

    'Required by the Windows Form Designer
    Private components As System.ComponentModel.IContainer

    'NOTE: The following procedure is required by the Windows Form Designer
    'It can be modified using the Windows Form Designer.  
    'Do not modify it using the code editor.
    Friend WithEvents ScanTimer As System.Windows.Forms.Timer
    Friend WithEvents cmdExit As System.Windows.Forms.Button
    Friend WithEvents GroupBox3 As System.Windows.Forms.GroupBox
    Friend WithEvents Label8 As System.Windows.Forms.Label
    Friend WithEvents Label7 As System.Windows.Forms.Label
    Friend WithEvents txtError As System.Windows.Forms.TextBox
    Friend WithEvents GroupBox1 As System.Windows.Forms.GroupBox
    Friend WithEvents cmdSelectDevice As System.Windows.Forms.Button
    Friend WithEvents txtDeviceNum As System.Windows.Forms.TextBox
    Friend WithEvents txtDeviceName As System.Windows.Forms.TextBox
    Friend WithEvents Label2 As System.Windows.Forms.Label
    Friend WithEvents Label1 As System.Windows.Forms.Label
    Friend WithEvents GroupBox2 As System.Windows.Forms.GroupBox
    Friend WithEvents Label6 As System.Windows.Forms.Label
    Friend WithEvents Label5 As System.Windows.Forms.Label
    Friend WithEvents Label4 As System.Windows.Forms.Label
    Friend WithEvents Label3 As System.Windows.Forms.Label
    Friend WithEvents txtScanTime As System.Windows.Forms.TextBox
    Friend WithEvents cmbGateMode As System.Windows.Forms.ComboBox
    Friend WithEvents cmbChannel As System.Windows.Forms.ComboBox
    Friend WithEvents cmdScanStop As System.Windows.Forms.Button
    Friend WithEvents cmdScanStart As System.Windows.Forms.Button
    Friend WithEvents txtGatePeriod As System.Windows.Forms.TextBox
    Friend WithEvents Label9 As System.Windows.Forms.Label
    Friend WithEvents Label10 As System.Windows.Forms.Label
    Friend WithEvents Label11 As System.Windows.Forms.Label
    Friend WithEvents txtFreq As System.Windows.Forms.TextBox
   Friend WithEvents DAQCounter1 As AxDAQCounterLib.AxDAQCounter
   <System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent()
      Me.components = New System.ComponentModel.Container
      Dim resources As System.Resources.ResourceManager = New System.Resources.ResourceManager(GetType(frmFreq))
      Me.ScanTimer = New System.Windows.Forms.Timer(Me.components)
      Me.cmdExit = New System.Windows.Forms.Button
      Me.GroupBox3 = New System.Windows.Forms.GroupBox
      Me.Label8 = New System.Windows.Forms.Label
      Me.Label7 = New System.Windows.Forms.Label
      Me.txtError = New System.Windows.Forms.TextBox
      Me.txtFreq = New System.Windows.Forms.TextBox
      Me.cmdScanStop = New System.Windows.Forms.Button
      Me.cmdScanStart = New System.Windows.Forms.Button
      Me.GroupBox1 = New System.Windows.Forms.GroupBox
      Me.cmdSelectDevice = New System.Windows.Forms.Button
      Me.txtDeviceNum = New System.Windows.Forms.TextBox
      Me.txtDeviceName = New System.Windows.Forms.TextBox
      Me.Label2 = New System.Windows.Forms.Label
      Me.Label1 = New System.Windows.Forms.Label
      Me.GroupBox2 = New System.Windows.Forms.GroupBox
      Me.Label11 = New System.Windows.Forms.Label
      Me.Label10 = New System.Windows.Forms.Label
      Me.Label9 = New System.Windows.Forms.Label
      Me.txtGatePeriod = New System.Windows.Forms.TextBox
      Me.Label6 = New System.Windows.Forms.Label
      Me.Label5 = New System.Windows.Forms.Label
      Me.Label4 = New System.Windows.Forms.Label
      Me.Label3 = New System.Windows.Forms.Label
      Me.txtScanTime = New System.Windows.Forms.TextBox
      Me.cmbGateMode = New System.Windows.Forms.ComboBox
      Me.cmbChannel = New System.Windows.Forms.ComboBox
      Me.DAQCounter1 = New AxDAQCounterLib.AxDAQCounter
      Me.GroupBox3.SuspendLayout()
      Me.GroupBox1.SuspendLayout()
      Me.GroupBox2.SuspendLayout()
      CType(Me.DAQCounter1, System.ComponentModel.ISupportInitialize).BeginInit()
      Me.SuspendLayout()
      '
      'ScanTimer
      '
      '
      'cmdExit
      '
      Me.cmdExit.Location = New System.Drawing.Point(384, 56)
      Me.cmdExit.Name = "cmdExit"
      Me.cmdExit.Size = New System.Drawing.Size(88, 24)
      Me.cmdExit.TabIndex = 8
      Me.cmdExit.Text = "Close"
      '
      'GroupBox3
      '
      Me.GroupBox3.Controls.Add(Me.Label8)
      Me.GroupBox3.Controls.Add(Me.Label7)
      Me.GroupBox3.Controls.Add(Me.txtError)
      Me.GroupBox3.Controls.Add(Me.txtFreq)
      Me.GroupBox3.Controls.Add(Me.cmdScanStop)
      Me.GroupBox3.Controls.Add(Me.cmdScanStart)
      Me.GroupBox3.Location = New System.Drawing.Point(288, 96)
      Me.GroupBox3.Name = "GroupBox3"
      Me.GroupBox3.Size = New System.Drawing.Size(192, 128)
      Me.GroupBox3.TabIndex = 7
      Me.GroupBox3.TabStop = False
      Me.GroupBox3.Text = "Freq Read:"
      '
      'Label8
      '
      Me.Label8.Location = New System.Drawing.Point(11, 96)
      Me.Label8.Name = "Label8"
      Me.Label8.Size = New System.Drawing.Size(88, 16)
      Me.Label8.TabIndex = 5
      Me.Label8.Text = "Error Message:"
      '
      'Label7
      '
      Me.Label7.Location = New System.Drawing.Point(11, 64)
      Me.Label7.Name = "Label7"
      Me.Label7.Size = New System.Drawing.Size(80, 16)
      Me.Label7.TabIndex = 4
      Me.Label7.Text = "Freq value:"
      '
      'txtError
      '
      Me.txtError.ForeColor = System.Drawing.SystemColors.HotTrack
      Me.txtError.Location = New System.Drawing.Point(107, 96)
      Me.txtError.Name = "txtError"
      Me.txtError.ReadOnly = True
      Me.txtError.Size = New System.Drawing.Size(77, 20)
      Me.txtError.TabIndex = 3
      Me.txtError.Text = ""
      '
      'txtFreq
      '
      Me.txtFreq.ForeColor = System.Drawing.SystemColors.HotTrack
      Me.txtFreq.Location = New System.Drawing.Point(107, 64)
      Me.txtFreq.Name = "txtFreq"
      Me.txtFreq.ReadOnly = True
      Me.txtFreq.Size = New System.Drawing.Size(77, 20)
      Me.txtFreq.TabIndex = 2
      Me.txtFreq.Text = ""
      '
      'cmdScanStop
      '
      Me.cmdScanStop.Location = New System.Drawing.Point(104, 24)
      Me.cmdScanStop.Name = "cmdScanStop"
      Me.cmdScanStop.Size = New System.Drawing.Size(80, 24)
      Me.cmdScanStop.TabIndex = 1
      Me.cmdScanStop.Text = "Scan Stop"
      '
      'cmdScanStart
      '
      Me.cmdScanStart.Location = New System.Drawing.Point(13, 24)
      Me.cmdScanStart.Name = "cmdScanStart"
      Me.cmdScanStart.Size = New System.Drawing.Size(80, 24)
      Me.cmdScanStart.TabIndex = 0
      Me.cmdScanStart.Text = "Scan Start"
      '
      'GroupBox1
      '
      Me.GroupBox1.Controls.Add(Me.cmdSelectDevice)
      Me.GroupBox1.Controls.Add(Me.txtDeviceNum)
      Me.GroupBox1.Controls.Add(Me.txtDeviceName)
      Me.GroupBox1.Controls.Add(Me.Label2)
      Me.GroupBox1.Controls.Add(Me.Label1)
      Me.GroupBox1.Location = New System.Drawing.Point(16, 8)
      Me.GroupBox1.Name = "GroupBox1"
      Me.GroupBox1.Size = New System.Drawing.Size(352, 80)
      Me.GroupBox1.TabIndex = 5
      Me.GroupBox1.TabStop = False
      Me.GroupBox1.Text = "Select Device :"
      '
      'cmdSelectDevice
      '
      Me.cmdSelectDevice.Location = New System.Drawing.Point(240, 16)
      Me.cmdSelectDevice.Name = "cmdSelectDevice"
      Me.cmdSelectDevice.Size = New System.Drawing.Size(88, 24)
      Me.cmdSelectDevice.TabIndex = 4
      Me.cmdSelectDevice.Text = "Select Device"
      '
      'txtDeviceNum
      '
      Me.txtDeviceNum.Location = New System.Drawing.Point(96, 24)
      Me.txtDeviceNum.Name = "txtDeviceNum"
      Me.txtDeviceNum.Size = New System.Drawing.Size(56, 20)
      Me.txtDeviceNum.TabIndex = 3
      Me.txtDeviceNum.Text = "0"
      '
      'txtDeviceName
      '
      Me.txtDeviceName.Location = New System.Drawing.Point(96, 48)
      Me.txtDeviceName.Name = "txtDeviceName"
      Me.txtDeviceName.ReadOnly = True
      Me.txtDeviceName.Size = New System.Drawing.Size(248, 20)
      Me.txtDeviceName.TabIndex = 2
      Me.txtDeviceName.Text = "No Device!"
      '
      'Label2
      '
      Me.Label2.Location = New System.Drawing.Point(9, 48)
      Me.Label2.Name = "Label2"
      Me.Label2.Size = New System.Drawing.Size(80, 16)
      Me.Label2.TabIndex = 1
      Me.Label2.Text = "Device Name :"
      '
      'Label1
      '
      Me.Label1.Location = New System.Drawing.Point(9, 24)
      Me.Label1.Name = "Label1"
      Me.Label1.Size = New System.Drawing.Size(64, 16)
      Me.Label1.TabIndex = 0
      Me.Label1.Text = "Device No. :"
      '
      'GroupBox2
      '
      Me.GroupBox2.Controls.Add(Me.Label11)
      Me.GroupBox2.Controls.Add(Me.Label10)
      Me.GroupBox2.Controls.Add(Me.Label9)
      Me.GroupBox2.Controls.Add(Me.txtGatePeriod)
      Me.GroupBox2.Controls.Add(Me.Label6)
      Me.GroupBox2.Controls.Add(Me.Label5)
      Me.GroupBox2.Controls.Add(Me.Label4)
      Me.GroupBox2.Controls.Add(Me.Label3)
      Me.GroupBox2.Controls.Add(Me.txtScanTime)
      Me.GroupBox2.Controls.Add(Me.cmbGateMode)
      Me.GroupBox2.Controls.Add(Me.cmbChannel)
      Me.GroupBox2.Location = New System.Drawing.Point(16, 96)
      Me.GroupBox2.Name = "GroupBox2"
      Me.GroupBox2.Size = New System.Drawing.Size(264, 128)
      Me.GroupBox2.TabIndex = 6

⌨️ 快捷键说明

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