亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? frmmain.frm

?? 很好的Kepware的VB的OPC Client例子.
?? FRM
?? 第 1 頁 / 共 5 頁
字號:
                Else
                    ' If it is an array we need to turn the array into a string
                    ' that shows the values separated by commas.
                    Dim b As Integer
                    itmX.SubItems(1) = "" ' listview item string to start
                    ' Regardless of the Option Base setting arrays returned
                    ' from an OPC Server have a starting index of 0
                    For b = 0 To UBound(ItemValue)
                        ' Build the array display by looping through each value and appending it with a comma.
                        itmX.SubItems(1) = itmX.SubItems(1) + Str(ItemValue(b)) + ", "
                    Next b
                End If
                
                ' Get the item Quailty for this item.
                Quality = OPCItemToUpdate.GetItemQuality(OPCItemLocal)
                If Quality And &HC0 Then
                    itmX.SubItems(2) = "Good"
                Else
                    itmX.SubItems(2) = "Bad" + Str(Quality)
                End If
                            
                ' Get the next ListView item using its numeric index number.
                ' If we exceed the number of item available in the list
                ' display the error handler will automatically to us to the
                ' SkipDisplayUpdate label
                a = a + 1
                Set itmX = lvListView.ListItems.Item(a)
            Next i
            
      End If
        
    End If
SkipDisplayUpdate:
End Sub


' The AddSelectedOPCServerMain is called from the frmSelectOPCServer form.
' The function is housed here because of the dependecy it has on
' updating the TreeView control once a new server connection is added.
' This function also creates the actual working instance of the OPCServerClass
' object that will be used to contain your OPC groups and their associated
' items.  If the server connection is successfully made with the server
' the OPCServers collection will be updated to contain the new OPCServerClass
' object.  The TreeView will also be updated with this new server connection.
' Whether your OPC application has a user interface or is driver progrmatically,
' you will always start by making a connection to an OPC server first.
' Once the connection to the OPC server is made you can add groups and items
' to the connection and start putting OPC to use.  In this example this
' function handle both the class objects and the user interface objects.
' In your application you may not need the user interface code.
'
Sub AddSelectedOPCServerMain(OPCServerName As String)
    ' Create a OPCServerClass object that we will attempt to connect to the server
    ' if the connection is sucessful we will add this new OPCServerClass object to
    ' OPCServers collection.
    Dim OPCServer As OPCServerClass
    Set OPCServer = New OPCServerClass
    Dim Result As Boolean
    
    ' Create a unique key for this new server
    Dim SrvName As String
    SrvName = "Server" + Str(Module1.ServerIndex)
          
    ' Attempt a connection to the selected OPC Server
    Result = OPCServer.ConnectOPCServer(OPCServerName, SrvName, Module1.ServerIndex)
          
    ' Prepare for next server connection.
    Module1.ServerIndex = Module1.ServerIndex + 1
    
    ' If the connection was sucessful then add this new OPCServerClass
    ' object to the OPCServers collection and add this to the TreeView.
    If (Result = True) Then
           
        With OPCServers
           .Add OPCServer, SrvName
        End With
    
        ' Add Node objects.
        Dim nodX As Node    ' Declare Node variable.
        ' Add the new server as a root in the tree view
        Set nodX = fMainForm.tvTreeView.Nodes.Add(, , SrvName, OPCServerName)
        nodX.EnsureVisible
    
        ' Make this new server the selected server
        Set Module1.SelectedOPCServer = OPCServer
        ' Clear any selected group or item
        Set Module1.SelectedOPCGroup = Nothing
        Set Module1.SelectedOPCItem = Nothing
        ' Remove all items from the list view if there are any.
        lvListView.ListItems.Clear
    
    End If
    
    ' If the connect fails the DisplayOPC_COM_ErrorValue inside of the OPCServerClass
    ' will display the error.
    
    End Sub
    
    
' The AddOPCGroupMain function is called from the frmAddGroup form.
' The function is housed here because of the dependecy it has on
' updating the TreeView control once a new group object is added.
' Unlike the AddSelectedOPCServerMain function above this function does not
' actually create the OPCGroupClass object.  That is done in the
' OPCServerClass object you now have.  The OPCServerClass objects are handled
' directly by your application.  After that the OPCGroupClass object and
' OPCItemClass object are handled by the class modules.  You have access to the
' the collections within these object that house the groups or items but
' your application doesn't directly need to store these objects.
' You'll also notice that unlike the OPCServerClass object, we as the
' application don't determine the OPC group key instead the AddOPCGroup
' function of the OPCServerClass object returns a key to us.  This key
' can then be used in the list view as a key.  The key is unique for all
' server connection since it is built using the group index and the server
' index numbers.  Example group keys are "Group 1 1" for a group on
' OPCServerClass object with a server index of 1, and "Group 1 2" on an
' OPCServerClas object with a server index of 2.  In this example this
' function handle both the class objects and the user interface objects.
' In your application you may not need the user interface code.
'
Sub AddOPCGroupMain(ByVal GroupName As String, ByVal UpdateRate As Long, ByVal DeadBand As Single, ByVal ActiveState As Boolean)
    
    Dim GroupKey As String
               
    If Module1.SelectedOPCServer.AddOPCGroup(GroupName, UpdateRate, DeadBand, ActiveState, GroupKey) = True Then
        ' Add Node objects.
        Dim nodX As Node    ' Declare Node variable.
        ' Add the new server as a root in the tree view
        Set nodX = fMainForm.tvTreeView.Nodes.Add(Module1.SelectedOPCServer.GetOPCServerKey, tvwChild, GroupKey, GroupName) ' + Str(Module1.SelectedOPCServer.GetOPCServerIndex)
        nodX.EnsureVisible
    End If
    
    ' If the add group fails the DisplayOPC_COM_ErrorValue inside of the OPCServerClass
    ' will display the error.
    
End Sub


' The AddOPCItemMain function is called from the frmAddItem Form.
' The function is housed here because of the dependecy it has on
' updating the ListView control once a new group object is added.
' Unlike the AddSelectedOPCServerMain function above this function does not
' actually create the OPCItemClass object.  That is done in the
' OPCGroupClass object you now have.  Once you have a group added to your
' OPCServerClass object you can add items to it by calling the
' OPCGroupClass.AddOPCItem function.  The AddOPCItem function takes
' the ItemID, Datatype, and Active state as parameters. It also
' takes a ItemKey string to hold the returned ItemKey for use in the
' ListView control.  In this example this
' function handle both the class objects and the user interface objects.
' In your application you may not need the user interface code.
'
Function AddOPCItemMain(ByVal ItemID As String, ByVal DataTypeSelected As Integer, ByVal ActiveState As Integer)
    
    Dim ItemKey As String
    
    ' Make sure the SelectedOPCGroup pointer is valid
    If Not Module1.SelectedOPCGroup Is Nothing Then
        ' Attempt to add an OPC item to the selected group.
        If Module1.SelectedOPCGroup.AddOPCItem(ItemID, DataTypeSelected, ActiveState, ItemKey) = False Then
            AddOPCItemMain = False
            GoTo ErrorOnAdd
        End If
    End If
    
    Dim itmX As ListItem
    ' Add the new item to the ListView's ListItem objects.
    Set itmX = lvListView.ListItems.Add(, ItemKey, ItemID)
    itmX.SubItems(1) = "" 'Initialize to no value
    itmX.SubItems(2) = "Bad" ' Initialize to Bad quality
    
    ' Let the caller know the function worked.
    AddOPCItemMain = True
ErrorOnAdd:
End Function
    
    
    
    
    
'*****************************************************************
' The remainder of this module was code generated by the VB wizard
'*****************************************************************

Private Sub mnuHelpAbout_Click()
    frmAbout.Show vbModal, Me
End Sub


Private Sub mnuViewStatusBar_Click()
    If mnuViewStatusBar.Checked Then
        sbStatusBar.Visible = False
        mnuViewStatusBar.Checked = False
    Else
        sbStatusBar.Visible = True
        mnuViewStatusBar.Checked = True
    End If
    SizeControls imgSplitter.Left
End Sub

Private Sub mnuViewUpdateDispaly_Click()
    Load frmItemUpdateInterval
    frmItemUpdateInterval.Show
End Sub


Private Sub Form_Resize()
    On Error Resume Next
    If Me.Width < 3000 Then Me.Width = 3000
    SizeControls imgSplitter.Left
End Sub


Private Sub imgSplitter_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
    With imgSplitter
        picSplitter.Move .Left, .Top, .Width \ 2, .Height - 20
    End With
    picSplitter.Visible = True
    mbMoving = True
End Sub


Private Sub imgSplitter_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
    Dim sglPos As Single
    

    If mbMoving Then
        sglPos = X + imgSplitter.Left
        If sglPos < sglSplitLimit Then
            picSplitter.Left = sglSplitLimit
        ElseIf sglPos > Me.Width - sglSplitLimit Then
            picSplitter.Left = Me.Width - sglSplitLimit
        Else
            picSplitter.Left = sglPos
        End If
    End If
End Sub


Private Sub imgSplitter_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
    SizeControls picSplitter.Left
    picSplitter.Visible = False
    mbMoving = False
End Sub


Sub SizeControls(X As Single)
    On Error Resume Next
    

    'set the width
    If X < 3500 Then X = 2500
    If X > (Me.Width - 2500) Then X = Me.Width - 2500
    tvTreeView.Width = X
    imgSplitter.Left = X
    lvListView.Left = X + 40
    lvListView.Width = Me.Width - (tvTreeView.Width + 140)
    lblTitle(0).Width = tvTreeView.Width
    lblTitle(1).Left = lvListView.Left + 20
    lblTitle(1).Width = lvListView.Width - 40


        
    tvTreeView.Top = picTitles.Height
    lvListView.Top = tvTreeView.Top
    

    'set the height
    If sbStatusBar.Visible Then
        tvTreeView.Height = Me.ScaleHeight - (picTitles.Top + picTitles.Height + sbStatusBar.Height)
    Else
        tvTreeView.Height = Me.ScaleHeight - (picTitles.Top + picTitles.Height)
    End If
    

    lvListView.Height = tvTreeView.Height
    imgSplitter.Top = tvTreeView.Top
    imgSplitter.Height = tvTreeView.Height
End Sub


Private Sub TreeView1_DragDrop(Source As Control, X As Single, Y As Single)
    If Source = imgSplitter Then
        SizeControls X
    End If
End Sub

Private Sub mnuFileExit_Click()
    'unload the form
    Unload Me
End Sub

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日韩一级片网站| 亚洲色图欧洲色图婷婷| 亚洲成人先锋电影| 精品综合久久久久久8888| 国产一区二区三区四区五区入口| 99re热这里只有精品免费视频| 成人国产精品视频| 欧美私模裸体表演在线观看| 久久久99精品久久| 亚州成人在线电影| 成人免费看视频| 日韩美女在线视频| 久久综合色婷婷| 亚洲线精品一区二区三区八戒| 2024国产精品| 激情成人综合网| 中文字幕中文在线不卡住| 不卡大黄网站免费看| 日韩美女啊v在线免费观看| 色吧成人激情小说| 丝袜国产日韩另类美女| 亚洲成人在线观看视频| 91蝌蚪国产九色| 成人永久免费视频| 91精品国产一区二区三区蜜臀 | 欧美大片在线观看| 亚洲女子a中天字幕| 国产成人8x视频一区二区| 欧美区在线观看| 亚洲欧美偷拍三级| 国产毛片精品一区| 日韩欧美电影一二三| 午夜精品在线视频一区| 欧美主播一区二区三区美女| wwwwxxxxx欧美| 蜜臀av一区二区在线观看| 欧美日韩高清一区| 亚洲高清免费在线| 99视频热这里只有精品免费| 欧美国产视频在线| 懂色av一区二区在线播放| 欧美成人一区二区| 欧美96一区二区免费视频| 欧美久久免费观看| 午夜影院久久久| 欧美三级视频在线播放| 亚洲一区免费在线观看| 欧美专区日韩专区| 亚洲成人久久影院| 欧美一区二区国产| 久久er99精品| 欧美r级在线观看| 日韩精品三区四区| 91精品国产综合久久久久久漫画| 亚洲成av人综合在线观看| 欧美色中文字幕| 夜夜精品视频一区二区| 6080亚洲精品一区二区| 久久av老司机精品网站导航| 久久综合一区二区| www.成人网.com| 一区二区免费在线播放| 欧美日韩和欧美的一区二区| 日本美女一区二区| 91精品国产色综合久久不卡电影| 男女激情视频一区| 亚洲一区二区av电影| 日韩三级免费观看| 国产一区二区不卡| 亚洲色图.com| 欧美日高清视频| 国产伦精品一区二区三区免费| 国产精品你懂的在线欣赏| 成人av手机在线观看| 亚洲一区二区视频| 精品国产乱码久久久久久老虎 | 国产目拍亚洲精品99久久精品| 成人网在线免费视频| 亚洲欧洲色图综合| 91精品国产一区二区三区| 国产成人亚洲综合a∨婷婷图片 | 国产精品免费av| 欧美日韩一区二区三区不卡| 久久精品国产亚洲a| 国产亚洲1区2区3区| 欧美三级电影精品| 丰满放荡岳乱妇91ww| 日日嗨av一区二区三区四区| 亚洲视频 欧洲视频| 国产亚洲精品超碰| 精品久久久久久无| 日韩午夜小视频| 91 com成人网| 欧美日韩视频在线观看一区二区三区| 成人美女视频在线观看18| 国产一区二区三区最好精华液| 日韩高清一级片| 亚洲大型综合色站| 亚洲一二三四区| 亚洲精品亚洲人成人网| 国产日韩欧美一区二区三区乱码 | 欧美顶级少妇做爰| 91国产免费看| 在线看国产日韩| 色婷婷久久久综合中文字幕| 91亚洲永久精品| 成人黄色777网| av亚洲精华国产精华精| 成人一二三区视频| caoporn国产精品| 成人激情小说乱人伦| 丁香网亚洲国际| 成人免费视频一区| 成人av高清在线| 91免费国产视频网站| 日本韩国精品在线| 欧美视频第二页| 91精品久久久久久蜜臀| 宅男噜噜噜66一区二区66| 日韩一级高清毛片| 蜜臀av在线播放一区二区三区| 日本视频中文字幕一区二区三区| 日韩中文字幕亚洲一区二区va在线 | 国产精品免费观看视频| 国产精品视频一区二区三区不卡| 中文字幕在线不卡一区二区三区| 中文字幕成人网| 亚洲另类春色国产| 三级欧美在线一区| 紧缚捆绑精品一区二区| 成人免费va视频| 欧美午夜理伦三级在线观看| 欧美一区二区视频在线观看2020 | 91麻豆国产在线观看| 欧洲精品一区二区三区在线观看| 欧美剧情片在线观看| 亚洲精品一区二区三区福利| 国产精品剧情在线亚洲| 亚洲综合精品自拍| 久久av中文字幕片| 97久久人人超碰| 欧美一级午夜免费电影| 国产精品欧美综合在线| 日韩电影在线一区二区| 丰满放荡岳乱妇91ww| 欧美日本在线看| 中文字幕av免费专区久久| 亚洲国产人成综合网站| 国产精品一级片在线观看| 色老汉av一区二区三区| 亚洲精品在线电影| 亚洲精品乱码久久久久久| 韩国成人在线视频| 欧美中文字幕一区| 国产欧美日韩综合精品一区二区 | 国产91精品精华液一区二区三区 | 一区二区欧美在线观看| 久草中文综合在线| 欧美中文字幕一区二区三区| 久久精品亚洲乱码伦伦中文| 亚洲免费av高清| 国产成人免费视| 欧美一级二级在线观看| 伊人开心综合网| 国产999精品久久| 欧美一级一级性生活免费录像| 亚洲欧美一区二区三区久本道91| 激情综合色丁香一区二区| 欧美精品九九99久久| 一区二区在线观看免费| 国产**成人网毛片九色 | 91亚洲男人天堂| 日韩亚洲电影在线| 亚洲精品免费一二三区| 丁香婷婷综合五月| 欧美精品一区男女天堂| 午夜欧美在线一二页| 9久草视频在线视频精品| 久久精品人人爽人人爽| 麻豆91精品91久久久的内涵| 欧美日韩国产一二三| 亚洲午夜免费视频| 91福利在线观看| 一区二区成人在线| 色系网站成人免费| 国产精品久久久久影视| 成人午夜激情片| 国产精品久久久久一区二区三区| 国产精品一区二区三区乱码| 久久久久久久久久美女| 国产一区二区三区高清播放| 精品国产伦一区二区三区免费| 另类专区欧美蜜桃臀第一页| 欧美一卡二卡在线| 青青草精品视频| 精品国产乱码久久久久久牛牛| 极品销魂美女一区二区三区| 久久久国产精品午夜一区ai换脸| 国产福利不卡视频| 国产日韩精品一区二区三区在线|