| || |
I'm having trouble adding a property to a window declaration. I'm using Silk 5 to automate some software and have defined the window fred.inc thus...
const wMainWindow = fred
window MainWin fred
void Set(string value)
sNumber = value
When I use 'fred.sNumber = "1234"' in a testcase I get a stack overflow. The problem seems to be that when the agent gets to the 'sNumber = value' part of the property set command it calls the Get() function. The sNumber property value that is returned by the Get() seems to cause the Get()function to be called recursively until the stack overflows. I don't understand why the compiler seems to require the value of sNumber in order to perform an assignment. Is this a bug with silk or am I doing something completely stupid?
Re: Properties bug?
I think a variable is needed to store sNumber. 4Test says: "Properties allow information associated with a window to be accessed as if it were stored in a variable." It doesn't say a property is a variable.