Posts

Showing posts with the label Eclipse

Database Development Plug-in for Eclipse

Image
I found an Eclipse plug-in which can work with many databases, to help developers work more easily. To install the plug-in, please follow these steps. Go to “Help” menu and select “Install new software...” item. Select download site for each version. Wait for loading lists of plug-in. After the list loading is finished, check “Database Development” item. Click “Next >” until finish installation. Open “Database Development” perspective. In “Data Source Explorer” panel on the left hand side of the screen, right click on the “Database Connections” then click “New” item. Choose database you want to work with and fill the information.

ทำ Executable jar file ด้วย eclipse

Image
คลิกขวาที่ project ที่ต้องการทำ jar file แล้วเลือก export เลือก Java >> JAR file แล้ว Next เลือกที่ที่ต้องการจะ export โดยการ Browse… เลือกที่ แล้วตั้งชื่อ สามารถติ๊กถูกที่ export java source files and resources เพื่อให้ใส่ .java และ resources ต่างๆ ใน jar file ไปด้วย เสร็จแล้วกด Next > จะเจอหน้าแบบนี้ ให้กด Next > อีกที เจอหน้าสุดท้าย กด Next ต่อไปไม่ได้แล้ว ตรงช่อง Select the class of the application entry point: ให้กด Browse… แล้วเลือก Main Class ของ application ในที่นี้ผมมีคลาสเดียวชื่อ MainClass และมี main method อยู่ในคลาสนี้ เลยเลือกอันนี้ กด OK กด Finish เป็นอันเสร็จเรียบร้อย ได้ executable jar file มาแล้ว ลอง run เพื่อทดสอบ รันได้ ! เรียบร้อยครับ !!