It is very easy I have tried by creating a function and calling that function at the place ,where it is needed. Just for example prepare a windows form and create a database in Ms Access as I have described in my previous post. and follow all the step as mentioned in that post.In code editor just create a function