Write an applet program for displaying 3 different sentences with 3 different colors

Write an applet program for displaying 3 different sentences with 3 different colors

Write an applet program for displaying 3 different sentences with 3 different colors

View Answers

January 2, 2013 at 10:14 PM

import java.applet.*;
import java.awt.*;
/*
<applet code= colr width=500 height=500>
</applet>
*/
public class colr extends Applet
{
    public void paint(Graphics g)
    {
        g.setColor(Color.RED);
        g.drawString("Hello ",0,10);
        g.setColor(Color.BLUE);
        g.drawString("I am Chirag Viradiya",20,20);
        g.setColor(Color.ORANGE);
        g.drawString("from Surat,Gujarat.",40,30);
        g.setColor(Color.BLACK);
        g.drawString("[email protected]",60,40);

    }
}









Related Tutorials/Questions & Answers:
Write an applet program for displaying 3 different sentences with 3 different colors
Write an applet program for displaying 3 different sentences with 3 different colors  Write an applet program for displaying 3 different sentences with 3 different colors
connect 3 frameset to other 3 different frameset in html
connect 3 frameset to other 3 different frameset in html  first display the 3 frames in one html page after login it will display 3 differnt frame
Advertisements
connect 3 frameset to other 3 different frameset in html
connect 3 frameset to other 3 different frameset in html  first display the 3 frames in one html page after login it will display 3 differnt frame
dojo grid from 3 different sources
dojo grid from 3 different sources  I'm new with dojo. I need to get data from 3 different database tables and diplay them on the browser (maybe..., movie title, desc,... table #3 fields: username, firstName, lastName, user img
links with different colors.
links with different colors.  How can I have two sets of links with different colors
write those 3 questions (class)
write those 3 questions (class)  1) write a function minE which takes... an int k to minE and return the k smallest element.) 2) write a function rev which takes an array of integers and reverses it. 3) write a function isDistinct which
java program of different shapes
java program of different shapes  pls help me to get the code of a java program of different shapes using menu
Displaying different portions of a page subsequently on the basis of action
Displaying different portions of a page subsequently on the basis of action  Suppose in Report.jsp there are two text fields From Date: and To Date: with js calender beside these and a SEARCH Button(When the page initially loads
different borders
the different colors. . Code description  The package we need to import... different borders       In this program we are going create a sheet  after that 
how to mark different colors for diffent rows - Java Beginners
how to mark different colors for diffent rows  Hi, i have drawn a simple table using swings and now i want to mark diffent colors for each row..............my target is to have each color for each row.......first row
how to mark different colors for diffent rows - Java Beginners
how to mark different colors for diffent rows  Hi frends, Actually yesterday i had a question that, how can i mark colors to my rows in the table using swings.............one of my frend posted the solution also
Here is a set of 18 different shades of one of the most favourite Choclate colors
; padding:5px 0px 5px 5px; } Here is a set of 18 different shades of one of the most favourite choclate colors rangeing from light choclate color to darker... Chocolate 3 #542A0C Chocolate 4 #69340F
Here is a set of 26 different shades of one of the most favourite Red colors
:5px 0px 5px 5px; } Here is a set of 26 different shades of one of the most favourite Red colors rangeing from light Red color to darker Red color... #FF0000 Red 2 #F80000 Red 3 #F00000 Red 4
3
This is a set of 18 different shades of DarkSalmon colors covering lighter DarkSalmon color to darker DarkSalmon color.
:5px 0px 5px 5px; } This is a set of 18 different shades of DarkSalmon colors covering lighter DarkSalmon color to darker DarkSalmon color... #E9967A DarkSalmon 2 #EBA087 DarkSalmon 3 #EDAB95
Write an applet program to transfer the content of the text field into the component on clicking a button
Write an applet program to transfer the content of the text field into the component on clicking a button  Write an applet program to transfer the content of the text field into the component on clicking a button
Spring 3
Spring 3  Hi I want to know how to write code Spring 3 for registration and login pages with help of data bse.Please help me I am new to Spring
This is a set of 26 different shades of brown colors covering light brown to darker brown.
:5px 0px 5px 5px; } This is a set of 26 different shades of brown colors... Brown 3 #79443B Brown 4 #964B00
Set Different Color to different row in Java Program
Java Set Different Color to different row In this section, you will learn how to set different color to table row using java swing.For this purpose, we have.... This class provides the method setBackground() which allow us to set different
Different JRE
Different JRE  Java is platform independent. The why different JRE's there for differen operating systems
Here is a set of 26 different shades of one of the most favourite Orange colors rangeing from light Orange color to darker Orange color.
:5px 0px 5px 5px; } Here is a set of 26 different shades of one of the most favourite Orange colors rangeing from light Orange color to darker Orange color... Orange 1 #FF7F00 Orange 2 #FFBF00 Orange 3
Here is a set of 26 different shades of one of the most favourite Pink colors rangeing from light Pink color to darker Pink color.
:5px 0px 5px 5px; } Here is a set of 26 different shades of one of the most favourite Pink colors rangeing from light Pink color to darker Pink color... #FFCBDB Pink 2 #F19CBB Pink 3 #FB607F
Web 3
been coined with different meanings to describe the evolution of web usage
3 Java Programs for Beginners
3 Java Programs for Beginners  Write a program that prompts the user for 2 different integers, then prints out the numbers between the 2 integers (inclusive) and their squares and the sum of their squares. Write a program
help me 3
help me 3  write aprogram in java using two dimentional array.Accept the two dimentional array from the user and perform addition and subtraction of these two arrays and display the result for each add and subtruct
html page viewed on different os
html page viewed on different os  The colors on my page look different when viewed on a Mac and a PC
applet program code - Applet
applet program code  hello sir, i did't get the code for below problem... please help me... 1.An applet program to draw a line graph for y=2x+5.[for suitable values of x & y
Applet program
Applet program  Write a java applet for the following case- The hotel Maharaja provides the facility to its customers to select any one room (from.... 100. All above charges are applicable per day basis. The applet will display
ModuleNotFoundError: No module named '3'
ModuleNotFoundError: No module named '3'  Hi, My Python program is throwing following error: ModuleNotFoundError: No module named '3' How to remove the ModuleNotFoundError: No module named '3' error
JSP Tutorials - Page 3
JSP Tutorials - Page 3
C++ question 3
C++ question - add the two matrices and display the elements of resultant matrix.   Write a program to accept from user elements of two 2x3 matrices. Then add the two matrices and display the elements of resultant matrix
3 RADIO BUTTONS
3 RADIO BUTTONS  3 RADIO BUTTONS USING ALSO ONE RADIO CLICKING HOW TO PROCESS OF NEXTPAGE
DIFFERENT PAGES FOR DIFFERENT USERS ACCORDING TO THEIR ROLE
DIFFERENT PAGES FOR DIFFERENT USERS ACCORDING TO THEIR ROLE  I HAVE A PROBLEM IN PHP CODING PLS HELP ME PROBLEM IS THAT I WANT DIFFERENT PAGES TO VIEW FOR DIFFERENT USERS WHEN THEY LOGIN ACCORDING TO THEIR ROLE IN DATABASE
Entity Relationship Diagram 3
Entity Relationship Diagram 3  Task 3 Activities: Identify all entities and attributes from the given scenario. Draw entity relationship diagram... no, a name, an age, and a degree program(e.g BS, MSC). ? Each professor must
3 queries on java class
3 queries on java class  Hey. I need to do 3 queries on same class ( JAVA) One is to populate the combobox, the another one to populate tje jlist and the last one to use on button to open a file from database (BLOB) Can some
Transaction in last 3 months
Transaction in last 3 months  I have a project in which i have to calculate amount submitted through transactions in last three months. I have... submitted. What query can i use to get all the transactions in past 3 months starting
@configuration annotation in Spring 3
@configuration annotation in Spring 3  doesn't make code tight coupling..? if we keep that in IOC in XML form, its deployment free for some kind of change management right?.   Please visit the following link: http
How to write a simple java applet
How to write a simple java applet   Hi, how can i write a simple java applet, displaying text in specific colors and font style. For example... ShowsTextExample extends Applet{ public void paint(Graphics g){ g.setColor
machine learning in 3 months
machine learning in 3 months  Hi, I am beginner in Data Science... learning in 3 months Try to provide me good examples or tutorials links so that I can learn the topic "machine learning in 3 months". Also tell me
What are the 3 types of AI?
What are the 3 types of AI?  Hi, I am beginner in Data Science... are the 3 types of AI? Try to provide me good examples or tutorials links so that I can learn the topic "What are the 3 types of AI?". Also tell me which
The Life cycle of An Applet
of an applet and different methods of an applet. Applet runs in the browser and its... into the first program or Applet. destroy() method: The destroy() method... The Life cycle of An Applet     
problem 3 = C#
C# program for grading system   Create a C# program for the following scenario: The grading system of a college is as follows: Marks : 80 -100 display "Distinction" 70 - 80 "Very Good 60 - 70 "Good" 50 - 60 "OK
an overview of ejb 3
An overview of EJB 3. As we know that EJB architecture has failed in keeping the promise of increased productivity whereas EJB 3.0 has succeeded in doing so. It has reduced the complexity for the developers. It has succeeded in reducing
applet program
applet program  applet to simulates a traffic signal light with short delay between states
ftech different value corresponding different value
ftech different value corresponding different value  in my dropdown two options are their and i want when i select any option the corresponding value that go in the database should be different. for eg. in my drop down
size of different basic data types
size of different basic data types   Write a simple program to find the size of different basic data types in java
different JDBC drivers available
different JDBC drivers available  What are the different JDBC drivers available
different kinds of actions in Struts
different kinds of actions in Struts  What are the different kinds of actions in Struts
java program to take the backup of folders and copy the folder in different location without deleting the existing one
java program to take the backup of folders and copy the folder in different location without deleting the existing one  java program to take the backup of folders and copy the folder in different location without deleting
Different between getRequestParameterMap() and getRequestParameterValuesMap()
Different between getRequestParameterMap() and getRequestParameterValuesMap()  What is the different between getRequestParameterMap() and getRequestParameterValuesMap

Ads