Aspen Touch Solutions ATM-123R Series Specifikace Strana 64

  • Stažení
  • Přidat do mých příruček
  • Tisk
  • Strana
    / 374
  • Tabulka s obsahem
  • KNIHY
  • Hodnocené. / 5. Na základě hodnocení zákazníků
Zobrazit stránku 63
2-50 Key HYSYS Objects
2-50
returned to variants.
The presence of Flex in the object name indicates the
possibility of a dynamic array (in other words, has a
variable size, depending on what is being returned.)
The example below, shows how to get a stream property value
in a specific unit using the RealVariable method GetValue.
The example below, shows how to set a stream property value
in a specific unit using the RealVariable method SetValue.
The example below, checks how the temperature value of a
stream is determined by examining the state property.
The constants vsCalculated, vsSpecified, and
Example 1: RealVariable
Dim hyStream As ProcessStream
Dim TemperatureVal As Double
Set hyStream = hyCase.Flowsheet.MaterialStreams.Item(0)
TemperatureVal = hyStream.Temperature.GetValue(“F”)
MsgBox hyStream.name & “ temperature(F) = “ & TemperatureVal
Example 2: RealVariable
Dim hyStream As ProcessStream
Dim TemperatureVal As Double
Set hyStream = hyCase.Flowsheet.MaterialStreams.Item(0)
TemperatureVal = 150
hyStream.Temperature.SetValue 150, “F”
Example 3: RealVariable
Dim hystream As ProcessStream
Set hystream = hyCase.Flowsheet.MaterialStreams.Item(0)
Select Case hystream.Temperature.State
Case vsCalculated
MsgBox “Temperature value is calculated.”
Case vsSpecified
MsgBox “Temperature value is specified.”
Case vsDefaultedValue
MsgBox “Temperature value is default.
End Select
Zobrazit stránku 63
1 2 ... 59 60 61 62 63 64 65 66 67 68 69 ... 373 374

Komentáře k této Příručce

Žádné komentáře