Skip to main content

Posts

Showing posts from April, 2010

Lightning

This summer temperature is setting new records... I think its because of "Global Warming", because last few summers temperature is increasing more n more. But yesterday there was raining in Pune. Following are some snapshots of lighting that I captured from my terrace

Using JTable

JTable is the component which helps us to display the multi columned data. This post is about fetching database data and displaying it using JTable. First we will design our Frame public class MyFrame extends JFrame {  private JTable table;  private JScrollPane jsp;  public MyFrame()  {   super("MyFrame");   setSize(400,400);   setDefaultCloseOperation(EXIT_ON_CLOSE);   setLocationRelativeTo(null);   initMyFrame();   setVisible(true);  }  private void initMyFrame()  {   setLayout(new BorderLayout());   table=new JTable();   jsp=new JScrollPane(table);   add(jsp,BorderLayout.CENTER);   // database connection and remaining code will go here  }  public static void main(String args[])  {   new MyFrame();  } }

Creating Simple Dll

This post is a tutorial for creating a simple dll in C++. So lets get started,  Create new project " SimpleDll " in Visual C++. If you are using Visual C++ 6.0 then select Dynamic Link Library Project and if you are using 2005 then select Win32 Project and select Dll and Empty Project in Additional options. After this add new header file " simpledll.h " to our project and add following code in header file . // SimpleDll.h #ifndef _SIMPLEDLL_H_ #define _SIMPLEDLL_H_ #include // this is the function which we will export VOID ShowMessage(WCHAR msg); #endif