I have an animation program which allows users to import and animate images. I do this using timer events. I have a listbox which contains the image references, and a Image which displays the chosen image. Here is the code:

When the user clicks the "Animate" button:

vb.net Code:
  1. Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles animate.Click
  2.         Dim cananimate As Boolean = True
  3.  
  4.         'The secret code
  5.         If Images.Items.Count > 0 Then
  6.             Images.SelectedIndex = 0
  7.  
  8.             'While it has a image in front, keep animating
  9.             If Not Images.SelectedIndex = Images.Items.Count - 1 Then
  10.  
  11.                 Timer1.Start()
  12.  
  13.                 'If only one image present, display a message
  14.                 If Images.Items.Count = 1 Then
  15.                     MessageBox.Show("You must have more than one image to begin animating.")
  16.                 End If
  17.             End If
  18.         End If
  19.     End Sub

Timer tick event:

vb.net Code:
  1. Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
  2.         If Not Images.SelectedIndex = Images.Items.Count - 1 Then
  3.             Cursor = Cursors.AppStarting
  4.             Images.SelectedIndex += 1
  5.             mainimage.Refresh()
  6.             Cursor = Cursors.Default
  7.             If Images.SelectedIndex + 1 = Images.Items.Count Then
  8.                 Timer1.Enabled = False
  9.             End If
  10.         End If
  11.     End Sub

I want to make a dialog to appear and allow the user to select a custom FPS for the animation. For instance, if they type 15, the listbox must go down 15 images in 1 second. But how do I convert FPS to a timer interval?