White insert text into text box

Jun 16, 2012 at 4:53 AM

Hi all I am using white UI tool

I am trying to insert text in to a Win-form text box

I can get the text box by

White.Core.UIItems.TextBox tbName = customer.Get< White.Core.UIItems.TextBox>(SearchCriteria.ByAutomationId("tbCustomerName"));

          
I am trying to insert the text by
tbName.Enter("Rifat");
tbName.Text = "Rifat";
tbName.SetValue("Rifat");
But these are not working. the text box remains empty, by the way the textbox is Dev express 'Text Edit'

Jun 16, 2012 at 7:22 AM

I guess this is the preferedway:

tbName.BulkText = "Rifat";

Jun 16, 2012 at 9:51 AM

Thanks fro your reply

But it still does not work anyway.

Jun 16, 2012 at 11:51 AM

Maybe you could include the output from the debugger about the tbName object? Furthermore, do you get an exception or is the request just ignored?

Jun 17, 2012 at 5:21 AM

at jalla347,

No I don't get any exception , the request is just ignored,

How can  I include the output from the debugger about the tbName object ? just don't get it.

Jun 18, 2012 at 1:58 AM

try setting the value using valuepattern for the textbox

var valuepatternTBName = tbName.AutomationElement.GetCurrentPattern(ValuePattern.Pattern) as ValuePattern;

valuepatternTBName.SetValue("Rifat");