Navigation:  ThinBASIC Modules > Core (thinBasic Core Engine) > Core Module Classes > cTimer Class > cTimer Methods >

<cTimer>.SetName

Previous pageReturn to chapter overviewNext page

 

Description

 

Sets the name associated with the instantiated cTimer variable.

 

Syntax

 

s = <cTimer>.SetName(sName)

 

Returns

 

String: previous description

 

Parameters

 

Name

Type

Optional

Meaning

sName

String

No

Dynamic string to be passed as name

 

Remarks

 

Restrictions

 

See also

 

Examples

 

'---Create a class variable

Dim MyTimer  As cTimer

 

'---Instantiate the class variable. This will automatically call internal Constructor

MyTimer = New cTimer("TIMER1")

...

'---Assign a new Name

MyTimer.SetName("TIMERXXX")

...

 

'---Will return "TIMERXXX" string

MsgBox 0, MyTimer.GetName