CasewareDocs

IsServerTask

Determines if the current task is running on IDEA Server.

Compatibility

Available as of IDEA version 9.0

Syntax

IsServerTask

Type

Boolean

Example

Sub Main 
Set db = Client.OpenDatabase ("General Ledger.IMD")
Set task = db.Extraction

task.IncludeAllFields
dbName = "Greater than 50'000.IMD"
task.AddExtraction dbName, "", "DMBTR > 50000"

If SmartContext.IsServerTask Then
task.CreateVirtualDatabase = True
Else
task.CreateVirtualDatabase = False
End If

'The same as above but much shorter
task.CreateVirtualDatabase = SmartContext.IsServerTask
task.PerformTask 1, db.count

Set task = Nothing
db.close
Set db = Nothing
End Sub