i wanted to enter some text to a text field in my android application.I installed the app and in the second page i wanted to search for some places.For that i need to enter some text.
I tried `device.press('KEYCODE_BUTTON_SELECT',MonkeyDevice.DOWN_AND_UP)
device.press('KEYCODE_i','DOWN_AND_UP')
device.press('KEYCODE_n','DOWN_AND_UP')
device.press('KEYCODE_d','DOWN_AND_UP')
device.press('KEYCODE_i','DOWN_AND_UP')
device.press('KEYCODE_a','DOWN_AND_UP')
or Device.type(India)`
But these commands are not working for my application.,It is not entering string "India" to my application text filed.But this is working with phone native search text filed.
I installed Android View Client and import the following things
import from com.dtmilano.android.view client import View Client
from com.android.monkey runner import Monkey Runner, Monkey Device
Then i wrote the code like this
vc = ViewClient(device)
vc.dump()
address= vc.findViewById('search')
address.type('india')
But it is showing error: 'None Type' object has no attribute 'type'.
Can u pls help me in doing this.