Click here to Skip to main content
16,005,037 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: HTTP 500 - Internal server error Pin
N a v a n e e t h11-Oct-07 21:14
N a v a n e e t h11-Oct-07 21:14 
GeneralRe: HTTP 500 - Internal server error [modified] Pin
leenav11-Oct-07 21:57
leenav11-Oct-07 21:57 
GeneralRe: HTTP 500 - Internal server error Pin
N a v a n e e t h11-Oct-07 23:50
N a v a n e e t h11-Oct-07 23:50 
GeneralRe: HTTP 500 - Internal server error Pin
Vasudevan Deepak Kumar12-Oct-07 0:15
Vasudevan Deepak Kumar12-Oct-07 0:15 
QuestionIMsgStore.OpenEntry: MAPI_E_INVALID_ENTRYID problem Pin
pjc*11-Oct-07 20:52
pjc*11-Oct-07 20:52 
QuestionCollection editor problem Pin
Ujjaval Modi11-Oct-07 20:51
Ujjaval Modi11-Oct-07 20:51 
AnswerRe: Collection editor problem Pin
Sandeep Akhare11-Oct-07 21:57
Sandeep Akhare11-Oct-07 21:57 
GeneralRe: Collection editor problem Pin
Ujjaval Modi13-Oct-07 0:22
Ujjaval Modi13-Oct-07 0:22 
I have tried debugging the application by putting breakpoints.

Here's the code :
First of all I designed a class for creating a List Collection :

using System;
using System.Collections.Generic;
using System.Text;
using System.Collections;

namespace Funnel
{
public class SectionValue : CollectionBase
{
public double this[int index]
{
get
{
return ((double)List[index]);
}
set
{
List[index] = value;
}

}

public int Add(double value)
{
return (List.Add(value));
}

public int Add(string value)
{
try
{
double c = Convert.ToDouble(value);
return (List.Add(c));
}
catch (Exception)
{
throw new ArgumentException(string.Format(
"Error converting the given string '{0}' to a color",
value), "value");
}
}
public bool Contains(double value)
{
// If value is not of type Color, this will return false.
return (List.Contains(value));
}


public int IndexOf(double value)
{
return (List.IndexOf(value));
}
public void Insert(int index, double value)
{
List.Insert(index, value);
}
public void Remove(double value)
{
List.Remove(value);
}

public SectionValue(double[] sections) : base()
{
foreach (double s in sections)
{
this.Add(s);
}
}

public SectionValue()
: base()
{}
}
}

Then I use object of the class in my control as follows :

protected SectionValue m_SectionValue;

and write property for it as follows :


[Bindable(true)
, Category("Appearance")
, Browsable(true)
, PersistenceMode(PersistenceMode.Attribute)
, DesignerSerializationVisibility(DesignerSerializationVisibility.Content)
]

public SectionValue UserDefinedSection
{
get
{
if (m_SectionValue == null)
m_SectionValue = new SectionValue();

return m_SectionValue;
}
set
{
m_SectionValue = value;
}
}


Now this code is working perfectly regarding displaying the collection editor and add/deleting values from it. Even I am able to add/delete values from code-behind.
But the values added during design time do not get reflected at run-time. If I assign values to collection from code-behind file then the values get reflected at run-time but not from design-time.

Regards,
Ujjaval Modi. Smile | :)
Questionauthentication Pin
venky45611-Oct-07 20:46
venky45611-Oct-07 20:46 
AnswerRe: authentication Pin
Aavesh Agarwal11-Oct-07 20:57
Aavesh Agarwal11-Oct-07 20:57 
QuestionRegarding deployment of project in Asp.net2.0 Pin
Aavesh Agarwal11-Oct-07 20:38
Aavesh Agarwal11-Oct-07 20:38 
Questionupdate dll Pin
Mri1a11-Oct-07 20:25
Mri1a11-Oct-07 20:25 
AnswerRe: update dll Pin
Aavesh Agarwal11-Oct-07 21:06
Aavesh Agarwal11-Oct-07 21:06 
GeneralRe: update dll Pin
Mri1a11-Oct-07 21:31
Mri1a11-Oct-07 21:31 
GeneralRe: update dll Pin
Mri1a11-Oct-07 22:17
Mri1a11-Oct-07 22:17 
QuestionPassing values through header Pin
Malayil alex11-Oct-07 20:17
Malayil alex11-Oct-07 20:17 
AnswerRe: Passing values through header Pin
Sandeep Akhare11-Oct-07 20:23
Sandeep Akhare11-Oct-07 20:23 
AnswerRe: Passing values through header Pin
N a v a n e e t h11-Oct-07 20:24
N a v a n e e t h11-Oct-07 20:24 
GeneralRe: Passing values through header Pin
Malayil alex11-Oct-07 20:31
Malayil alex11-Oct-07 20:31 
GeneralRe: Passing values through header Pin
N a v a n e e t h11-Oct-07 21:09
N a v a n e e t h11-Oct-07 21:09 
GeneralRe: Passing values through header Pin
Guffa11-Oct-07 21:25
Guffa11-Oct-07 21:25 
GeneralRe: Passing values through header Pin
N a v a n e e t h11-Oct-07 21:28
N a v a n e e t h11-Oct-07 21:28 
GeneralRe: Passing values through header Pin
Sandeep Akhare11-Oct-07 21:48
Sandeep Akhare11-Oct-07 21:48 
GeneralRe: Passing values through header Pin
Malayil alex11-Oct-07 22:01
Malayil alex11-Oct-07 22:01 
AnswerRe: Passing values through header Pin
Guffa12-Oct-07 3:35
Guffa12-Oct-07 3:35 

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.