Wednesday, April 22, 2009

Inheritances of child of God

As told in TPM CHURCH, ROYAPETTA 20-APR-2009 SUNDAY SERVICE

I Kings 21: 1-3
"And Ahab spake unto Naboth, saying, Give me thy vineyard, that I may have it for a garden of herbs, because it is near unto my house: and I will give thee for it a better vineyard than it; or, if it seem good to thee, I will give thee the worth of it in money.
And Naboth said to Ahab, The LORD forbid it me, that I should give the inheritance of my fathers unto thee"

Here we can see that Ahab is asking for an inheritance that belongs to Naboth and he is reluctant to sell it to him.In this passage we can compare Ahab to worldly pleasures and Naboth to spiritual life. For a child of God,whenever he is away from the presence of God, the worldly pleasures will ask to turn our inheritance to a garden of Herbs.

If you are a true child of God, you should not allow to convert your Fathers inheritance to a garden of hers. You should be ready to put your head for keeping it safe.

Here we can see the five inheritance possessed by a child of GOD

Anointing of Holy Spirit

Eph 1:14 : "ye were sealed with that holy Spirit of promise,Which is the earnest of our inheritance until the redemption of the purchased possession, unto the praise of his glory".

The gift of holy spirit is an inheritance of a child of God. You should preserve it till your end.In Eph 4:31, we will find the things which will devil bring to our life to destroy our inheritance of HolySpirit "Let all bitterness, and wrath, and anger, and clamour, and evil speaking, be put away from you, with all malice"
We aware of all the loop holes which devil brings in our life and preserve our inheritnace of Holyspirit.

HolyChurch

Psalms 16:6 "The lines are fallen unto me in pleasant places; yea, I have a goodly heritage". What is this pleasant place? The Holy consecration which the Lord brings us by his mercy is one of our inheritances. In our consecration
we have 5 officers, 9 gifts and 8 ministers. The Lord has given us saints who will teach us the path to Zion and Jerusalem and also we have a wonderful fellowship with the children of God.

As the brothers of Joseph told to him as in Gen 42:10, we are the children of one father. Jesus is our father and we are his children.
Preserve this inheritance of Concegration till the end.

Fellowship with saints

Colossians 1:12 "Giving thanks unto the Father, which hath made us meet to be partakers of the inheritance of the saints in light", Yes, the wonderful fellowship God has given to us with the saints of god is an inheritance.

Lord is my inheritance

Psalms 14:5 "There were they in great fear: for God is in the generation of the righteous". Jesus is our father and we are his children. All that belonging to Jesus is our inheritance. Zion is our inheritance, Jerusalem is our inheritance.

The Devil will try to separate us from our God. But we should be ready to say that "Who will separate me from my Lord, God?"

If you are able to preserve all the above 4 inheritance then

Eternal inheritance

Heb 9:15 "And for this cause he is the mediator of the new testament, that by means of death, for the redemption of the transgressions that were under the first testament, they which are called might receive the promise of
eternal inheritance." .

The lord is preparing an eternal inheritance for us. There will not be any sorrow or tears we
Will live with our God for years and years.
Are u prepared for the eternal inheritance?
We should be like the merchant as in Mathew 13:46 "Who, when he had found one pearl of great price, went and sold all that he had, and bought it.". We have found one pearl of great price. That pearl is Jesus Christ , who gave his young blood for saving the mankind from sin.

Be ready to meet Our Lord in Mid-air?

Tuesday, April 21, 2009

Programmatically sending Lotus Notes UI Memo thorugh back-end code

I have faced a small problem while trying to send a mail thru back-end which is currently opened in the workspace. I have to sent the mail and have to close the ui window as if it were sending thru clicking the normal 'Send' button. The problem is when I am using uidoc.close(), the client will give the send dialog at the front end, which is very awkward.

I used the following workaround for avoiding this problem and silently closing the memo after sending it thru back-end.

Call uidoc.Send()
'during closing to avoid asking for confirmation
'do a backend save and close it.
Set doc = uiMemodoc.Document 'get the back-end handle
Call doc.Save(True,False) 'save it
Call doc.ReplaceItemValue("SaveOptions",0)
Call uiMemodoc.Close() 'now it wil close without any dialog box

SWT Designer Tool

While designing some SWT application, I came across a designer tool which seems very helpful for creating complex application in quick time.

www.instantiations.com/

They provide a free license version, if you are interested you can also buy from them

Code for implementing the drop functionality in SWT tree

Below is a small snippet for code for implementing the drop functionality in SWT tree

int operations = DND.DROP_DEFAULT | DND.DROP_COPY | DND.DROP_LINK | DND.DROP_MOVE;
DropTarget target = new DropTarget(tree, operations);
target.setTransfer(new Transfer[] { FileTransfer.getInstance() };);
target.addDropListener(new DropTargetAdapter() {

public void drop(DropTargetEvent event) {
File f = new File (event.item)
TreeItem item = new TreeItem (root, 0);
item.setText ("item");
item.setData (f);
}

File drag functionality for a tree in SWT

Below is a small snippet of implementing file drag functionality for a tree in SWT

int operations = DND.DROP_DEFAULT | DND.DROP_COPY | DND.DROP_LINK | DND.DROP_MOVE;
DragSource dragSource = new DragSource(tree, operations);
Transfer[] types = new Transfer[] { FileTransfer.getInstance() };
dragSource.setTransfer(types);
dragSource.addDragListener(new DragSourceListener() {

TreeItem[] dndSelection = null;
String[] sourceNames = null;

public void dragStart(DragSourceEvent event) {
dndSelection = ExporttargetTree.getSelection();
sourceNames = null;
event.doit = dndSelection.length > 0;
}

public void dragFinished(DragSourceEvent event) {
dndSelection = null;
sourceNames = null;
}

public void dragSetData(DragSourceEvent event) {
if (dndSelection == null || dndSelection.length == 0)
return;
if (!FileTransfer.getInstance().isSupportedType(event.dataType))
return;
for (int i = 0; i <>
File file = (File) dndSelection[i].getData();
sourceNames[i] = file.getAbsolutePath();
}
event.data = sourceNames;
}
});

File drag functionality for a tree in SWT

Below is a small snippet of impementing filedrag functionality for a tree in SWT

int operations = DND.DROP_DEFAULT | DND.DROP_COPY | DND.DROP_LINK | DND.DROP_MOVE;
DragSource dragSource = new DragSource(tree, operations);
Transfer[] types = new Transfer[] { FileTransfer.getInstance() };
dragSource.setTransfer(types);
dragSource.addDragListener(new DragSourceListener() {

TreeItem[] dndSelection = null;
String[] sourceNames = null;

public void dragStart(DragSourceEvent event) {
dndSelection = ExporttargetTree.getSelection();
sourceNames = null;
event.doit = dndSelection.length > 0;
}

public void dragFinished(DragSourceEvent event) {
dndSelection = null;
sourceNames = null;
}

public void dragSetData(DragSourceEvent event) {
if (dndSelection == null || dndSelection.length == 0)
return;
if (!FileTransfer.getInstance().isSupportedType(event.dataType))
return;
for (int i = 0; i <>
File file = (File) dndSelection[i].getData();
sourceNames[i] = file.getAbsolutePath();
}
event.data = sourceNames;
}
});

Code for selecting/de-selecting the main checkboxes in the tree SWT

Below is a small snippet of code for selecting/de-selecting the main parent checkboxes in the tree

TreeItem[] itm = tree.getItems();
for(int i =0; i <>
//selecting parent items
itm[i].setChecked(true); //use false for de-selecting
}

Code for selecting/de-selecting the checkboxes in the child items of tree SWT

Below is a small snippet of code for selecting/de-selecting the checkboxes in the child items of tree

TreeItem[] itm = tree.getItems();
for(int i =0; i <>
//getting the child items for the parent items
TreeItem[] childItm = itm[i].getItems();
for(int j = 0; j <>
childItm[j].setChecked(true); //use false for de-selecting
}
}

Code for selecting/de-selecting the checkbox in tree SWT

Below is a small snippet for code for selecting/de-selecting the child checkbox in tree

TreeItem[] itm = tree.getItems();
for(int i =0; i <>
//selecting parent items
itm[i].setChecked(true); //use false for de-selecting
//getting the child items for the parent items
TreeItem[] childItm = itm[i].getItems();
for(int j = 0; j <>
childItm[j].setChecked(true);
}
}

Dispaly tree in expanded mode SWT

Below is a small snippet of code for creating a checked tree in SWT and display the tree in expanded mode
//code to display the tree in expanded mode
TreeItem[] items = tree.getItems();
for (int i = 0; i <>
items[i].setExpanded(true);
}

Check box tree in SWT

Below is a small snippet of code for creating a checked tree in SWT

tree = new Tree(composite, SWT.CHECK | SWT.BORDER);
// Turn off drawing to avoid flicker
tree.setRedraw(false);
for(int i = 0; i<5>
TreeItem item = new TreeItem(tree, SWT.NONE);
item.setText("TreeItem" + i);
item.setChecked(true);
item.setExpanded(true);
for ( int j =0; j <>
TreeItem child = new TreeItem(item, SWT.NONE);
child.setText("TreeItem" + i + "." + j);
child.setChecked(true);
child.setExpanded(true);
}
}
// Turn drawing back on!
tree.setRedraw(true);

Creating a checked tree in SWT

Below is a small snippet of code for creating a checked tree in SWT

tree = new Tree(composite, SWT.CHECK | SWT.BORDER);
// Turn off drawing to avoid flicker
tree.setRedraw(false);
for(int i = 0; i<5>
TreeItem item = new TreeItem(tree, SWT.NONE);
item.setText("TreeItem" + i);
item.setChecked(true);
item.setExpanded(true);
for ( int j =0; j <>
TreeItem child = new TreeItem(item, SWT.NONE);
child.setText("TreeItem" + i + "." + j);
child.setChecked(true);
child.setExpanded(true);
}
}
// Turn drawing back on!
tree.setRedraw(true);