Skip to content
This repository has been archived by the owner on Sep 27, 2022. It is now read-only.

Module 2 link a website to your app #121

Open
becschatz opened this issue Jun 20, 2018 · 2 comments
Open

Module 2 link a website to your app #121

becschatz opened this issue Jun 20, 2018 · 2 comments

Comments

@becschatz
Copy link

Hi Seinecle,
I am trying too link a webiste to my app however it is saying Builed failed. Prior to this the build was successful

This is the code that I wrote:

public void onActionEvent(com.codename1.ui.events.ActionEvent ev) {
display.getInstance().execute("http://www.sportsdietitians.com.au");
}
}

Thanks

@seinecle
Copy link
Owner

seinecle commented Jun 20, 2018

Try putting a capitalized D at "display":

Display.getInstance().execute("http://www.sportsdietitians.com.au");

A red warning will appear in the margin. Click on "Add import Display.."

@becschatz
Copy link
Author

Capital D did not work this is what the output screen says

Compiling 1 source file to D:\rscha34\Desktop\NetBean\Redsnutrition\Redsnutrition\build\tmp
D:\rscha34\Desktop\NetBean\Redsnutrition\Redsnutrition\src\schatz\redsnutrition\Screen1.java:78: error: cannot find symbol
Display.getInstance().execute("http://www.sportsdietitians.com.au");
symbol: variable Display
location: class Screen1
Note: D:\rscha34\Desktop\NetBean\Redsnutrition\Redsnutrition\src\schatz\redsnutrition\Screen1.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
1 error
D:\rscha34\Desktop\NetBean\Redsnutrition\Redsnutrition\build.xml:57: Compile failed; see the compiler error output for details.
BUILD FAILED (total time: 2 seconds)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants