Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to disable the Addnew button after click ?
Message
From
01/12/2010 05:48:18
 
 
To
01/12/2010 05:40:52
Yim Ming Sun Derek
Spacious Design Consultant
Hong Kong, Hong Kong
General information
Forum:
ASP.NET
Category:
Coding, syntax and commands
Environment versions
Environment:
VB 9.0
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
MS SQL Server
Application:
Desktop
Miscellaneous
Thread ID:
01491331
Message ID:
01491345
Views:
36
>Hi,
>I set the code in the Addnew button click event.
>theBindingSource.AllowNew = false
>
>but it return an error that "Item cannot be added to a read-only or fixed-size list."

Are you sure that that is the line throwing the exception rather than the attempt to actually add an item? The documentation only mentions exceptions when setting the AllowNew property to true :http://msdn.microsoft.com/en-us/library/system.windows.forms.bindingsource.allownew.aspx
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform