Mani Maran
Posts: 0
Joined: Tue Jul 21, 2015 12:49 am

how do i change text in listitem if i click the button? (In javascript)

If i click the mobilebutton_7 under panel_6. it wants to change text in mobilelistitem_49 under mobileheader and what do i want to write in javascript? Don't link any url please, i already tried those links

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

how do i change text in listitem if i click the button? (In javascript)

Hello Mani,

Is this button located in list item? Are these listitems generate via service?

Mani Maran
Posts: 0
Joined: Tue Jul 21, 2015 12:49 am

how do i change text in listitem if i click the button? (In javascript)

No, button is located in panel and listitem is located in app page. No, list items won't generate any service

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

how do i change text in listitem if i click the button? (In javascript)

Please use JS below:

preApperyio("mobilelistitemName").text("Test text");/pre

here mobilelistitemName - mobilelistitem's name

Mani Maran
Posts: 0
Joined: Tue Jul 21, 2015 12:49 am

how do i change text in listitem if i click the button? (In javascript)

Thanks Mr. Sergiy Kulibaba

Francois Conradie9916163
Posts: 0
Joined: Tue Jan 15, 2019 12:20 pm

how do i change text in listitem if i click the button? (In javascript)

Maybe I'm stupid, but when you start an app from scratch and you place to components a button and text and you name the text txtBox and add the following script

Apperyio("txtBox").text("100");

When you click the button, I can't understand why a simple statement like this won't work

Write
Alert("Hello World") and it pops up so the click event does fire from the button

Illya Stepanov
Posts: 0
Joined: Mon Mar 18, 2013 8:48 am

how do i change text in listitem if i click the button? (In javascript)

Hello Francois, do you use a jQuery Mobile Appery.io builder?
I have just tested the case and it works perfectly - please check out if there any errors in the browser console when running your app.

Return to “Issues”