Sets or returns a value indicating whether results will be captured and/or returned by the brExecute method.
object.brResults[ = iValue]
| Parameter | Description |
|---|---|
| object | An object variable that represents a clsD3TCLCommand object. |
| iValue | The setting or return value is an Integer data type or a TCL Command Constant, as specified in Settings. |
| TCL Command Constants | Value | Description |
|---|---|---|
| D3ExecuteNoResults | 0 | Neither brCapturing nor brReturning are set. |
| D3ExecuteCapturing | 1 | Only brCapturing is set. |
| D3ExecuteReturning | 2 | Only brReturning is set. |
| D3ExecuteWithBoth | 3 | Both brCapturing and brReturning are set. |
The results code can also be set using the brOpenTclCommand method or the brExecute method.
Sub Main()
Dim oEnv As New clsD3Environment
Dim oConn As clsD3Connection
Dim oTCLCmd As clsD3TclCommand
Dim sResult As String
Dim sNumOrders As String
Set oConn = oEnv.brOpenConnection("ODBC", "Production")
Set oTCLCmd = oConn.brOpenTclCommand("")
oTCLCmd.brCommand = "run dm,bp, process.orders"
' Provide appropriate data that is typically
' entered by the user.
oTCLCmd.brData "Y" & D3AMChr & "Y"
oTCLCmd.brResults= D3ExecuteCapturing
oTCLCmd.brExecute
Debug.Print oTCLCmd.brCapturing.brCString
sResult = oTCLCmd.brCapturing.brExtractStr(1)
sNumOrders = oTCLCmd.brCapturing.brExtractStr(2)
oConn.brCloseTclCommand oTCLCmd
oEnv.brCloseConnection oConn
Set oEnv = Nothing
End Sub