Intersoft WebGrid Documentation
AllowAddNew Property
See Also  Example Send Feedback
ISNet.WebUI.WebGrid Namespace > LayoutSet Class : AllowAddNew Property






Specifies whether the user is allowed to add new row(s).

Syntax

Visual Basic (Declaration) 
<NotifyParentPropertyAttribute(True)>
<DefaultValueAttribute()>
<DescriptionAttribute("Specifies whether or not to allow users add new row.")>
<ISNet.Serialization.BinarySerializableAttribute()>
<ISNet.Serialization.XmlSerializableAttribute()>
Public Property AllowAddNew As AddNew
Visual Basic (Usage)Copy Code
Dim instance As LayoutSet
Dim value As AddNew
 
instance.AllowAddNew = value
 
value = instance.AllowAddNew
C# 
[NotifyParentPropertyAttribute(true)]
[DefaultValueAttribute()]
[DescriptionAttribute("Specifies whether or not to allow users add new row.")]
[ISNet.Serialization.BinarySerializableAttribute()]
[ISNet.Serialization.XmlSerializableAttribute()]
public AddNew AllowAddNew {get; set;}
Delphi 
public read-write property AllowAddNew: AddNew; 
JScript 
NotifyParentPropertyAttribute()
DefaultValueAttribute()
DescriptionAttribute("Specifies whether or not to allow users add new row.")
ISNet.Serialization.BinarySerializableAttribute()
ISNet.Serialization.XmlSerializableAttribute()
public function get,set AllowAddNew : AddNew
Managed Extensions for C++ 
[NotifyParentPropertyAttribute(true)]
[DefaultValueAttribute()]
[DescriptionAttribute("Specifies whether or not to allow users add new row.")]
[ISNet.Serialization.BinarySerializableAttribute()]
[ISNet.Serialization.XmlSerializableAttribute()]
public: __property AddNew get_AllowAddNew();
public: __property void set_AllowAddNew( 
   AddNew value
);
C++/CLI 
[NotifyParentPropertyAttribute(true)]
[DefaultValueAttribute()]
[DescriptionAttribute("Specifies whether or not to allow users add new row.")]
[ISNet.Serialization.BinarySerializableAttribute()]
[ISNet.Serialization.XmlSerializableAttribute()]
public:
property AddNew AllowAddNew {
   AddNew get();
   void set (    AddNew value);
}

Example

 

The sample code below shows you how to set the AllowAddNew property programmatically.
C#Copy Code
private void WebGrid1_InitializeLayout(object sender, ISNet.WebUI.WebGrid.LayoutEventArgs e)
{
        e.Layout.AllowAddNew = ISNet.WebUI.WebGrid.AddNew.Yes;
}

Remarks

In order to add new data, users can add new row by setting the AllowAddNew property in LayoutSettings to True. Then users can insert the new data into the new row. For more information regarding editing functionalities you can read Editing Environment

Requirements

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family

See Also

Reference

LayoutSet Class
LayoutSet Members

Tasks

How-to: Perform adding a new row

Other Resources

Editing Environment
Rich User Interface Elements

©2012 Intersoft Solutions Corp. All Rights Reserved.