Java Tutorial

/* <applet code=\"URLDemo\"   height=100 width=400> </applet> */

import java.awt.*;
import java.applet.*;

public class URLDemo extends Applet
      public void paint(Graphics g){
          String msg;

          URL url=getCodeBase();
          msg = \"Code Base : \"+url.toString();

          msg=\"Document Base : \"+url.toString();

    Related Post:
  1. Program to show an example of using a recursive method in a class

  2. Program to copy the elements of an array into another array in reverse order and print them

  3. An applet program to give demo of getDocumentBase() and getCodeBase() methods

  4. Program to show an example of Arrays of String

  5. Develop a CORBA based application for addition of two complex numbers and displaying the result on client side

  6. Corba program of Count Client Applet, IDL,Server, Client

  7. Program of UDP datagram

  8. Program to display reverse $ tree

  9. corba program of client and a DNS server where given a URL the server sends back an IP address

  10. Program to make directory

  11. Program of linear search

  12. Program to read input from the Standard Input Device

  13. Program to ask question and accept answer up to 3 attempt and display right answer if it is wrong

  14. Program to show the use of Switch Statement for the same statement for several different case labels

  15. An applet program that concatenates two string entered in TextField

  16. Program that enabled applet that takes name of the user. Server returns back the number in uppercase clubbed with “HELLO” and display it on applet

  17. Program that enabled applet calculator

  18. Program using session tracking capability of Servlets, which displays information of current user session by HttpServletRequest object

  19. RMI based application, which reads a file with list of marks of student from a client, send it to server and find how many students having distinct

  20. Program to show the use of Bitwise Operator (|) OR

Didn't find what you were looking for? Find more on An applet program to give demo of getDocumentBase() and getCodeBase() methods