Java TextFields, keyTyped Vs insertUpdate Events

It's been a while since I last posted, I have been spending a lot of my spare time on a java application where I came across a problem with the keyTyped() Event.

The task I was trying to achieve was to reproduce a similar feature to google suggest which was fairly straight forward simply using a Collection to store all my values and the Iterator to loop through each value checking against my search string which was retrieved using the getText() method and then matched against each value using the startsWith() method.

Installing and Programming with PHP and Java

As a web developer PHP has always been top of my list when it comes to programming but just recently with my studies Java has been my main language and as I have come to love Java I looked into ways of using both PHP and Java together.

While searching the internet I found a few different solutions to this, you are able to recompile PHP with java support on both windows and Linux but the easiest solution I found for the windows operating system was Java Bridge, combined with WAMP (Windows Apache MySql and PHP) I was already to go in a matter of minutes.

Display Your Visitors Location using Google Maps

If you have ever seen a map on a web site showing your location then you know what we are trying to achieve here. One of the easiest ways to do this is to use a data file provided by maxmind to look up the users IP address or a domain name / IP address the visitor entered, I will first explain the steps we need to take and the tools we will need and then a walkthrough of how to put it all together.

What you will need.

WAMP Server Problems, Yellow Symbol

If you have ever had a problem with your WAMP server where it will just not start and the icon in the windows notification area stays yellow then you will understand my frustration. After a bit of a search on google i still did not find the answer to my problem.

I started by checking the error logs from within WAMP and determined it was apache that was not starting, after finding apache in the Services under Adminstrative tools i was still unable to manually start apache. This is when i knew that another program must have also been using Port 80.

Geo Coding for Specific Landing Pages

I was asked yesterday by a website owner if it would be possible to discover where his users were coming from using IP addresses and redirect or show them different content accordingly. I remembered that I had accomplished a similar task only a few months ago using Maxminds geo locating data file to overlay on Google maps showing the location of peoples IP addres and providing reverse look ups of hostnames etc.

Note: if anyone would like this script just leave a comment and I will try and dig it out.

Overloading Methods and Constructors | Java

What is overloading?

Overloading is the term used when more than one method exists with the same name. It does not matter if the methods exist in the same class, or if one or both methods exist in the parent or child classes.

The compiler differentiates between the two methods using the methods parameters, specifically the order and the data types of the parameters. Therefore you could have two methods with the same name and two parameters as long as the data types were different or the same data types but in a different order.

Visual Basic - MinValue and MaxValue Properties

Today I was asked by a friend who is studying Visual Basic to write an article on the properties MinValue and MaxValue at first I thought these very simple properties were hardly worth an article but then I realised that when just starting out in programming it’s good to have examples of when these properties, could or should be used.

If we wanted to collect 10 scores of student’s exams results and then display the minimum and maximum score entered we could do so with the following code.

An Introduction to Visual Basic .NET 2008

Visual Basic .NET is an object orientated programming language which is a combination of Microsoft’s Visual Basic in conjunction with the .NET framework. VB .NET was designed by Microsoft to increase the development speed of GUI applications for the Windows platform.

Visual Basic was originally designed to be easy

to use and learn, while making the development of simple graphical programs easy, visual basic also offers many powerful features for the development of large and complex applications.