Sql & vb.net

Im hoping to find someone that can help me with a problem that I cant seem to resolve and it's driving me crazy!

Basically I am trying to create a child management system for a nurse using vb.net and SQL as my backend db
The application consists of a number of differen forms. Two of these forms are called "frmSearchInfo" and "frmChildDetails".

The application is connected to a SQL database with two tables "Parent_Details" and "Child"

When users enter details on form "frmSearchInfo" I want it to be able to search records in the database and return the same first name, second name and DOB as well as the ID, phone, addressline1, addressline2, county. I also want the datagrid to show dates of appointments for the children.
The records needed are stored in the Child Table.

prepare sql statement at front end only based on the condition. and pass to DB and return the dataset and load...

example:

Private sub SerachDetails(Byval firstname as string,lastname as string,dob as date)
Try
--here you check for all the parameters which are not nothing and based on that write where condition..
catch
End Try
End sub