We have some installation project in Visual Studio solution (Other project types -> Setup and deployment -> Setup project). This project has another library type project with Installation class named InstallationCore like project output. In user action, I call to Install and Uninstall functions of installer of InstallationCore.
InstallationCore has windows forms for interaction with user. There, in forms, I use Drag and Drop functionality for Drag and Drop text from Tree View to Text Box.
But in line:
txbUserName.AllowDrop = true;
I get error of JIT debugger:
Unhandled exception has occured
DragDrop registration did not succeed
System.InvalidOperationException: DragDrop registration did not succeed
And long stack trace after that.
Important to say, that when I run Installer function from test project the error did not occur and all work fine. Error occurs only when I run the .msi package.
Any suggestions?
Do you have any multi threads causing this issue. If so, find them and force them to STA
trd = New Threading.Thread(AddressOf ThreadTask) trd.IsBackground = True trd.SetApartmentState(ApartmentState.STA)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With