Some Doubts in my Own App Inventor

But we can make duplicate label and message to show version name or anything else...

1 Like

Buildserver is not activate ..

1 Like

@Android_Builder
means? I can't get you, how to activate it?

can I add something like
String html = "8th Oct 2021" + "Version 1.0" +

cd buildserver then ant RunLocalBuildserver

2 Likes

Label label1 = new Label(""8th Oct 2021" + "Version 1.0"");

panel.add(label1);

1 Like

then how to add that label1 in this line?

VerticalPanel DialogBoxContents = new VerticalPanel();
String html = MESSAGES.gitBuildId(GitBuildId.getDate(), GitBuildId.getVersion()) +
"
" + MESSAGES.useCompanion(YaVersion.PREFERRED_COMPANION, YaVersion.PREFERRED_COMPANION + "u") +
"
" + MESSAGES.targetSdkVersion(YaVersion.TARGET_SDK_VERSION, YaVersion.TARGET_ANDROID_VERSION);
Label label1 = new Label (MESSAGES.gitBuildId());
DialogBoxContents.add(label1);

2 Likes

I'll try pasting this directly
:+1:

~ @Android_Builder

I made some modifications and changed from this to this :point_down:

to this :point_down:

VerticalPanel DialogBoxContents = new VerticalPanel();

      String html = MESSAGES.gitBuildId(GitBuildId.getDate(), GitBuildId.getVersion()) + MESSAGES.useCompanion(YaVersion.PREFERRED_COMPANION, YaVersion.PREFERRED_COMPANION + "u") + MESSAGES.targetSdkVersion(YaVersion.TARGET_SDK_VERSION, YaVersion.TARGET_ANDROID_VERSION);

      Label label1 = new Label (MESSAGES.gitBuildId());

      DialogBoxContents.add(label1);

But still I got ant errors :point_down: BUILD LOG

AndroidRuntime.uptodate:

AndroidRuntime:

AiClientLib:
   [depend] Deleted 85 out of date files in 0 seconds
    [javac] Compiling 216 source files to E:\srikar\Funmora_Builder\appinventor\appengine\build\war\WEB-INF\classes
    [javac] E:\srikar\Funmora_Builder\appinventor\appengine\src\com\google\appinventor\client\TopToolbar.java:848: error: cannot find symbol
    [javac]       Label label1 = new Label (MESSAGES.gitBuildId());
    [javac]       ^
    [javac]   symbol:   class Label
    [javac]   location: class AboutAction
    [javac] E:\srikar\Funmora_Builder\appinventor\appengine\src\com\google\appinventor\client\TopToolbar.java:848: error: cannot find symbol
    [javac]       Label label1 = new Label (MESSAGES.gitBuildId());
    [javac]                          ^
    [javac]   symbol:   class Label
    [javac]   location: class AboutAction
    [javac] E:\srikar\Funmora_Builder\appinventor\appengine\src\com\google\appinventor\client\TopToolbar.java:848: error: method gitBuildId in interface OdeMessages cannot be applied to given types;
    [javac]       Label label1 = new Label (MESSAGES.gitBuildId());
    [javac]                                         ^
    [javac]   required: String,String
    [javac]   found: no arguments
    [javac]   reason: actual and formal argument lists differ in length
    [javac] Note: Some input files use or override a deprecated API.
    [javac] Note: Recompile with -Xlint:deprecation for details.
    [javac] Note: Some input files use unchecked or unsafe operations.
    [javac] Note: Recompile with -Xlint:unchecked for details.
    [javac] 3 errors

BUILD FAILED
E:\srikar\Funmora_Builder\appinventor\build.xml:16: The following error occurred while executing this line:
E:\srikar\Funmora_Builder\appinventor\appengine\build.xml:529: The following error occurred while executing this line:
E:\srikar\Funmora_Builder\appinventor\build-common.xml:125: Compile failed; see the compiler error output for details.

Total time: 9 seconds

You need to import Label class of GWT and also need to create method gitBuildId() in OdeMessages.java

1 Like

But I've no idea on these things because I am still learning this, can you guide me

I said you need to import class in your java file ...

1 Like

Please tell me in which file you have added this code ?

1 Like

TopToolbar.java

In the TopToolbar.java file you will find some statment starting with import please add following line after all import statement

import com.google.gwt.user.client.ui.Label;

2 Likes

I added it and now ran the ant command
Result:
AnnotationProcessors:

AndroidRuntime.uptodate:

AndroidRuntime:

AiClientLib:
[depend] Deleted 62 out of date files in 0 seconds
[javac] Compiling 223 source files to E:\srikar\Funmora_Builder\appinventor\appengine\build\war\WEB-INF\classes
[javac] E:\srikar\Funmora_Builder\appinventor\appengine\src\com\google\appinventor\client\TopToolbar.java:850: error: method gitBuildId in interface OdeMessages cannot be applied to given types;
[javac] Label label1 = new Label (MESSAGES.gitBuildId());
[javac] ^
[javac] required: String,String
[javac] found: no arguments
[javac] reason: actual and formal argument lists differ in length
[javac] Note: Some input files use or override a deprecated API.
[javac] Note: Recompile with -Xlint:deprecation for details.
[javac] Note: Some input files use unchecked or unsafe operations.
[javac] Note: Recompile with -Xlint:unchecked for details.
[javac] 1 error

BUILD FAILED
E:\srikar\Funmora_Builder\appinventor\build.xml:16: The following error occurred while executing this line:
E:\srikar\Funmora_Builder\appinventor\appengine\build.xml:529: The following error occurred while executing this line:
E:\srikar\Funmora_Builder\appinventor\build-common.xml:125: Compile failed; see the compiler error output for details.

Total time: 10 seconds

Now open OdeMessage.java file and this code into file ...

@DefaultMessage("MESSAGE DISPLAYED ON BROWSER")
  @Description("sort discription of message.")
  String gitBuildId();
1 Like

Remove the space between Label and the Opening Parenthesis on line number 848, to the right of the "=" sign.

1 Like

This line


Changed to this: