Write an applet that display the directory holding html file, Computer Engineering

Assignment Help:

Write an applet that display the directory holding the HTML file that started the applet and the directory from which, applet class file was loaded.

An applet is here given below, which display the directory holding the HTML file which started the applet:

import java.awt .*;

import java.applet .*;    //import package

import java.net .*;

public class Base extends Applet

{

public void piant (Graphics g)

{

String msg;

URL url = getCodebase( );  / / string is initialize to be displayed.

Msg = "Code base:" +url . tost ring( );

g.drawst ring(msg,10,20);

URL url = getDocumentbase() ;

Msg = "Document base: " +url . tost ring();

g.drawst ring(msg,10,40);

}

}


Related Discussions:- Write an applet that display the directory holding html file

Challenges facing operations managers - information systems, Challenges Fac...

Challenges Facing Operations Managers - Information Systems While information systems should be seen as tools that enable better performance their implementation also brings a

Example of time division multiplexing, Two computers using TDM take up turn...

Two computers using TDM take up turns to send 100-bytes packet over a shared channel that operates at 64000 bits per second. The hardware takes 100 microseconds after one computer

The javascript validation not run on the asp.net, Why The JavaScript Valida...

Why The JavaScript Validation Not Run on the Asp.Net? The Asp.Net Button Is post backed on the server & not yet Submit & when it goes to the server its states is lost so if we

Illustrate decimal fixed point representation, Q. Illustrate Decimal Fixed ...

Q. Illustrate Decimal Fixed Point Representation? The point of this representation is to keep the number in decimal equivalent form and not binary as above. A decimal digit is

What is the difference among character and block devices, a. What is the di...

a. What is the difference among character and block devices? b. Discuss the method to make a Kernel Driver for the PC Speaker. c. Explain the socket structure with the help o

Interrupt - driven input-output, Q. Interrupt - Driven Input-output? Pr...

Q. Interrupt - Driven Input-output? Problem with programmed I/O is that processor has to wait a long time for I/O interface to see whether a device is free or waits until compl

Minimization of the logic function using k-maps, Minimize the logic functio...

Minimize the logic function F(A, B, C, D) = ∑ m(1,3,5,8,9,11,15) + d(2,13) using K-maps Ans. The logic function minimization of F(A, B, C, D) = ∑ m(1,3,5,8,9,11.15) + d(2,13) by

Proof by contradiction - artificial intelligence, Proof by Contradiction - ...

Proof by Contradiction - Artificial intelligence So, both backward chaining andforward chaining have drawbacks. Another approach is to think regarding proving theorems by contr

C++, pebble merchant

pebble merchant

Set up the minunit test framework - mortgage code, Set up the minunit test ...

Set up the minunit test framework examples in your environment (i.e. build or compile the code). Once you can run the example, use the minunit test framework to create and run a bo

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