beautypg.com

Setting up mig calendar for usage – MiG InfoCom MiG Calendar Getting Started Guide User Manual

Page 6

background image

MiG InfoCom AB

Setting up MiG Calendar for usage

Classpath
In order to use the calendar component your application

needs to find it. How to do this depends entirely on you

environment but normally you add it to your classpath,

possibly in the project settings in your IDE. The file to make

available is

migcalendar.jar

or

migcalendarbean.jar

.

Note! From v5.5 You should use

migcalendarbean.jar

for

development and

migcalendar.jar

for deployment. They

differ only by the fact that the latter has more information in

the file, such as all the property editors needed for visual

development.

migcalendar.jar

contains the whole

component but all the unnecessary information is removed to

provide the smallest possible file.

migcalendar.jar

is

about half the size of

migcalendarbean.jar

.

Add License Code
Since the product you are using is commercial it will need to

be fed a license code before it can be used. This license code

should be entered before any usage if the component is

commenced or the component will enter evaluation mode.
This is normally done in your application's

main(...)

method or some other place that is run very early in the

startup sequence. This is done like this

com.miginfocom.util.LicenseValidator.setLicenseKey(File/String/InputStream);

Setting up a Swing Application
I order to show the MiG Calendar component you will have to

create a a normal Swing application. How to do that is

outside the scope if this tutorial but it can be done in just a

few lines. See the Swing trail in the Java Tutorial at Sun

Microsystems site. It is currently located at:

http://java.sun.com/docs/books/tutorial/uiswing/index.html

The examples below will assume that you have a basic Swing

MiG Calendar Getting Started Guide

Page 6 / 31