How to Set an Image as Background to a Frame
After all component settings, create an ImageIcon object with your desired image. Using this object, create a JLabel. Add the Jalbel to the lowest LayeredPane of the JFrame. Finally, add
After all component settings, create an ImageIcon object with your desired image. Using this object, create a JLabel. Add the Jalbel to the lowest LayeredPane of the JFrame. Finally, add
A default ResultSet object is not updateable and has a cursor that moves forward only. Thus, it is possible to iterate through it only once and only from the first
Normally, you should not check for null after creating an object. MyObject o = new MyObject(); This check is not required in Java because ‘new’ is not allowed to return
A rule of thumb in class design says that if a class has at least one virtual function, it should have a virtual destructor, too. This is because the presence
I have a much simpler form for the IsAlphaNum function: Public Function IsAlphaNum(ByVal sString _As String) As BooleanIf Not sString Like “*[!0-9A-Za-z]*” _Then IsAlphaNum = TrueEnd Function You can modify
Although VB has an IsNumeric function, it has no IsAlpha function. Use this routine whenever you want to determine whether a character or string of characters is alphabetic (A-Z or
This can be done by using ResultSetMetaData. For example, to get the number of columns you can use: /* get the meta-information about the result set */ResultSetMetaData metaData = rs.getMetaData();
This routine performs the standard column sorting on a ListView control found in many commercial applications, such as Windows Explorer and Outlook. Using this routine, the ListView sorts itself automatically
Traditional testing for alphabetic characters