gclib 2.0.9
Communications API for Galil controllers and PLCs
 
Loading...
Searching...
No Matches
Remote_Client.vb
Go to the documentation of this file.
2 ''' <summary>
4 ''' </summary>
6 ''' <remarks>See remote_client_example.cs for an example.</remarks>
7 Function Remote_Client() As Integer
8 Dim gclib = New Gclib()
9
12 "<0-9> Enter numbers 0-9 to connect to a server by index" + vbNewLine +
14 "<q> Quit")
15
18
21
22 If input = "q" Then
24 ElseIf input = "s" Then
27 Print_Servers_List(servers_list)
28 ElseIf input >= "0" And input <= "9" Then
33 End If
34 ElseIf input = "l" Then
37 ElseIf input = "h" Then
38 Dim addresses As String() = gclib.GAddresses()
39
40 For Each address As String In addresses
42 Next
43 End If
45
46 Return Examples.GALIL_EXAMPLE_OK
48
49 Private Sub Print_Servers_List(servers_list As String())
52 Else
54 Console.WriteLine("<" + i.ToString() + "> " + servers_list(i))
55 Next
56 End If
57
58 End Sub
Provides a class of shared constants and methods for gclib's example projects.
Definition commands.cs:16
Provides a class that binds to gclib's unmanaged dll. Wraps each call and provides a more user-friend...
Definition gclib.cs:68
GCLIB_DLL_EXPORTED GReturn GCALL GListServers(GCStringOut servers, GSize servers_len)
Uses GUtility(), G_UTIL_GCAPS_LIST_SERVERS to provide a list of all available gcaps services on the l...
Definition gclibo.c:169
GCLIB_DLL_EXPORTED GReturn GCALL GSetServer(GCStringIn server_name)
Uses GUtility(), G_UTIL_GCAPS_SET_SERVER to set the new active server.
Definition gclibo.c:128
GCLIB_DLL_EXPORTED GReturn GCALL GAddresses(GCStringOut addresses, GSize addresses_len)
Uses GUtility(), G_UTIL_GCAPS_ADDRESSES or G_UTIL_ADDRESSES to provide a listing of all available con...
Definition gclibo.c:54
void error(GCon g, GReturn rc)
An example of error handling and debugging information.
Definition examples.h:40
GReturn vector(GCon g, char *file)
Puts controller into Vector Mode and accepts a file defining vector points.
Definition vector.cpp:36
int Remote_Client()
Demonstrates various uses of GListServers() and GSetServer()
partial Module Examples
Definition Commands.vb:4