Week #8 Challenge: Java in 52 Weeks Of Code

Written by kishore

[img]http://www.egscript.info/wp-content/uploads/2010/02/545ed6fa17footer.png.png[/img] [b][size=5]Week #8: Java[/size][/b]

[img]http://www.oracle.com/ocom/groups/public/@ocom/documents/digitalasset/044762.gif[/img]

[b]CHALLENGE:[/b]
Experience the Java programming language. For those of you C++ or .Net programmers out there, here's your chance to see what all Java fanatics love about Java [url="http://java.sun.com/docs/books/tutorial/"]Official tutorial[/url]
[url="http://www.dreamincode.net/forums/showforum50.htm"]Dream.In.Code tutorials[/url]
[url="http://www.dreamincode.net/code/browse.php?cid=6"]Dream.In.Code snippets[/url]

[b]HOW TO GET STARTED:[/b]
This is the best startup guide I think I've ever read:
http://java.sun.com/docs/books/tutorial/getStarted/index.html

All that you need is a text editor and the Java JDK. You can download the Java JDK from [url="http://java.sun.com/javase/downloads/widget/jdk6.jsp"]this link[/url]. You do not have to use a text editor. You can also use an integrated development environment(IDE) instead. With the IDE you will still need the Java JDK. Popular IDEs for Java are [url="http://java.sun.com/javase/downloads/widget/jdk_netbeans.jsp"]Net Beans[/url], [url="http://www.eclipse.org/downloads/download.php?file=/technology/epp/downloads/release/galileo/SR1/eclipse-java-galileo-SR1-win32.zip"]Eclipse[/url], and [url="http://www.jcreator.org/download.htm"]JCreator[/url].

Java is a completely Object-Oriented language. That means that everything and everything is a class and composed of objects. Here is the traditional “Hello World” program written in Java. When learning a new language the majority of people will write a program that will print “Hello World” on the screen. You should note that the name of the class your main method is in needs to have the same file name as the name of the class. In the example below, when you save your program, it must be named Hello.java for the program to work.

[code]
class Hello {
public static void main(String[] args) {
System.out.println("Hello World");
}
}
[/code]

[b]WHERE TO GO FOR HELP:[/b]
If you are in need of help with you Java programs, you can visit the [url=http://www.dreamincode.net/forums/showforum32.htm]Java forum[/url] here on DIC. The [url="http://www.dreamincode.net/code/browse.php?cid=6"]java code snippets[/url] and [url="http://www.dreamincode.net/forums/showforum50.htm"]java tutorials[/url] will help you in your challenge as well. The best resource for beginning with Java are the [url="http://java.sun.com/docs/books/tutorial/index.html"]Java Tutorials[/url] from Sun.

View original here:
Week #8 Challenge: Java in 52 Weeks Of Code

Feb
22

resize and save picture

Written by kishore

hey, i have used the following code to browse & upload a picture durin runtime

Private Sub cmdBrowse_Click()

Me.CommonDialog1.InitDir = “D:”

Me.CommonDialog1.Filter = “Graphic Files (*.bmp;*.gif;*.jpg)| *.bmp;*.jpg”

Me.CommonDialog1.ShowOpen

If Me.CommonDialog1.FileName <> “” Then Me.Image1.Picture = LoadPicture _
(Me.CommonDialog1.FileName)

End Sub

do you have any sample code i can use to save the picture (image1) into an access database called “tblHrData” field name “Picture”.
I would appreciate sample code to resize the picture to fit into the image box.thanks in advance

Regards

More:
resize and save picture

Feb
19