Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9263823
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T13:40:47+00:00 2026-06-18T13:40:47+00:00

Hello im new with Programming and with googlescripts i hope some can help me,

  • 0

Hello im new with Programming and with googlescripts i hope some can help me, i make as a test app just a simple textbox with a button and i want to change the value of the textbox and show the date and the time when i clicking on the button , i have trid to write this code but i dont know where is the wrong in it
thank you all

 function doGet() {
      var app=UiApp.createApplication().setTitle('test app');
      var pan1=app.createHorizontalPanel();
      app.add(pan1);
      var txt1=app.createTextBox().setId(txt1);
      var btn1=app.createButton().setText('start').setId('btn1');
      btn1.addClickHandler(app.createServerHandler("now"));
      pan1.add(txt1);
      pan1.add(btn1);
      return app;
}

function now() {
     var app =UiApp.getActiveApplication();
     app.getElementById("txt1").setText(new Date());
     return app;
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T13:40:48+00:00Added an answer on June 18, 2026 at 1:40 pm

    Change the following line

    var txt1=app.createTextBox().setId(txt1);

    to

    var txt1=app.createTextBox().setId('txt1');

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am new to iPhone programming,need some Help, I am using SQLITE Database In
Hello I'm new to android programming. I would like to ask how can I
Relatively new to Java and Android programming can anybody help as to why I'm
Hello im new to programming, im trying to construct my first simple application, im
hello I'm new to PHP programming and I migrated from ASP .net to PHP..
Hello i'm new to programming.I have address in following format and i want to
Hello I am new here and programming in C. I didn't want to ask
I am new to programming so there may be a simple solution to my
Hello I am new to programming working on Selenium using Ruby and I'm having
Hello friends a very novice question as I am very new to programming. I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.