Prevent modifying Attribute

C

Chris Zopers

Hello,

We've developed a Web Application with inputforms that are being
generated dynamically, including all WebControls on the forms.

In each WebControl we save some data in specific Attributes, so when the
user clicks a Save button, we have some extra information for each
WebControl.

For Example:

TextBox txb = New TextBox();
txb.Attributes["NewExampleAttribute"] = "HelloWorld";

This Attribute is of course invisble to the user. But when a User has
installed the Developer Toolbar, he can find the control and view it's
attributes. But he can also modify the value of those attributes and we
don't want that. Is there a way to prevent this? As far as I can see,
the AttributesCollection is of type String, so no settings can be
applied to make a new Attribute readonly.

Greetings,
Chris
 
G

Guest

Hello,

We've developed a Web Application with inputforms that are being
generated dynamically, including all WebControls on the forms.

In each WebControl we save some data in specific Attributes, so when the
user clicks a Save button, we have some extra information for each
WebControl.

For Example:

TextBox txb = New TextBox();
txb.Attributes["NewExampleAttribute"] = "HelloWorld";

This Attribute is of course invisble to the user. But when a User has
installed the Developer Toolbar, he can find the control and view it's
attributes. But he can also modify the value of those attributes and we
don't want that. Is there a way to prevent this? As far as I can see,
the AttributesCollection is of type String, so no settings can be
applied to make a new Attribute readonly.

Greetings,
Chris

*** Sent via Developersdexhttp://www.developersdex.com***

What is "Developer Toolbar"? If it's a kind of debug/hack extension
than it probably may modify everything in the output.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top