Click here to Skip to main content
16,007,932 members
Home / Discussions / C#
   

C#

 
GeneralRe: Problems pulling an image out of SQL Pin
Christian Graus24-Nov-05 14:24
protectorChristian Graus24-Nov-05 14:24 
GeneralRe: Problems pulling an image out of SQL Pin
Judy10110124-Nov-05 14:30
Judy10110124-Nov-05 14:30 
GeneralRe: Problems pulling an image out of SQL Pin
Christian Graus24-Nov-05 17:05
protectorChristian Graus24-Nov-05 17:05 
GeneralRe: Problems pulling an image out of SQL Pin
Judy10110124-Nov-05 14:34
Judy10110124-Nov-05 14:34 
GeneralRe: Problems pulling an image out of SQL Pin
Christian Graus24-Nov-05 17:28
protectorChristian Graus24-Nov-05 17:28 
AnswerRe: Problems pulling an image out of SQL Pin
Guillermo Rivero25-Nov-05 3:50
Guillermo Rivero25-Nov-05 3:50 
AnswerRe: Problems pulling an image out of SQL Pin
Mark DeVol29-Nov-05 11:55
Mark DeVol29-Nov-05 11:55 
QuestionFileNotFoundException with remoting Pin
Sylvain Boissé24-Nov-05 13:05
Sylvain Boissé24-Nov-05 13:05 
Hello,
I have an issue as I am trying to use remoting in my VS 2005 project, with Ipc channels.

I have the assembly myproject.dll, containing all the necessary implementation for server and client processes to use it for remoting:

IMyObject
CMyObject : IMyObject
CMyObjectRemoteClient : IMyObject
CMyObjectRemoteServer : MarshalByRefObject, IMyObject

I have a first process, the server, instantiating CMyObjectRemoteServer, registring the channel, etc. All goes well for that part:

// Create Ipc Channel
m_oIpcServerChannel = new IpcServerChannel("myproject");

// Register to the IPC channel
ChannelServices.RegisterChannel(m_oIpcServerChannel, false);

//register remote object
RemotingConfiguration.RegisterWellKnownServiceType(
typeof(CMyObjectRemoteServer),
"CMyObject",
WellKnownObjectMode.Singleton);

I have the second process, the client, doing the following:

// Create Ipc Channel
m_oIpcClientChannel = new IpcClientChannel("myproject", null);

// Register to the IPC channel
ChannelServices.RegisterChannel(m_oIpcClientChannel, false);

// Get the remote object
remoteObject = (IMyObject) Activator.GetObject(
typeof(CMyObjectRemoteServer),
"ipc://myproject/CMyObject");

So far, all is good. No exception. But then I try to call a function of my object:

remoteObject.Open();

And I get the following exception:

1724 RemoteTester. WARNING 18:49:57:246 00e9c MyNamespace::CMyObjectRemoteClient.Open() Error calling remote object function: Could not load file or assembly 'myproject, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified.

The first process is nothing but an exe using myproject.dll to get a CMyObjectRemoteServer object. It works good.

The second process is also a simple exe using myproject.dll to get a CMyObjectRemoteClient object.

The 2 exe of the client and server, and myproject.dll are all in the same folder. I also checked:

typeof(CMyObjectRemoteServer).Assembly.CodeBase
typeof(CMyObjectRemoteClient).Assembly.CodeBase

to find out they really point to the right place, and all looks fine.

It works good until it fails to locate the assembly 'myproject', where it actually got CMyObjectRemoteClient, which also contains CMyObjectRemoteServer object from (if this is what it looking for). Duh! What is going wrong, and why does it fail loading the assembly?

Thanks for your help!

-Sly

There are 3 types of people in this world, people who understand binary, and those who don't.

-- modified at 19:06 Thursday 24th November, 2005
QuestionUser and Group Security Pin
jez12345624-Nov-05 11:33
jez12345624-Nov-05 11:33 
QuestionnumericUpDown + button + paint handler Pin
...---...24-Nov-05 9:07
...---...24-Nov-05 9:07 
AnswerRe: numericUpDown + button + paint handler Pin
Christian Graus24-Nov-05 9:27
protectorChristian Graus24-Nov-05 9:27 
QuestionRegular Expressions in .NET (C#) Pin
conrado724-Nov-05 8:47
conrado724-Nov-05 8:47 
AnswerRe: Regular Expressions in .NET (C#) Pin
Kevin McFarlane24-Nov-05 10:54
Kevin McFarlane24-Nov-05 10:54 
QuestionDataGrid row value Pin
webhay24-Nov-05 8:35
webhay24-Nov-05 8:35 
AnswerRe: DataGrid row value Pin
Stanciu Vlad24-Nov-05 9:01
Stanciu Vlad24-Nov-05 9:01 
GeneralRe: DataGrid row value Pin
webhay24-Nov-05 9:24
webhay24-Nov-05 9:24 
GeneralRe: DataGrid row value Pin
Stanciu Vlad24-Nov-05 9:29
Stanciu Vlad24-Nov-05 9:29 
QuestionFormatting Console.WriteLine Pin
budidharma24-Nov-05 8:03
budidharma24-Nov-05 8:03 
AnswerRe: Formatting Console.WriteLine Pin
Curtis Schlak.24-Nov-05 13:57
Curtis Schlak.24-Nov-05 13:57 
QuestionCode & Compiler Efficiency Pin
Andrew day24-Nov-05 7:28
Andrew day24-Nov-05 7:28 
AnswerRe: Code & Compiler Efficiency Pin
Colin Angus Mackay24-Nov-05 8:03
Colin Angus Mackay24-Nov-05 8:03 
AnswerRe: Code & Compiler Efficiency Pin
Colin Angus Mackay24-Nov-05 8:29
Colin Angus Mackay24-Nov-05 8:29 
AnswerRe: Code & Compiler Efficiency Pin
leppie24-Nov-05 20:16
leppie24-Nov-05 20:16 
QuestionHashTable Beginning Question Pin
budidharma24-Nov-05 7:27
budidharma24-Nov-05 7:27 
AnswerRe: HashTable Beginning Question Pin
budidharma24-Nov-05 7:40
budidharma24-Nov-05 7:40 

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.