cancel
Showing results for 
Search instead for 
Did you mean: 

Date field is getting wiped out when running keyword test

SOLVED
Highlighted
New Contributor

Date field is getting wiped out when running keyword test

My date fields are getting wiped out after other fields get populated on keyword test runs.

If you look at my attachments it fills the birthdate in but then once it fills in a SSN field with text, the birthdate disappears.

Has anyone seen this issue happen before?  We use Winforms.

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Community Hero

Re: Date field is getting wiped out when running keyword test

If you're using "SetText" to enter the dates, try "Keys" instead.  The reason being is that most likely there's an "OnExit" event on the component.  Sometimes SetText will trigger this but generally I've seen this problem with SetText.  Keys actually puts the cursor in the edit field and clicking or entering somewhere else on the screen will actually trigger that event.


Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Vegas Thrill Rider
Extensions available

View solution in original post

2 REPLIES 2
Community Hero

Re: Date field is getting wiped out when running keyword test

If you're using "SetText" to enter the dates, try "Keys" instead.  The reason being is that most likely there's an "OnExit" event on the component.  Sometimes SetText will trigger this but generally I've seen this problem with SetText.  Keys actually puts the cursor in the edit field and clicking or entering somewhere else on the screen will actually trigger that event.


Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Vegas Thrill Rider
Extensions available

View solution in original post

New Contributor

Re: Date field is getting wiped out when running keyword test

That worked beautifully.  Thank you!