Ciao
Ho fatto un programmino per controllare e copiare velocemente dei file da una NAS a un PC.
Per avere un'interfaccia completa durante la copia file ho utilizzato "Microsoft.VisualBasic.FileIO"
Durante il Debug con VS 2019 non mi ha mai dato nessun problema, ma una volta compilato, quando lancio il comando copia,
il programma si chiude e nei log di Windows trovo questo errore:
Evento 1006 NET Runtime
Applicazione: FileCheck.exe
Versione framework: v4.0.30319
Descrizione: il processo è stato terminato a causa di un'eccezione non gestita.
Informazioni sull'eccezione: System.InvalidOperationException
in System.Windows.Forms.Control.MarshaledInvoke(System.Windows.Forms.Control, System.Delegate, System.Object[], Boolean)
in System.Windows.Forms.Control.Invoke(System.Delegate, System.Object[])
in System.Windows.Forms.Control.Invoke(System.Delegate)
in File_Check.CopyFromStorage.CopyAndDelete()
in System.Threading.ThreadHelper.ThreadStart_Context(System.Object)
in System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
in System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
in System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
in System.Threading.ThreadHelper.ThreadStart()
Ho provato delle soluzioni in rete ma non sono state risolutive.
Sono disperato.
|