Frm_OPCTest.xaml
2.37 KB
<Window x:Class="HHWCSHost.View.Frm_OPCTest"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:HHWCSHost.View"
mc:Ignorable="d"
Title="OPC测试" Height="229.2" Width="687.2" ResizeMode="CanMinimize" Closing="Window_Closing">
<Grid>
<TextBlock HorizontalAlignment="Left" Margin="76,59,0,0" TextWrapping="Wrap" Text="地址" VerticalAlignment="Top" RenderTransformOrigin="1.3,0.564"/>
<TextBox x:Name="txt_Adress" HorizontalAlignment="Left" Height="23" Margin="116,54,0,0" TextWrapping="Wrap" VerticalAlignment="Top" Width="178"/>
<TextBlock HorizontalAlignment="Left" Margin="397,59,0,0" TextWrapping="Wrap" Text="写入" VerticalAlignment="Top"/>
<TextBox x:Name="txt_Write" HorizontalAlignment="Left" Height="23" Margin="433,54,0,0" TextWrapping="Wrap" VerticalAlignment="Top" Width="120"/>
<Button x:Name="btn_Read" Content="读取" HorizontalAlignment="Left" Margin="219,94,0,0" VerticalAlignment="Top" Width="75" Click="btn_Read_Click"/>
<Button x:Name="btn_Write" Content="写入" HorizontalAlignment="Left" Margin="433,92,0,0" VerticalAlignment="Top" Width="75" Click="btn_Write_Click"/>
<Label x:Name="lab_Value" Content="Value" HorizontalAlignment="Left" Margin="116,95,0,0" VerticalAlignment="Top"/>
<TextBlock HorizontalAlignment="Left" Margin="76,99,0,0" TextWrapping="Wrap" Text="值:" VerticalAlignment="Top" FontSize="14"/>
<Label x:Name="lab_Type" Content="Label" HorizontalAlignment="Left" Margin="116,144,0,0" VerticalAlignment="Top"/>
<Button Content="打开连接" HorizontalAlignment="Left" Margin="25,10,0,0" VerticalAlignment="Top" Width="91" Click="Button_Click"/>
<Button Content="关闭连接" HorizontalAlignment="Left" Margin="130,10,0,0" VerticalAlignment="Top" Width="93" Click="Button_Click_1"/>
<Button Content="读取char" HorizontalAlignment="Left" Margin="299,94,0,0" VerticalAlignment="Top" Width="75" Click="Button_Click_2"/>
<Button Content="写入chart" HorizontalAlignment="Left" Margin="513,92,0,0" VerticalAlignment="Top" Width="75" Click="Button_Click_3"/>
</Grid>
</Window>