RobertJay
Posts: 0
Joined: Fri Jun 15, 2012 1:32 pm

Possible bug: setting textarea focus

This works for inputs but apparently not textareas:

var t1 = Apperyio("mytextarea");
t1.focus();

RobertJay
Posts: 0
Joined: Fri Jun 15, 2012 1:32 pm

Possible bug: setting textarea focus

UPDATE: Now it's not working in inputs. So let me ask this: is this the correct command that should be used to set focus for both inputs and textareas, and if so, is it supposed to work after an alert() call and within an if block?

Alena Prykhodko
Posts: 0
Joined: Tue Apr 09, 2013 7:36 am

Possible bug: setting textarea focus

Hello Robert,

Could you please be more specific?
On what event handler do you run this code?
How do you test this?

RobertJay
Posts: 0
Joined: Fri Jun 15, 2012 1:32 pm

Possible bug: setting textarea focus

Thank you Alena, but I cannot provide that right now. Can you just tell me if that is the correct set-focus code and if it is supposed to work after an alert() call and within an if block.

Serhii Kulibaba
Posts: 150
Joined: Tue Aug 27, 2013 1:47 pm

Possible bug: setting textarea focus

Hello Robert,

This code works for me:

Apperyio("mytextarea").focus();

Could you check errors in the browser's console?

RobertJay
Posts: 0
Joined: Fri Jun 15, 2012 1:32 pm

Possible bug: setting textarea focus

Thank you Sergiy. The problem does in fact look like it's caused by alert()s . When an alert() appears either before or after the focus command, focus is lost on the target component (both inputs and textareas). I would consider this a bug.

Return to “Issues”