The CvsClient object contains the following methods:
Note: A description for each CxCvsLib helper object can be found in CxCvsLib Helper Objects.
AlphaGet(Request As AlphaGetReq, Response As AlphaGetResp) As Integer
| Parameter | Required | Description |
|---|---|---|
|
Request |
Yes |
The request object that contains the parameters for this method. Type: AlphaGetReq |
|
Response |
Yes |
The response object that contains the output of this method. Type: AlphaGetResp |
AlphaGetRtREx (Request As AlphaGetRtRExReq, Response As AlphaGetRtRExResp) As Integer
| Parameter | Required | Description |
|---|---|---|
|
Request |
Yes |
The request object that contains the parameters for this method. Type: AlphaGetRtRExReq |
|
Response |
Yes |
The response object that contains the output of this method. Type: AlphaGetRtRExResp |
The Connect method connects the object to a service.
Connect(DomainSiteService As String)
| Parameter | Required | Description |
|---|---|---|
|
DomainSiteService |
Yes |
The [Domain]Site.Service to which to connect. A domain is optional. The service must be a valid CVS. |
Returns 0 if successful and a non-zero value if the connection failed.
Example
The following example connects the CvsClient object to the CYGDEMO.UIS on domain 5410:
Example
|
Sub TheView_EventInitialize() 'Connect to a UIS Dim This : Set This = TheView CvsClient.Connect("[5410]CYGDEMO.UIS") End Sub |
The Disconnect method disconnects from the service.
Disconnect() As Integer
Returns 0 if successful and a non-zero value if the disconnect failed.
Example
|
Sub btnButton_EventClick() Dim This : Set This = btnButton Dim iTest iTest = CvsClient.Disconnect() If iTest <> 0 Then MsgBox "Error in disconnecting" End If End Sub |
The GetConsoleData method returns the console text and display attributes as two 25x80 arrays of unsigned characters.
GetConsoleData(ByRef pText, ByRef pAttr) As Integer
| Parameter | Required | Description |
|---|---|---|
|
pText |
Yes |
A two-dimensional 25x80 array of console text attributes returned by this method. |
|
pAttr |
Yes |
A two-dimensional 25x80 array of console display attributes returned by this method. |
This method returns 0 if successful.
Example
The following example writes the console text and display attributes to a CSV file.
|
Sub Dim aryText, aryAttr, nRet nRet = CvsClient.GetConsoleData(aryText, aryAttr)
' Write text attributes to CSV file Dim i, j, strMsg For i = 0 To UBound(aryText, 1) For j = 0 To UBound(aryText, 2) strMsg = strMsg + CStr(aryText(i, j)) + "," Next strMsg = strMsg + vbCr Next
dim fso, file Set fso = CreateObject("Scripting.FileSystemObject") Set file = fso.OpenTextFile("c:\console_text_attrs.csv", 2, True) file.WriteLine(strMsg) file.Close
strMsg = ""
' Write display attributes to CSV file For i = 0 To UBound(aryAttr, 1) For j = 0 To UBound(aryAttr, 2) strMsg = strMsg + CStr(aryAttr(i, j)) + "," Next strMsg = strMsg + vbCr Next
Set file = fso.OpenTextFile("c:\console_disp_attrs.csv", 2, True) file.WriteLine(strMsg) file.Close
MsgBox nRet End Sub |
The GetFacilityList method returns a list of facility IDs in a CVS.
GetFacilityList(ByRef FacilityList) As Integer
| Parameter | Required | Description |
|---|---|---|
|
FacilityList |
Yes |
Output. The array of facilities received. |
GetNamedRec(Request As GetNamedRecReq, Response As GetNamedRecResp) As Integer
| Parameter | Required | Description |
|---|---|---|
|
Request |
Yes |
The request object that contains the parameters for this method. Type: GetNamedRecReq |
|
Response |
Yes |
The response object that contains the output of this method. Type: GetNamedRecResp |
GetNamedRtREx(Request As GetNamedRtRExReq, Response As GetNamedRtRExResp) As Integer
| Parameter | Required | Description |
|---|---|---|
|
Request |
Yes |
The request object that contains the parameters for this method. Type: GetNamedRtRExReq |
|
Response |
Yes |
The response object that contains the output of this method. Type: GetNamedRtRExResp |
GetNamedSRtREx(Request As GetNamedSRtRExReq, Response As GetNamedSRtRExResp) As Integer
| Parameter | Required | Description |
|---|---|---|
|
Request |
Yes |
The request object that contains the parameters for this method. Type: GetNamedSRtRExReq |
|
Response |
Yes |
The response object that contains the output of this method. Type: GetNamedSRtRExResp |
The GetPointList method returns a list of Short Point IDs.
GetPointList(Descriptor As String, ByRef PointList) As Integer
| Parameter | Required | Description |
|---|---|---|
|
Descriptor |
Yes |
Indicates the descriptor(s) to retrieve for the point. |
|
PointList |
Yes |
Output. The array of Short Point IDs returned. |
GetRec(Request As GetRecReq, Response As GetRecResp) As Integer
| Parameter | Required | Description |
|---|---|---|
|
Request |
Yes |
The request object that contains the parameters for this method. Type: GetRecReq |
|
Response |
Yes |
The response object that contains the output of this method. Type: GetRecResp |
The GetReferences method refreshes the list of services referenced by the connected service.
GetReferences () As Integer
Example
The following example refreshes the referenced services.
|
Sub GetReferences() 'Create and initialize the CVS Client Dim CvsClient Set CvsClient = CreateObject("CxCvs.CvsClient") CvsClient.Connect("CYGDEMO.UIS")
uisClient.GetReferences() End Sub |
GetRefs(Request As GetRefsReq, Response As GetRefsResp) As Integer
| Parameter | Required | Description |
|---|---|---|
|
Request |
Yes |
The request object that contains the parameters for this method. Type: GetRefsReq |
|
Response |
Yes |
The response object that contains the output of this method. Type: GetRefsResp |
GetRtREx(Request As GetRtRExReq, Response As GetRtRExResp) As Integer
| Parameter | Required | Description |
|---|---|---|
|
Request |
Yes |
The request object that contains the parameters for this method. Type: GetRtRExReq |
|
Response |
Yes |
The response object that contains the output of this method. Type: GetRtRExResp |
GetShortNamedRec(Request As GetShortNamedRecReq, Response As GetShortNamedRecResp) As Integer
| Parameter | Required | Description |
|---|---|---|
|
Request |
Yes |
The request object that contains the parameters for this method. Type: GetShortNamedRecReq |
|
Response |
Yes |
The response object that contains the output of this method. Type: GetShortNamedRecResp |
GetShortRec(Request As GetShortRecReq, Response As GetShortRecResp) As Integer
| Parameter | Required | Description |
|---|---|---|
|
Request |
Yes |
The request object that contains the parameters for this method. Type: GetShortRecReq |
|
Response |
Yes |
The response object that contains the output of this method. Type: GetShortRecResp |
GetSNamedRtREx(Request As GetSNamedRtRExReq, Response As GetSNamedRtRExResp) As Integer
| Parameter | Required | Description |
|---|---|---|
|
Request |
Yes |
The request object that contains the parameters for this method. Type: GetSNamedRtRExReq |
|
Response |
Yes |
The response object that contains the output of this method. Type: GetSNamedRtRExResp |
GetSRtREx(Request As GetSRtRExReq, Response As GetSRtRExResp) As Integer
| Parameter | Required | Description |
|---|---|---|
|
Request |
Yes |
The request object that contains the parameters for this method. Type: GetSRtRExReq |
|
Response |
Yes |
The response object that contains the output of this method. Type: GetSRtRExResp |
MatchName(Request As MatchNameReq, Response As MatchNameResp) As Integer
| Parameter | Required | Description |
|---|---|---|
|
Request |
Yes |
The request object that contains the parameters for this method. Type: MatchNameReq |
|
Response |
Yes |
The response object that contains the output of this method. Type: MatchNameResp |
MatchNamedRtREx(Request As MatchNamedRtRExReq, Response As MatchNamedRtRExResp) As Integer
| Parameter | Required | Description |
|---|---|---|
|
Request |
Yes |
The request object that contains the parameters for this method. Type: MatchNamedRtRExReq |
|
Response |
Yes |
The response object that contains the output of this method. Type: MatchNamedRtRExResp |
The ResolvePoints method resolves a list of facility UDCs or Long Point IDs.
ResolvePoints(TagList, ByRef PointList) As Integer
| Parameter | Required | Description |
|---|---|---|
|
TagList |
Yes |
An array of Long Point IDs or facility UDCs (in "FACILITY.UDC" format) to convert to Short Point IDs |
|
PointList |
Yes |
Output. The array of Short Point IDs returned. |
SetRecord(Request As SetRecordReq, Response As SetRecordResp) As Integer
| Parameter | Required | Description |
|---|---|---|
|
Request |
Yes |
The request object that contains the parameters for this method. Type: SetRecordReq |
|
Response |
Yes |
The response object that contains the output of this method. Type: SetRecordResp |
SetRtREx(Request As SetRtRExReq, Response As SetRtRExResp) As Integer
| Parameter | Required | Description |
|---|---|---|
|
Request |
Yes |
The request object that contains the parameters for this method. Type: SetRtRExReq |
|
Response |
Yes |
The response object that contains the output of this method. Type: SetRtRExResp |