Click here to Skip to main content
15,921,351 members
Home / Discussions / C#
   

C#

 
QuestionValidating Email Address Pin
dabuskol6-Mar-07 20:27
dabuskol6-Mar-07 20:27 
AnswerRe: Validating Email Address Pin
sam#6-Mar-07 20:35
sam#6-Mar-07 20:35 
AnswerRe: Validating Email Address Pin
goldli6-Mar-07 21:07
goldli6-Mar-07 21:07 
AnswerRe: Validating Email Address Pin
Wayne Phipps6-Mar-07 21:12
Wayne Phipps6-Mar-07 21:12 
AnswerRe: Validating Email Address Pin
Scott Dorman8-Mar-07 17:31
professionalScott Dorman8-Mar-07 17:31 
QuestionMDI and OutOfMemoryException and CreateHandle() Pin
sarang.chandaikar6-Mar-07 20:15
sarang.chandaikar6-Mar-07 20:15 
AnswerRe: MDI and OutOfMemoryException and CreateHandle() Pin
VirtualVoid.NET7-Mar-07 1:26
VirtualVoid.NET7-Mar-07 1:26 
QuestionCloning object with properties Pin
Priya09026-Mar-07 19:57
Priya09026-Mar-07 19:57 
I have a problem in undo & redo of custom controls...I have a custom control object that needs to be cloned into a new object when redo is done.

Am using the following method :-

In the below method "ctrl" is the New empty object to which the properties have to be copied from "propertyList"(Properties of Old object)..
But the following line throws an exception 'Unable to convert System.Reflection.RuntimePropertyInfo to System.Drawing.Point' when trying to copy AutoScrollOffset property.
lINE ->myProperty.SetValue(ctrl, obj );
Is there a way to convert a property(whatever be the type ) to the corresponding property in the new object ?????....

public static void SetControlProperties(System.Windows.Forms.Control ctrl,Hashtable propertyList)
{
PropertyDescriptorCollection properties = TypeDescriptor.GetProperties(ctrl);
foreach (PropertyDescriptor myProperty in properties)
{
if(propertyList.Contains(myProperty.Name))
{
Object obj = propertyList[myProperty.Name];
myProperty.SetValue(ctrl, obj );
}
//...
}
}
AnswerRe: Cloning object with properties Pin
Martin#6-Mar-07 20:20
Martin#6-Mar-07 20:20 
QuestionRe: Cloning object with properties Pin
Priya09028-Mar-07 1:33
Priya09028-Mar-07 1:33 
AnswerRe: Cloning object with properties Pin
Martin#8-Mar-07 2:46
Martin#8-Mar-07 2:46 
QuestionHow to make a listview looks like the windows explorer? Pin
goldli6-Mar-07 19:54
goldli6-Mar-07 19:54 
AnswerRe: How to make a listview looks like the windows explorer? Pin
VirtualVoid.NET7-Mar-07 1:28
VirtualVoid.NET7-Mar-07 1:28 
Questionhow to restrict Copy and Paste in textbox control Pin
AR Reddy6-Mar-07 19:45
AR Reddy6-Mar-07 19:45 
AnswerRe: how to restrict Copy and Paste in textbox control Pin
Omkar Ghaisas6-Mar-07 19:55
Omkar Ghaisas6-Mar-07 19:55 
AnswerRe: how to restrict Copy and Paste in textbox control Pin
Navi156-Mar-07 20:08
Navi156-Mar-07 20:08 
QuestionInstantiating a Value Type in .NET Pin
Omkar Ghaisas6-Mar-07 19:29
Omkar Ghaisas6-Mar-07 19:29 
AnswerRe: Instantiating a Value Type in .NET Pin
Not Active6-Mar-07 20:08
mentorNot Active6-Mar-07 20:08 
GeneralRe: Instantiating a Value Type in .NET Pin
Omkar Ghaisas6-Mar-07 20:11
Omkar Ghaisas6-Mar-07 20:11 
GeneralRe: Instantiating a Value Type in .NET Pin
sam#6-Mar-07 20:45
sam#6-Mar-07 20:45 
GeneralRe: Instantiating a Value Type in .NET Pin
Colin Angus Mackay6-Mar-07 21:23
Colin Angus Mackay6-Mar-07 21:23 
GeneralRe: Instantiating a Value Type in .NET Pin
Not Active7-Mar-07 3:26
mentorNot Active7-Mar-07 3:26 
AnswerRe: Instantiating a Value Type in .NET Pin
Matthew Cuba7-Mar-07 1:09
Matthew Cuba7-Mar-07 1:09 
Questionlooking for guidelines about c# Pin
priychai6-Mar-07 19:09
priychai6-Mar-07 19:09 
AnswerRe: looking for guidelines about c# Pin
Sandeep Akhare6-Mar-07 19:59
Sandeep Akhare6-Mar-07 19:59 

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.