Write an applet,interact with http client & html interpreter, Computer Engineering

Assignment Help:

Write an applet that can interact with both the HTTP client and HTML interpreter in a browser. 

import java.applet.*;

import java.net.*;                        // import packages //

import java.awt.*;

public class buttons extends Applet {

public void init ( ) {

add(new Button{"Yin"});

add(new Button{"Yang"});

}

public Boolean action(Event e, Object arg) {

if (( ( Button) e. target).getLabel( ) == "Yin") {

try {

getAppletContext( ).showDocument(new

URL(http: / /www.expertsminds.com/yin();

}

catch(Exception ex) {

/ / catch block is used for Handle the exception handling / /

}

}

else if (( (Button) e. target) .getLabel ( ) == "Yang") {

try {

getAppletContext ( ).showDocument(new

URL(http: / /www.expertsminds.com/yang( );

}

catch(Exception ex) {

/ / try block is used for Handle the exception handling / /

}

}

return true;

}

}


Related Discussions:- Write an applet,interact with http client & html interpreter

Read after write and write after write - data hazards, RAW  and WAW - Data ...

RAW  and WAW - Data hazards: RAW (read after write) - j tries to read a source before i writes it, hence j wrongly gets the old value .This is the most usual type of

What is a metadata, What is a Metadata?  Metadata is information about ...

What is a Metadata?  Metadata is information about a PE. In COM, metadata is communicated by non-standardized type libraries. In .NET, this data is contained in the header port

How the information can be stored, In a RAM, information can be stored ? A...

In a RAM, information can be stored ? Ans. RAM is used by the user, number of times.

C#, I have assignment about writing code in c# language this code to contro...

I have assignment about writing code in c# language this code to control the leds in the circuit board ..any idea

Why floating point numbe process than integer, Why floating point number mo...

Why floating point number more difficult to represent and process than integer? In floating point numbers we have to show any number in three fields sign, exponent and mantissa

What are the roll and page areas, What are the roll and page areas? Ro...

What are the roll and page areas? Roll and page areas are SAP R/3 buffers used to kept user contexts (process requests).  The SAP dispatcher assigns procedure requests to work

Software Engineering, Software Engineering is a layered technology. Explain...

Software Engineering is a layered technology. Explain

Explain resource request and allocation graph (rrag), Explain Resource requ...

Explain Resource request and allocation graph (RRAG) Deadlocks can be explained by a directed bipartite graph known as a Resource-Request-Allocation graph (RRAG).A graph G = (V

What does the term entrepreneurship mean, 1) What does the term entrepreneu...

1) What does the term entrepreneurship mean to you?  What are some basic characteristics of entrepreneurs? 2) What is e-commerce?  Why are the Internet economy and e-commerce he

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd