tags:

views:

249

answers:

2

Hello Devs,

i have an application where half screen will show a website and half screen will be covered with the keyboard(Not the webview's default keyboard). Keyboard has a textfield with it and user can write to the text field and send to the web page(i have used javascript there).

Now i need to keep the keyboard up while user typing and sending text to the webview..,but while user scrolls the webview by touching ...the keyboards hides. I tried the keyBoarWillHide method to make the keyboard becomefirstresponder....but no result.

any idea while scrolling webview will not hide the keyboard?

A: 

You said you are not using the default keyboard, so it means you created your keyboard? If is that the case then you should be able to control it by 100%

If you are just putting some layer or view on the default keyboard I don't have many ideas.

The thing is that the keyboard appears when something like UITextField UITextView ( or some text input-able UI Object) becomes first responder. Then, if the first responder Object is not text input-able keyboard will hide. So, When you touch an UIWebView object, this becomes the first responder and since is not text inputable, the keyboard hides.

I don't know what happens it you write something like [webview canBecomeFirstResponder:NO]; In theory this should work.

nacho4d
Actually i mean the UIWEBVIEW has a default keyboard for webviews textfields with next/previous/done button included, i didnot used "That" keyboard. i Used normal keyboard whick has a textfield as a subview.Now i want to keep the textfield always the first responder(that means up) when the user will also able to scroll the webview. i Used the canbecomefirsrresponder but no luck...Plz help....
Benzamin
A: 

You can hold onto first responder by returning NO to - (BOOL)resignFirstResponder - beware of the impact this can have on your UI though, nothing more annoying than being made to jump through the programmer's hoops before you can move on.

Adam Eberbach