  public function Detail (email as string) as structStaff
  
  	dim myDSN as String = ConfigurationSettings.AppSettings("ProjectPalDSN")
	dim mySQLReader as SqlDataReader
	dim myConn As new SQLConnection(myDSN)
	dim mySQLCommand as new SQLCommand("spGetStaffDetail", myConn)
	dim myStruct as new structStaff()

	mySQLCommand.CommandType = CommandType.StoredProcedure
	mySQLCommand.Parameters.Add(New SqlParameter("@email", SqlDbType.varchar))
    mySQLCommand.Parameters("@email").Value = email

	myConn.Open()
	mySQLReader = mySQLCommand.ExecuteReader()

    while (mySQLReader.Read()) 
	  myStruct.id = mySQLReader.GetInt32(0)
      myStruct.firstname = mySQLReader.GetString(1)
      myStruct.lastname = mySQLReader.GetString(2)
      myStruct.email = mySQLReader.GetString(3)
      myStruct.password = mySQLReader.GetString(4)
      myStruct.isPM = mySQLReader.GetInt32(5)
    end while
	
	mySQLReader.Close
	myConn.Close

	Return ( myStruct )
  
  end function
