I'm testing a C++ application using SilkTest 6.0. At one point in the script SilkTest clicks a single PushButton, producing an error message saying "Access violation in variable (...) in app.exe" - and it's reproducable every time I run the script! If I perform the same click manually instead, this message NEVER appears.
It's probably hard for you to explain this behaviour without more details and/or the app itself but: Does anybody have an idea where this difference might come from? Hints where to start my research would also be very much appreciated. Am I dealing with timing problems?
Re: "Access violation" per script, but never manually
Two things actually,
1] One thing can be timing issue. Try specifying a Sleep (3) before you click the button.
2] Second could be the basestate which is set by the script. This is very important, for apps wherein there is somekind of a .ini file or a settings file, this can happen. Some defects can be reproducible only when the app is invoked with particulat settings or after the particular operation (in this case clicking on the pushutton) is done after a particular basestate is set.
You can try two things
a)Set a debug just before you click the pushbutton, step thru the code and see if the error is reproduced.
b) Set a debug just before you click the pushbutton, exit the run, then click on the pushbutton manually.
Let us know how it turns out.
Life, that dares send, A challenge to his end,
And when it comes say, Welcome friend.