Hi,
I am launching windows form from script in event handler, form launched successfully and unable interact with form and form freezes.
Thanks and Regards
Praveen Kumar
I am launching windows form from script in event handler, form launched successfully and unable interact with form and form freezes.
FileSystemWatcher _fileWatcher = new System.IO.FileSystemWatcher();
vde.AddHostObject("_fileWatcher", _fileWatcher);
_fileWatcher.Path = "C:\\Users\\praveen\\Desktop";
_fileWatcher.Filter = "*.*";
_fileWatcher.NotifyFilter = System.IO.NotifyFilters.Attributes |
System.IO.NotifyFilters.CreationTime |
System.IO.NotifyFilters.DirectoryName |
System.IO.NotifyFilters.FileName |
System.IO.NotifyFilters.LastAccess |
System.IO.NotifyFilters.LastWrite |
System.IO.NotifyFilters.Security |
System.IO.NotifyFilters.Size;
_fileWatcher.EnableRaisingEvents = true;
_fileWatcher.IncludeSubdirectories = true;
Scriptvar form=new WinForms.System.Windows.Forms.Form();
var delconncect=_fileWatcher.Created.connect(function(obj,e){
form.Show();
});
var desconncect=_fileWatcher.Deleted.connect(function(obj,e){
form.Show();
});
form does not freeze if we launch without event handler.Thanks and Regards
Praveen Kumar