Computer Quiz

Computer Quiz Contact information, map and directions, contact form, opening hours, services, ratings, photos, videos and announcements from Computer Quiz, Computer Company, Hyderabad.

14/06/2016

// SHOW IMAGE IN FRAME...
import javax.swing.*;
class Example
{
JFrame frame;
JLabel image;
Example()
{
frame=new JFrame("Show Image");
frame.setSize(500,500);
frame.show();
frame.setLayout(null);
//path of image with image name
image=new JLabel(new ImageIcon("picture.jpg"));
frame.add(image);
//setBounds(int x_axies , int y_axies , int width , int height)
image.setBounds(50,50,400,400);
}
public static void main(String args[])
{
new Example();
}
}

14/06/2016

//VERY INTERESTING : TRY IT
import java.awt.*;
import javax.swing.*;
import javax.swing.JColorChooser;
import javax.swing.border.Border;
class colorchooser
{
JColorChooser cc;
JFrame f;
colorchooser()
{
f=new JFrame("colorchooser");
Border br = BorderFactory.createTitledBorder("Color Chooser");
cc=new JColorChooser();
f.add(cc);
cc.setBorder(br);
f.setVisible(true);
f.setSize(600,500);
}
public static void main(String args[])
{
new colorchooser();
}
}

14/06/2016

// FRAME INSIDE A FRAME
import java.awt.event.*;
import java.awt.*;
import javax.swing.*;
public class A1 extends JFrame implements ActionListener
{
JButton b;
JInternalFrame fr;
A1()
{
setLayout(null);
setSize(800,800);
show();
fr = new JInternalFrame("internal",true,true,true,true);
add(fr);
fr.setSize(300,300);
b=new JButton("click");
add(b);
b.setBounds(30,30,80,30);
b.addActionListener(this);
}
public void actionPerformed(ActionEvent e)
{
fr.show();
}
public static void main(String[] args)
{
new A1();
}
}

14/06/2016

// IMAGINATION to make GAME for BEGINNERS
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
class AA implements KeyListener
{
JFrame fr;
JPanel p1;
JButton b1,b2;
AA()
{
fr=new JFrame();
b1=new JButton("");
fr.add(b1);
b1.setBounds(10,10,20,20);
b1.addKeyListener(this);
fr.setLayout(null);
fr.setSize(500,500);
fr.show();
}
public void keyTyped(KeyEvent e)
{
}
int x=10;
int y=10;
public void keyPressed(KeyEvent e)
{
int c=e.getKeyCode();
if(c==KeyEvent.VK_RIGHT)
{
x+=10;
b1.setBounds(x,y,20,20);
System.out.println(c);
}
else if(c==KeyEvent.VK_LEFT)
{
x-=10;
b1.setBounds(x,y,20,20);
System.out.println(c);
}
else if(c==KeyEvent.VK_UP)
{
y-=10;
b1.setBounds(x,y,20,20);
System.out.println(c);
}
else if(c==KeyEvent.VK_DOWN)
{
y+=10;
b1.setBounds(x,y,20,20);
System.out.println(c);
}
}
public void keyReleased(KeyEvent e)
{
}
public static void main(String atgs[])
{
new AA();
}
}

20/12/2015

main( )
{
int a=printf("\n hello ");
printf("%d",a);
}
A.hello7
B. hello6
C. hello8
D. hello9

19/09/2015

Program under ex*****on is called ?
A . process
B . i/o program
C . processing
D . interrupt

05/09/2015

JVM full form ?

02/09/2015

What is the first browser to run the Applet window ?
A . Java hot
B . Hot java
C . Sun java
D . Micro java

02/09/2015

What is the method to create a folder in java ?
A . mkdir()
B . makeDirectory()
C . makeFolder()
D . showFolder()

28/08/2015

Which type of code is used in Assembly Language ?
A . Binary
B . Pseudo
C . Ascii
D . Unicode

11/07/2015

//what is the output ?
class static
{
static {
System.out.print("JAVA");
}
public static void main(String args[])
{
}
}

07/07/2015

How to Format USB Pen Drives Using Command Prompt to Delete Viruses Permanently Posted by dhrumil shah When you're using a pen drive to transfer data between PCs, the common problem is viruses. You might format your pen drive many times because of viruses. Some kind of viruses never get delete by normal formatting. Are you disappointed of the result that you get after formatting your pen drive and still find viruses in it? Here I'll give you a solution to format your USB pen drive completely. You can format pen drives using command prompt to remove all the virus files permanently. Most of the times these type of formats delete all the viruses from pen drive. So let's see how to format your pen drive using command prompt. Insert pen drive into your PC Find the drive letter of the pen drive Now click on Start ---> Run In run box, type cmd and hit Enter Now command prompt will appear, in this window type format "your pen drive letter:" For example type : format g: Hit Enter twice Wait for sometime until command prompt verify the file system. Now command prompt will ask you to enter a drive name. After that type the drive name and then hit Enter again. That's all, you have done !!!

Address

Hyderabad

Telephone

9154929850

Website

Alerts

Be the first to know and let us send you an email when Computer Quiz posts news and promotions. Your email address will not be used for any other purpose, and you can unsubscribe at any time.

Contact The Business

Send a message to Computer Quiz:

Share