문제

I tried

btn.click();

And the error message is 'Cannot call property click in object ti.modules.titanium.ui.ButtonProxy@44f61. It is not a function, it is "object"'

도움이 되었습니까?

해결책

btn.fireEvent('click');

this should work

다른 팁

btn.addEventListener('click',function() {
    Titanium.API.info('Button Clicked');

});
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top