I have an application that I am writing and i was initially using a form as the startup, but I want to use sub Main() as the start. This is the sub
VB Code:
  1. Sub main()
  2.         Application.EnableVisualStyles()
  3.         Application.DoEvents()
  4.  
  5.         'Check to see if an installer is flagged for deletion
  6.         Dim inFile As String = My.Settings.KillInstaller
  7.         'if updates are enabled then do a check
  8.         If My.Settings.enableUpdates = True Then
  9.             'if flagged, delete the recent installer
  10.             If inFile <> String.Empty Then
  11.                 'check to see if installer exists in the temp directory
  12.                 If IO.File.Exists(My.Computer.FileSystem.SpecialDirectories.Temp & "\" & inFile) Then
  13.                     'Delete the previous installer
  14.                     IO.File.Delete(My.Computer.FileSystem.SpecialDirectories.Temp & "\" & inFile)
  15.                     'Update my.settings flag
  16.                     My.Settings.KillInstaller = String.Empty
  17.                 End If
  18.             End If
  19.             'Check for any new updates and run the update form if any exist
  20.             If checkUpdates() Then Exit Sub
  21.         End If
  22.         'Run the login screen
  23.         Application.Run(New Login)
  24.         Application.Exit()
  25.     End Sub

It does a few things that are irrelevant to my question, which is this. I have enableVisualStyles in the sub, however when the application is run from this method, as opposed to haveing a form as startup item, all the linkLabels in my application look horrible, almost like it is changing the font. Has anyone else seen anything like this or perhaps see any errors in my code?

Thanks