26/06/20 15:30
gnapolitano@teletu.it
Ho il seguente codice:
Perché mai msgboxresult non esegue il condizionamento e quindi manda ttto il stampa come se cliccassi sempre su OK?
Grazie per il vostro aiauto.
Private Sub stampa_Click(sender As Object, e As EventArgs) Handles stampa.Click WebBrowser1.ShowPageSetupDialog() If MsgBoxResult.Ok Then For NumPag = 1 To pagine fileName = Application.StartupPath & "\tabulati\registroChiusuraNF" & Format(NumPag, "00") + ".html" WebBrowser1.Navigate(fileName) Application.DoEvents() Threading.Thread.Sleep(20) Do While WebBrowser1.IsBusy Application.DoEvents() Loop WebBrowser1.Print() Next Else Me.annostat.Text = "" Me.Close() Exit Sub End If End Sub
Perché mai msgboxresult non esegue il condizionamento e quindi manda ttto il stampa come se cliccassi sempre su OK?
Grazie per il vostro aiauto.