Click here to Skip to main content
15,896,111 members
Home / Discussions / C#
   

C#

 
GeneralRe: Mouse Click Problem Pin
Heath Stewart6-May-04 18:05
protectorHeath Stewart6-May-04 18:05 
GeneralMSMQ Peek Callbacks and duplicate messages Pin
inyoursadachine6-May-04 13:20
inyoursadachine6-May-04 13:20 
Generalmultiline display in dataGridColumn textBox Pin
blankg6-May-04 12:24
blankg6-May-04 12:24 
GeneralRe: multiline display in dataGridColumn textBox Pin
Heath Stewart6-May-04 18:20
protectorHeath Stewart6-May-04 18:20 
GeneralRe: multiline display in dataGridColumn textBox Pin
blankg7-May-04 1:55
blankg7-May-04 1:55 
GeneralRemoting/Serializing Pin
markkow6-May-04 11:23
markkow6-May-04 11:23 
GeneralRe: Remoting/Serializing Pin
Heath Stewart6-May-04 11:58
protectorHeath Stewart6-May-04 11:58 
GeneralRe: Remoting/Serializing Pin
markkow6-May-04 12:15
markkow6-May-04 12:15 
Firstly, thanks for the information about naming conventions for the framework, I guess I'm just stuck in my ways because of many years of coding in C++ and using a C in front of classes.

MyClass does inherit from MarshalByRefObject, and it is attributed with the SerializableAttribute, sorry I missed them.
I do want to use an instance method to save the instance. Like so:

public void save(string fileName){
try
{
IFormatter formatter = new BinaryFormatter();
Stream stream = new FileStream(fileName, FileMode.Create, FileAccess.Write, FileShare.None);
formatter.Serialize(stream, this);
stream.Close();
}
catch(Exception e){
MessageBox.Show(e.Message);
}
}
Which would be ideal, however when this is run an exception is thrown with the following message:
"The type System.Runtime.Remoting.ServerIdentity in Assembly mscorlib, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 is not marked as serializable."
Everything stored in MyClass is marked as serializable, it saves fine when using my static method, but not when called remotely. All other remote calls in MyClass work ok.
GeneralRe: Remoting/Serializing Pin
Heath Stewart6-May-04 17:52
protectorHeath Stewart6-May-04 17:52 
GeneralRe: Remoting/Serializing Pin
markkow7-May-04 16:34
markkow7-May-04 16:34 
GeneralRe: Remoting/Serializing Pin
Heath Stewart8-May-04 19:18
protectorHeath Stewart8-May-04 19:18 
GeneralRe: Remoting/Serializing Pin
markkow9-May-04 5:40
markkow9-May-04 5:40 
GeneralToolBar.BackColor Pin
Anonymous6-May-04 10:37
Anonymous6-May-04 10:37 
GeneralRe: ToolBar.BackColor Pin
Heath Stewart6-May-04 11:51
protectorHeath Stewart6-May-04 11:51 
QuestionAcitveX equivalent in C# ? Pin
TigerNinja_6-May-04 8:35
TigerNinja_6-May-04 8:35 
AnswerRe: AcitveX equivalent in C# ? Pin
Heath Stewart6-May-04 8:40
protectorHeath Stewart6-May-04 8:40 
GeneralRe: AcitveX equivalent in C# ? Pin
TigerNinja_6-May-04 10:08
TigerNinja_6-May-04 10:08 
GeneralRe: AcitveX equivalent in C# ? Pin
Heath Stewart6-May-04 10:26
protectorHeath Stewart6-May-04 10:26 
AnswerRe: AcitveX equivalent in C# ? Pin
TigerNinja_6-May-04 9:09
TigerNinja_6-May-04 9:09 
GeneralSound- Two Events at a time Pin
MeterMan6-May-04 8:14
MeterMan6-May-04 8:14 
GeneralRe: Sound- Two Events at a time Pin
Heath Stewart6-May-04 8:29
protectorHeath Stewart6-May-04 8:29 
GeneralRe: Sound- Two Events at a time Pin
MeterMan6-May-04 12:15
MeterMan6-May-04 12:15 
GeneralRe: Sound- Two Events at a time Pin
Heath Stewart6-May-04 17:53
protectorHeath Stewart6-May-04 17:53 
GeneralRe: Sound- Two Events at a time Pin
MeterMan6-May-04 17:58
MeterMan6-May-04 17:58 
GeneralRe: Sound- Two Events at a time Pin
Heath Stewart6-May-04 18:01
protectorHeath Stewart6-May-04 18:01 

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.