I have a TextArea in my browser, and in my code, the variable "MyTextArea" is correctly assigned. When I try to type in a string that is a full sentence, only the first word is typed in and the rest is not. But if I try a second time it works fine. I cannot say for sure, but it might also be because this browser window with the textarea object was just opened and this is the first thing I'm trying to type into it.
Here is my code and what I did to work around it (note that almost always the if condition is triggered)... perhaps if this is a bug you can look into it.
MyTextArea.UseEnsureVisible = True MyTextArea.PressKeys("{CONTROL DOWN}{END}{CONTROL UP}{SHIFT DOWN}{CONTROL DOWN}{HOME}{CONTROL UP}{SHIFT UP}{DELETE}") MyTextArea.PressKeys(sValuePassedIn) 'And to fix it I just did this, which solves the problem.... If MyTextArea.InnerText <> sValuePassedIn Then MyTextArea.UseEnsureVisible = True MyTextArea.PressKeys("{CONTROL DOWN}{END}{CONTROL UP}{SHIFT DOWN}{CONTROL DOWN}{HOME}{CONTROL UP}{SHIFT UP}{DELETE}") MyTextArea.PressKeys(sValuePassedIn) End IfAracknid