Click here to Skip to main content
15,913,486 members
Home / Discussions / C#
   

C#

 
QuestionSplit Data Table Records into several parts and assign to different Threads Pin
prabhakar CSPL9-Feb-10 22:47
prabhakar CSPL9-Feb-10 22:47 
QuestionThreading Pin
MumbleB9-Feb-10 22:20
MumbleB9-Feb-10 22:20 
AnswerRe: Threading Pin
OriginalGriff9-Feb-10 22:31
mveOriginalGriff9-Feb-10 22:31 
GeneralRe: Threading Pin
MumbleB9-Feb-10 22:43
MumbleB9-Feb-10 22:43 
GeneralRe: Threading Pin
OriginalGriff9-Feb-10 23:25
mveOriginalGriff9-Feb-10 23:25 
GeneralRe: Threading Pin
MumbleB9-Feb-10 23:35
MumbleB9-Feb-10 23:35 
GeneralRe: Threading Pin
Luc Pattyn10-Feb-10 1:57
sitebuilderLuc Pattyn10-Feb-10 1:57 
QuestionLoading an assembly from a new AppDoamin Pin
ThetaClear9-Feb-10 20:28
ThetaClear9-Feb-10 20:28 
Hi Guys,

I'm trying to do something that looks easy but for some reason doesn't work.
I have a window service which loads .dll's that are in a different directory every couple of minutes.
I need to update those .dll's every now an than so I created an AppDomin and from there I want to load the .dll's in to the main AppDomain.
The strange thing is when I try to load a .dll I get an exception that the .dll can't be found.
Here's the source code:

AppDomainSetup AppDomSetup = new AppDomainSetup();
                AppDomSetup.ApplicationName = "Service Name";
                AppDomSetup.ApplicationBase = Application.StartupPath;
                AppDomSetup.PrivateBinPath = "alerts";
                AppDomSetup.ShadowCopyFiles = "true";
                AppDomSetup.CachePath = Path.Combine(Application.StartupPath, "_cache");
                m_FilesDomain = AppDomain.CreateDomain("Ksm Scheduler", null , AppDomSetup);
                m_FilesDomain.Load("alert1.dll");

The 'PrivateBinPath' property points to the directory that contains the .dll's.
The 'cache path' folder IS CREATED but I get an exception. When I place the .dll's in the 'ApplicationBase' directory i.e. in the directory of the .exe file, the .dll is loaded.



Thanks for any help,


Avi
AnswerRe: Loading an assembly from a new AppDoamin Pin
Rob Philpott10-Feb-10 0:11
Rob Philpott10-Feb-10 0:11 
GeneralRe: Loading an assembly from a new AppDoamin Pin
ThetaClear10-Feb-10 9:53
ThetaClear10-Feb-10 9:53 
QuestionRSync Pin
satsumatable9-Feb-10 19:22
satsumatable9-Feb-10 19:22 
QuestionPreventing the dropdown from being opened when drop down button pressed in combobox? Pin
Ron.bharath9-Feb-10 18:53
Ron.bharath9-Feb-10 18:53 
AnswerRe: Preventing the dropdown from being opened when drop down button pressed in combobox? Pin
Hessam Jalali10-Feb-10 1:25
Hessam Jalali10-Feb-10 1:25 
QuestionSuspendLayout ResumeLayout Question Pin
Douglas Kirk9-Feb-10 18:52
Douglas Kirk9-Feb-10 18:52 
AnswerRe: SuspendLayout ResumeLayout Question Pin
Dave Kreskowiak10-Feb-10 2:07
mveDave Kreskowiak10-Feb-10 2:07 
AnswerRe: SuspendLayout ResumeLayout Question Pin
Luc Pattyn10-Feb-10 2:09
sitebuilderLuc Pattyn10-Feb-10 2:09 
QuestionRss Pin
kk.tvm9-Feb-10 18:21
kk.tvm9-Feb-10 18:21 
AnswerRe: Rss Pin
Arun Jacob9-Feb-10 19:13
Arun Jacob9-Feb-10 19:13 
AnswerRe: Rss Pin
Giorgi Dalakishvili9-Feb-10 19:32
mentorGiorgi Dalakishvili9-Feb-10 19:32 
QuestionIEnumerable Min() not working as expected Pin
Member 39190499-Feb-10 16:43
Member 39190499-Feb-10 16:43 
AnswerRe: IEnumerable Min() not working as expected Pin
Dave Kreskowiak10-Feb-10 2:02
mveDave Kreskowiak10-Feb-10 2:02 
QuestionWhat is the use of e.Handled in the KeyDown event Pin
Kalvin @ Work9-Feb-10 11:04
Kalvin @ Work9-Feb-10 11:04 
AnswerRe: What is the use of e.Handled in the KeyDown event Pin
loyal ginger9-Feb-10 11:22
loyal ginger9-Feb-10 11:22 
QuestionDatagridview C# Editable combo box control. Pin
Omersayeed9-Feb-10 7:45
Omersayeed9-Feb-10 7:45 
QuestionSQL select on two tables takes too long Pin
TheJudeDude9-Feb-10 7:42
TheJudeDude9-Feb-10 7:42 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.