nK0de's Profile User Rating: ****-

Reputation: 204 Stalwart
Group:
Contributors
Active Posts:
823 (0.86 per day)
Joined:
21-December 11
Profile Views:
41,046
Last Active:
User is offline Apr 16 2013 06:08 AM
Currently:
Offline

Previous Fields

Country:
LK
OS Preference:
Windows
Favorite Browser:
FireFox
Favorite Processor:
Intel
Favorite Gaming Platform:
PC
Your Car:
Who Cares
Dream Kudos:
25

Latest Visitors

Icon   nK0de in for the long run!

Posts I've Made

  1. In Topic: your life?

    Posted 28 Dec 2012

    View PostMartyr2, on 23 December 2012 - 11:27 PM, said:

    We can slam our heads against problems every day... but once you solve it you are on cloud nine.


    I had one of those moments just today! :D It really is a good feeling.
  2. In Topic: What show are you currently watching?

    Posted 28 Dec 2012

    I watch only 2 shows. I don't wanna start new ones 'cause if I do, I'd get hooked on and be tempted to watch every episode up to now in a stretch and that would hinder me from doing the important stuff I'm supposed to do.

    How I Met Your Mother - I'm starting to dislike this show. Too many break ups, make ups, pussy out during the last minute at weddings. I mean, wtf! It used to be a really god show.

    Game of Thrones - I fucking love this one! Can't wait for the Season 3! :)
  3. In Topic: ios apps work with sql type rdbms?

    Posted 20 Nov 2012

    SQLite is used in iOS devices as the backend database to store data.
  4. In Topic: Invoking events of a control defined inside a class

    Posted 5 Nov 2012

    Skydiver : I'm trying to invoke them from anywhere I use the class. I went with your second method an it works great! :D Modifying the constructor seems ugly indeed.

    tlhIn`toq : Thanks for that piece of information but this one I kinda have to do it in WinForms as this is for my work, not a personal project. :)
  5. In Topic: 'Cannot find symbol' error on setString method

    Posted 26 Oct 2012

    Yes. I hadn't declared an instance of PreparedStatement class.

    package learnjdbc;
    
    import java.sql.*;
    import javax.swing.*;
    
    public class NewJFrame extends javax.swing.JFrame {
    
        Connection con;
        Statement st;
        PreparedStatement pst = null;
        ResultSet rs;
    
        private void btnInsertActionPerformed(java.awt.event.ActionEvent evt) {
            
            con = DatabaseHandler.connectToDb(); //this method returns a connection object
            try {
                
                String author = "K.A. Applegate";
                pst = con.prepareStatement("INSERT INTO Authors(Name) VALUES(?)");
                pst.setString(1, author);
                
            }
            catch(Exception ex) {
                JOptionPane.showMessageDialog(null, ex.getMessage());
            }
            
        }
    }
    
    


    Now it works fine. Thank you both. :)

My Information

Member Title:
Catch me As Exception
Age:
23 years old
Birthday:
October 12, 1990
Gender:

Contact Information

E-mail:
Click here to e-mail me