473,382 Members | 1,809 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,382 software developers and data experts.

'... is not marked as Serializable'

Has anyone got any idea what might be causing this message to be shown? It
occurs whenever I try to copy / cut my custom control from the Form Designer:

http://img13.echo.cx/img13/2061/notm...lizable5ok.png
Nov 17 '05 #1
3 13099
Hi,

Looks like the designer attempts to serialize the control object in order to
put it on the Clipboard. As your control is not marked as Serializable, this
attempt fails and the designer cannot copy your control to the clipboard.

--
Sincerely,
Dmytro Lapshyn [Visual Developer - Visual C# MVP]
"Barguast" <It*****************@Email.com> wrote in message
news:1A**********************************@microsof t.com...
Has anyone got any idea what might be causing this message to be shown? It
occurs whenever I try to copy / cut my custom control from the Form
Designer:

http://img13.echo.cx/img13/2061/notm...lizable5ok.png


Nov 17 '05 #2
From what I understand, including [Serializable] at the start of the class
definition is enough to mark the control as serializable, right? I have tried
that already but it doesn't seem to make any difference. The messagebox seems
to imply that the problem is with the UserControl class and I can't add the
attribute to that class...

"Dmytro Lapshyn [MVP]" wrote:
Hi,

Looks like the designer attempts to serialize the control object in order to
put it on the Clipboard. As your control is not marked as Serializable, this
attempt fails and the designer cannot copy your control to the clipboard.

--
Sincerely,
Dmytro Lapshyn [Visual Developer - Visual C# MVP]
"Barguast" <It*****************@Email.com> wrote in message
news:1A**********************************@microsof t.com...
Has anyone got any idea what might be causing this message to be shown? It
occurs whenever I try to copy / cut my custom control from the Form
Designer:

http://img13.echo.cx/img13/2061/notm...lizable5ok.png


Nov 17 '05 #3
I guess it is because you can't serialize a delegate\event and the user
control has some delegates\events defined in either your class or the base
implementation.
--
HTH

Ollie Riches
http://www.phoneanalyser.net

Disclaimer: Opinions expressed in this forum are my own, and not
representative of my employer.
I do not answer questions on behalf of my employer. I'm just a programmer
helping programmers.

"Barguast" <It*****************@Email.com> wrote in message
news:44**********************************@microsof t.com...
From what I understand, including [Serializable] at the start of the class
definition is enough to mark the control as serializable, right? I have tried that already but it doesn't seem to make any difference. The messagebox seems to imply that the problem is with the UserControl class and I can't add the attribute to that class...

"Dmytro Lapshyn [MVP]" wrote:
Hi,

Looks like the designer attempts to serialize the control object in order to put it on the Clipboard. As your control is not marked as Serializable, this attempt fails and the designer cannot copy your control to the clipboard.
--
Sincerely,
Dmytro Lapshyn [Visual Developer - Visual C# MVP]
"Barguast" <It*****************@Email.com> wrote in message
news:1A**********************************@microsof t.com...
Has anyone got any idea what might be causing this message to be shown? It occurs whenever I try to copy / cut my custom control from the Form
Designer:

http://img13.echo.cx/img13/2061/notm...lizable5ok.png


Nov 17 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: David Elliott | last post by:
I have a 3rd Party DLL that is a Win32 NOT .NET Assembly that is misbehaving. I am trying to isolate it in its own AppDomain. I got to load but can not create an instance. I receive the following...
1
by: Harshdeep Mehta | last post by:
Hi all, I have written a page in which I want to preserve value of object - suppose A - value, so I used viewstate. but that give me error. Code : ViewState = objClassA; // Before PostBack...
2
by: jeffpriz | last post by:
I'm having trouble.. I created a small class that I pass to my Pages, and I want to put that class into Viewstate.. I do: Viewstate.add("thisVar", myClassVariable) and i receive the lovely...
2
by: Prakash | last post by:
Hi Friends, In my C# application, i have tried to serialize some structured data using Soapformatter. While calling the serialize funciton i got the exception message like "mscorlib....The...
1
by: Yogesh Parab | last post by:
In our application we havr presentation layer and business laye. The presentation layer interacts with business layer using webservice. We need to store the object from the Business layer in the...
2
by: Frank Uray | last post by:
Hi again I have a little problem with "serializable" a control ... I am creating AppDomain, Assembly and Instance. All works fine. My "base" class for the instance inherit from: -...
0
mmfranke
by: mmfranke | last post by:
Hello. Hi. I'm writing a logging service that uses .NET remoting. The idea is that the service publishes an EventProcessor object that clients can access via .NET Remoting, passing it...
5
by: Nirdesh | last post by:
Hi, I am serializing a custom class holding some data for my project. This data internally contains a class which contains an event public delegate void MemberModifiedEventHandler(object...
2
by: amirghaffarie1362 | last post by:
i use below code for create arraylist() Dim ItemsT As New ArrayList() If ViewState("items") IsNot Nothing Then ItemsT = DirectCast(ViewState("items"), ArrayList) ...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.