You can achive this by using Timer Control and Properties of Window Form
See this code :
Private _TimeLimit As Integer = 0
Private Sub Form_Load(ByVal sender As Object, ByVal e As EventArgs) Handles Form1.Load
Timer1.Enabled = True
Timer1.Interval = 100
Timer1.Start()
End Sub
Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
_TileLimit = _TimeLimit + 1
If _TimeLimit = 100 Then WindowState = Minimized
End Sub
Here i am taking variable for time you can read time from your DataBase using Ado.Net
I hope it will help you. :)