Buongiorno
volevo sottoporre un problema che sto avendo con un applicativo da me fatto con VB.net 2010 WPF.
Ho implementato in una finestra WPF una routine con il dispatcher timer e con addhandler una Sub che cicla con un timer di 0,1 sec.
sul pc di sviluppo funziona tutto correttamente, mentre la cosa non funziona sul pc cliente su cui è implmentata l'applicazione. Da premettere che sono stati implementati altri eventi di questo tipo nel progetto.
La funzione addhandler è chiamata al caricamento della pagina, ma non è eseguita, cioè se metto breakpoint non la esegue:
cosa può essere???codice:Private Parametri_Loop1 As New DispatcherTimer() Private Sub CaricaFinestra(sender As System.Object, e As System.Windows.RoutedEventArgs) Handles MyBase.Loaded LeggiParam = True CaricaParametri1() CaricaParametri2() AddHandler Parametri_Loop1.Tick, AddressOf Parametri_Loop Parametri_Loop1.Interval = New TimeSpan(0, 0, 0.1) Parametri_Loop1.Start() End Sub Private Sub Parametri_Loop() If Edita_Parametri Then TextBox_Num2.IsReadOnly = False Num_Prg.IsReadOnly = False Label_NumDis2.Foreground = System.Windows.Media.Brushes.Black Else TextBox_Num2.IsReadOnly = True Num_Prg.IsReadOnly = True Label_NumDis2.Foreground = System.Windows.Media.Brushes.LightGray End If End Sub![]()

Rispondi quotando