Wednesday, July 26, 2006

Screen Mailer at SourceForge.net

Well... Well... My first project at Sourceforge... "Screen Mailer"... What's it?? As its name implies, it mails the screen... As some people asked me, why a person on this earth would need such a thing since there is a screen capture button available on the keyboard?? Well... There's a reason... Imagine you are in a environment which you are involved in a software related stuffs, where you will have to frequently contact support personals in case of errors and where you have to e-mail the screenshot to systems admin. So what you'll have to do is, taking the screenshot using keyboard and pasting that image to a image editor and save the image and then open-up a new mail compose window and attach the image file and then send the email to the relevent personal. Whole lot of work yeah?.. So why bother when you have ScreenMailer? It does all what you've done earlier.. All you have to do is simple initial configurations and it'll take care of your screen mailing problems.. just 1-2 clicks would do the work with ScreenMailer. Screenmailer is hosted at

www.sourceforge.net/projects/screenmailer

you can get your own copy of screen mailer as a exe or as a installer. You can get the source code of the ScreenMailer too. (Via CVS or Files section). Your comments are highly appreciated.

/Cheers,
-MadGuy

Wednesday, June 07, 2006

MadGuy's All New GUI Builder

I've been working on some interesting project for around two days. Actually it's just an applet. Wanna know what it is? Just go to following address and you'll get to know what it is.. :D

www.freewebtown.com/thushara/

All java folks out there.... You may use this applet to quickly build up a simple interface for your java programs.. But no layout managers though.. Even though i started this for a buyer who interested in this, i would work further on this project.. (Probably i will continue this at SourceForge.net.).. So keep your fingers crossed..

/Cheers,
-MadGuy

Friday, May 26, 2006

My Forthcoming Tech Posts at www.java-tips.org

This is just an announcement about my forthcoming post on the net. I've been chosen write tips for www.java-tips.org and I'll be writing tips about java.util.prefs API. Those tips will appear on that site in about 2 weeks time. I expect that you all will read those tips and send me comments on my work.

MadGuy Rules!

Cheers!
-MadGuy

Wednesday, May 24, 2006

Freelance Programming

Hay guys and gals out there,

Sorry about keeping quite during last few months. Well.. Today i'm not gonna write any tech article. Instead i though of telling you a way to earn some money.. :D

There are several websites out there which you could do some contact work as a programmer/graphics designer/document writer. During last few months i've been working on such a site and yes, i got paid. And now i can guerentee that's a 100% reliable website coz i got the money. You guys can also check that out. Just goto

www.rentacoder.com

and you can earn some pocket money.. :D

Do the best... Earn money... Have fun...

Cheers!
-MadGuy

Thursday, March 09, 2006

JDBC - ODBC

When you write a database application using Java, Most of the times your first choice is MS-Access. There is a reason for it. That is the easiness of handling the database. But when you connect to an Access database, there's something which bother you every time. That is setting up the ODBC data source in the windows control panel. There could be times that you tried to write you own installer for you java database application, but couldn’t automate the entire process, due to the problem of manually configuring ODBC source.

But here, I’ll show you how to automate it.


When you connect to a database using Java, you call the following statement, which returns a connection to the specified database.

Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
DriverManager.getConnection(DATABASE, USERNAME, PASSWORD);

Old Technique
If your database is an Access database, you parameter for DATABASE is something like this.

"jdbc:odbc:test";

Here, you have to go to control panel and set an ODBC data source called "test".

New Technique
In the way I’m going to tell you, you don’t have to set any ODBC data source. Just pass the following string as your DATABASE.

"jdbc:odbc:;DRIVER=Microsoft Access Driver (*.mdb);DBQ=C:\\testing folder\\test.mdb";

If the database is in your working directory, simply call following.

"jdbc:odbc:;DRIVER=Microsoft Access Driver (*.mdb);DBQ=test.mdb";

In this way, you can directly connect to the Access database you specified, without bothering about configuring ODBC.

That's how I do it.

/Cheers,
-MadGuy

Tuesday, March 07, 2006

Hacking hotmail / Yahoo?

Wel.. Wel.. 120+ page views in just 5 days. Thx for staying in touch with Developer Paradise. This time, i thought of writing an article which can be useful to everyone, instead of writing any technical article.

If you are a novice hacker, you are in a position of believing everyone who declares them selves as hackers. (That’s the general scenario). As soon as you query a search engine for information about hacking a web mail service, you will get a huge list of links. More often you’ll see articles like this.

By countinuing on down this letter you agree that Hack_Attack69 will not be held responsible for any misuse of information within these pages. This letter is purely for educational use. It your intensions are similar, proceed. But if not, you will be held responsible for your own mistakes.

Hello Hotmail users. There have been many attemps to hack www.hotmail.com. Unfortunately all of them have failed, Except this one. I found out a revolutionary way to hack hotmail. This took 8 months to me. After 8 months of research, i found the broken link. AdminPassBot to be exach. AutoPassBot@hotmail.com is a bot, an auto bot. You send it a letter and within a week it will send you one back. the ULTIMATE hack for hotmail is as follows.

First, send a letter to AdminPassBot@hotmail.com, second within the subject heading place, the word "password". This way the automated bot rcognizes what you are after. Then in the content text field place the name of the person at hotmail you want to hack (dont put @hotmail.com after their name). Then skip three lines and place your own hotmail account information suchas,
My login : My password

This way the bot can verify that your accout actually exists and then supplies you with the password for the person's account that you want it for. Here's an example :

To: AdminPassBot@hotmail.com
bcc:
cc:
Subject: Password

login of the person you want to hack.

your login : your password


Use with care.
Thank you.
So, What's wrong with this? That's your problem right? I'll tell you the problem. As pointed out at the hacking article, there's no such bot called "AdminPassBot@hotmail.com" in the hotmail server. AdminPassBot@hotmail.com is just a email address, which is belong to the author of that article. So what he indend to do is let you feel that this is a true bot and get a mail from you with your login name and password. As mentioned in the article, in a week, you will not get any reply to your mail. But instead of that you'll realize that the access of your email account is no longer in your hand. That point onwards, the hacking article author will take care of your email account. :D.

So, Dont get trapped into any fake article like this. Dont forget that internet is very useful but dangerouse place. (Dont worry. Developer Paradise is one of the safest places. Hehe).

/Cheers,
-MadGuy

Friday, March 03, 2006

Creating Your Own RSS Feed

Most of you must be familiar with the term RSS which stands for Really Simple Syndication. Have you ever thought of how to write your own RSS feed? Did you say NO!!! C'mon It's simple. Let me show you how to create a simple one.

Basics of RSS
A RSS feed contains what are reffered as Items. Each item contains an title, description and a link to the source. The title and description should be written to describe the content and the link should reference the webpage that contains the actual content.

RSS is a flavor of XML. Like html, the xml file uses open and close tags to designate the title, description and link. Tags are enclosed in brackets <>, like standard html and the close tag contains a forward slash /.

An RSS feed is a series of items, which are chained together to creae what is called a "Channel".

Writing the RSS feed
The following is what an item in a xml file looks like:
<item>
<title>Generating Excel Files With JSP</title>
<description>This article shows how to create an Excel file using JSP.</description>
<link>http://developerparadise.blogspot.com/2006/03/
generating-excel-files-with-jsp.html</link>
</item>


The channel appears at the top of the file and tells people how the items relate to each other. Just like items, channels also use title, description, and link tags to describe it's content. The open channel tag occurs before the first item and the closing channel tag occurs right after the last item.
<channel>

<title>Developer Paradise</title>
<description>The place for techies</description>
<link>http://developerparadise.blogspot.com</link>

<item>
<title>Generating Excel Files With JSP</title>
<description>This article shows how to create an Excel file using JSP.</description>
<link>http://developerparadise.blogspot.com/2006/03/
generating-excel-files-with-jsp.html</link>
</item>

</channel>

Finally you will need to designate the file by indicating it is an XML file by inserting following xml and rss definition tags at the beginning and at the very end.

<?xml version="1.0"?&#62;
<rss version="2.0"&#62;


The completed RSS feed will looks like this.

<?xml version="1.0"?&#62;
<rss version="2.0"&#62;

<channel>

<title>Developer Paradise</title>
<description>The place for techies</description>
<link>http://developerparadise.blogspot.com</link>

<item>
<title>Generating Excel Files With JSP</title>
<description>This article shows how to create an Excel file using JSP.</description>
<link>http://developerparadise.blogspot.com/2006/03/generating-excel-files-with-jsp.html</link>
</item>

<item>
<title>Changing screen resolution using Delphi</title>
<description>This article shows how to build a small program to change your screen resolution.</description>
<link>http://developerparadise.blogspot.com/2006/03/changing-windows-resolution-using.html</link>
</item>

</channel>

</rss>


As my math teacher used to say, check your work! Once your file is complete and uploaded enter it into the feed validator at http://feedvalidator.org to check your syntax.

Viewing the RSS
Now you any RSS viewer such as "Feed Reader" or "Google Desktop" to view your RSS feed.

Oh... Forgot to say.. you must save the RSS file using .RSS extension or .XML extension.

That's all.. Let your friends read your website updates via RSS.

Have fun!

/Cheers,
-MadGuy

Thursday, March 02, 2006

Generating Excel Files With JSP

When browsing through the web, sometimes, you might see web pages which generate and show reports in MS Excel file format. If you are a web developer, you might be aware of how to do this or you might be lost in web searching for a method to get this done. If you belongs to the second set, then you are now in the right place. If you know what JSP is and how to setup a server like Apache Tomcat and familiar with HTML, then it's more than enough for you to get this done. All you have to do is, putting the following line of code in you JSP page, right before the BODY tag.

< %
response.setContentType("application/vnd.ms-excel");
% >

**Note that the server must have MS Excel installed in it.

After putting the above lines of code, jsut proceed with your usual HTML coding.

When requesting your page from the server, it'll not be a HTML page anymore... It'll be a MS Excel Document!..

Bravo!

/Cheers,
-MadGuy

Changing Windows Resolution Using Delphi

Some might be wondering how people write massive programs. Well.. Most of the time, it's not just about the skills of the programmer, But also the features of the OS and the development language + tools. Well.. If you ever wanted to write a small program to change the screen resolution of your windows machine but you failed, you may be wondering about what i'm gonna say... Actually, with delphi, changing the resolution of your computer is just few lines of code.. Even if you are a stranger to delphi, you may be able to easily get the program working. You want to see the code??? Ok, here it is.

var
lpDevMode : TDeviceMode;
begin
EnumDisplaySettings(nil, 0, lpDevMode);
lpDevMode.dmFields:=DM_PELSWIDTH or DM_PELSHEIGHT;
lpDevMode.dmPelsWidth:=XRes;
lpDevMode.dmPelsHeight:=YRes;
ChangeDisplaySettings(lpDevMode, CDS_UPDATEREGISTRY );
end;


Just try it yourself.

Anyway, i've uploded a sample project along with the application. Just have a look.
http://rapidshare.de/files/14482738/Resolution_Changer.zip.html

Have Fun!

/Cheers,
-MadGuy

Mapping Folders to Virtual Drives

Any of you ever wanted to map your favourite folders as physical drivers in windows? so you can access the folder as a hard disk? Well.. Here's the way, just for you to create a virtual hard disk.

1. Choose the folder which you want to map.

2. Go to command prompt

3. Type the following line of code.
Subst [drive1: [drive2:]path]

4. Here, drive1 is the drive which you are about to create. drive2: is the drive which your destination folder exist and the path is your destination folder.

5. As an example, you can map c:\test folder to a virtual drive as follows.
Subst s: c:\test

6. If you want to remove the virtual drive, type the following code.
Subst drive1: /d

7. For an example, if you want to remove the drive which we created earlier, you can do it as follows.
Subst s: /d

Interesting... Huh??

/Cheers,
-MadGuy