Monthly Archives: January 2012

Writing Your own Log Messages in java Logger

import java.io.*; import java.util.logging.*; public class QuintLog{ public static void main(String[] args) { try{ FileHandler hand = new FileHandler(“vk.log”); Logger log = Logger.getLogger(“log_file”); log.addHandler(hand); log.warning(“Doing carefully!”); log.info(“Doing something …”); log.severe(“Doing strictily “); System.out.println(log.getName()); } catch(IOException e){} } }

Rate this:

| Tagged | Leave a comment

Convert Set of Images into PPT Presentations Using Java

import java.util.*; import java.sql.*; import java.lang.Integer; import java.text.DecimalFormat; import java.io.FileInputStream; import java.io.*; import java.text.*; import java.awt.Color; import java.awt.image.BufferedImage; import java.io.File; import java.io.IOException; import javax.imageio.ImageIO; import javax.imageio.ImageIO; import java.awt.image.BufferedImage; import java.awt.Dimension; import org.apache.poi.hslf.usermodel.SlideShow; import org.apache.poi.hslf.model.Slide; import org.apache.poi.hslf.model.Fill; import org.apache.poi.hslf.model.Picture; import org.apache.poi.hslf.model.TextBox; … Continue reading

Rate this:

| Tagged | Leave a comment

Save bytes Image in the Application Server Using java

import java.util.*; import java.sql.*; import java.lang.Integer; import java.text.DecimalFormat; import java.io.FileInputStream; import java.io.*; import java.text.*; import java.awt.Color; import java.awt.image.BufferedImage; import java.io.File; import java.io.IOException; import javax.imageio.ImageIO; import javax.imageio.ImageIO; import java.awt.image.BufferedImage; import java.awt.Dimension; import org.apache.poi.hslf.usermodel.SlideShow; import org.apache.poi.hslf.model.Slide; import org.apache.poi.hslf.model.Fill; import org.apache.poi.hslf.model.Picture; import org.apache.poi.hslf.model.TextBox; … Continue reading

Rate this:

| Tagged | 1 Comment

How to Print System Security Information in Java

import java.security.Provider; import java.security.Security; import java.util.Set; import java.util.HashSet; public class SecurityProvider { public static void main(String[] args) { // // Create a set so that we can have a unique result. // Set result = new HashSet(); // // Returns … Continue reading

Rate this:

| Leave a comment

How to Implement PDF to Image Convertion in java

Step 1 : Download Required Library PDFRenderer-0.9.0.jar and Extract Current Directory or Set Class Path Step 2: Compile and Run Java code import com.sun.pdfview.PDFFile; import com.sun.pdfview.PDFPage; import java.awt.Graphics; import java.awt.GraphicsConfiguration; import java.awt.GraphicsDevice; import java.awt.GraphicsEnvironment; import java.awt.HeadlessException; import java.awt.Image; import java.awt.Rectangle; … Continue reading

Rate this:

| 4 Comments