Click here to Skip to main content
15,894,291 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Recently I used a DLL library which displayed a splash screen when loaded in Visual Studio.
How can I do that? I need to be able to trigger some events when my dll is loaded in Visual Studio, from within the DLL itself.
Posted
Comments
syed shanu 4-Dec-14 19:58pm    
Loaded in Visual studio ?
Can you explain bit more with some example about your requirement.
Mihai Pruna 4-Dec-14 22:18pm    
see the Devdept Eyeshot trial for example

1 solution

 
Share this answer
 
Comments
Mihai Pruna 5-Dec-14 7:58am    
Thank you, I knew about DebuggerAttached but not DesignMode!
Mihai Pruna 5-Dec-14 10:33am    
...but, somehow, it always returns false even when is Debugger attached returns true.
ideally I would like for the event to occur when the assembly is actually loaded in visual studio, or during build, so that I can license the softare
Mehdi Gholam 5-Dec-14 10:50am    
DesignMode only works when you open the form designer, for debug/release running you need to implement licensing.
Mihai Pruna 5-Dec-14 11:45am    
but isn't the License manager tied to the same flag?
(System.ComponentModel.LicenseManager.UsageMode == System.ComponentModel.LicenseUsageMode.Designtime

I tried that and it didn't return true
Mehdi Gholam 6-Dec-14 1:28am    
Like I said they only work when designing not running, you need to use LicenseUsageMode.Runtime when running.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900