Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / xsp / System / Web / UI / WebControls / FormParameter.cs / 1 / FormParameter.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls { using System; using System.ComponentModel; using System.Data; using System.Security.Permissions; ////// Represents a Parameter that gets its value from the application's form parameters. /// [ DefaultProperty("FormField"), ] [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] [AspNetHostingPermission(SecurityAction.InheritanceDemand, Level=AspNetHostingPermissionLevel.Minimal)] public class FormParameter : Parameter { ////// Creates an instance of the FormParameter class. /// public FormParameter() { } ////// Creates an instance of the FormParameter class with the specified parameter name and form field. /// public FormParameter(string name, string formField) : base(name) { FormField = formField; } ////// Creates an instance of the FormParameter class with the specified parameter name, database type, and /// form field. /// public FormParameter(string name, DbType dbType, string formField) : base(name, dbType) { FormField = formField; } ////// Creates an instance of the FormParameter class with the specified parameter name, type, and form field. /// public FormParameter(string name, TypeCode type, string formField) : base(name, type) { FormField = formField; } ////// Used to clone a parameter. /// protected FormParameter(FormParameter original) : base(original) { FormField = original.FormField; } ////// The name of the form parameter to get the value from. /// [ DefaultValue(""), WebCategory("Parameter"), WebSysDescription(SR.FormParameter_FormField), ] public string FormField { get { object o = ViewState["FormField"]; if (o == null) return String.Empty; return (string)o; } set { if (FormField != value) { ViewState["FormField"] = value; OnParameterChanged(); } } } ////// Creates a new FormParameter that is a copy of this FormParameter. /// protected override Parameter Clone() { return new FormParameter(this); } ////// Returns the updated value of the parameter. /// protected override object Evaluate(HttpContext context, Control control) { if (context == null || context.Request == null) { return null; } return context.Request.Form[FormField]; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls { using System; using System.ComponentModel; using System.Data; using System.Security.Permissions; ////// Represents a Parameter that gets its value from the application's form parameters. /// [ DefaultProperty("FormField"), ] [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] [AspNetHostingPermission(SecurityAction.InheritanceDemand, Level=AspNetHostingPermissionLevel.Minimal)] public class FormParameter : Parameter { ////// Creates an instance of the FormParameter class. /// public FormParameter() { } ////// Creates an instance of the FormParameter class with the specified parameter name and form field. /// public FormParameter(string name, string formField) : base(name) { FormField = formField; } ////// Creates an instance of the FormParameter class with the specified parameter name, database type, and /// form field. /// public FormParameter(string name, DbType dbType, string formField) : base(name, dbType) { FormField = formField; } ////// Creates an instance of the FormParameter class with the specified parameter name, type, and form field. /// public FormParameter(string name, TypeCode type, string formField) : base(name, type) { FormField = formField; } ////// Used to clone a parameter. /// protected FormParameter(FormParameter original) : base(original) { FormField = original.FormField; } ////// The name of the form parameter to get the value from. /// [ DefaultValue(""), WebCategory("Parameter"), WebSysDescription(SR.FormParameter_FormField), ] public string FormField { get { object o = ViewState["FormField"]; if (o == null) return String.Empty; return (string)o; } set { if (FormField != value) { ViewState["FormField"] = value; OnParameterChanged(); } } } ////// Creates a new FormParameter that is a copy of this FormParameter. /// protected override Parameter Clone() { return new FormParameter(this); } ////// Returns the updated value of the parameter. /// protected override object Evaluate(HttpContext context, Control control) { if (context == null || context.Request == null) { return null; } return context.Request.Form[FormField]; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- RequestQueryProcessor.cs
- OdbcConnectionStringbuilder.cs
- ConnectorDragDropGlyph.cs
- Line.cs
- DocumentOrderComparer.cs
- DeclarativeCatalogPart.cs
- SQLDateTimeStorage.cs
- PropertyStore.cs
- ObjectAnimationBase.cs
- ImagingCache.cs
- Contracts.cs
- CaseInsensitiveOrdinalStringComparer.cs
- NegotiationTokenAuthenticatorState.cs
- Page.cs
- EastAsianLunisolarCalendar.cs
- ApplicationHost.cs
- ComponentRenameEvent.cs
- ResourceBinder.cs
- SevenBitStream.cs
- SafePEFileHandle.cs
- QuaternionAnimation.cs
- DBSchemaRow.cs
- ServiceModelExtensionElement.cs
- FlowLayout.cs
- FontWeights.cs
- Int64KeyFrameCollection.cs
- ShapingEngine.cs
- CodeSubDirectory.cs
- X509CertificateStore.cs
- Literal.cs
- IconBitmapDecoder.cs
- Pool.cs
- SQLBytesStorage.cs
- PlanCompilerUtil.cs
- BinaryObjectReader.cs
- RedistVersionInfo.cs
- Parameter.cs
- ClientApiGenerator.cs
- XmlDocumentFragment.cs
- InputLanguageProfileNotifySink.cs
- DataContext.cs
- ToolStripItemTextRenderEventArgs.cs
- ServiceNotStartedException.cs
- CollectionBuilder.cs
- ConstrainedGroup.cs
- StatusCommandUI.cs
- DriveNotFoundException.cs
- ResourceDictionaryCollection.cs
- DbDataRecord.cs
- SqlFileStream.cs
- ResourceManager.cs
- SpellerStatusTable.cs
- ExecutionScope.cs
- CellTreeNode.cs
- ConfigurationValidatorBase.cs
- NetMsmqBindingCollectionElement.cs
- ByteBufferPool.cs
- PipelineDeploymentState.cs
- RegisteredScript.cs
- XmlSchemas.cs
- CatchBlock.cs
- WebBrowser.cs
- SqlClientFactory.cs
- SafeNativeMethods.cs
- PathStreamGeometryContext.cs
- KeyFrames.cs
- AsyncInvokeContext.cs
- ConnectionStringsExpressionBuilder.cs
- LazyTextWriterCreator.cs
- GroupBoxAutomationPeer.cs
- Lock.cs
- ReferencedCollectionType.cs
- OutputCacheProviderCollection.cs
- StreamReader.cs
- DesignerOptionService.cs
- PartialArray.cs
- HttpModuleAction.cs
- EdmItemCollection.OcAssemblyCache.cs
- SafeWaitHandle.cs
- RoleManagerEventArgs.cs
- DrawingGroup.cs
- RightsManagementEncryptionTransform.cs
- RemotingSurrogateSelector.cs
- CollectionConverter.cs
- SystemIPAddressInformation.cs
- BrowsableAttribute.cs
- odbcmetadatacollectionnames.cs
- ControlBuilder.cs
- COM2IPerPropertyBrowsingHandler.cs
- TextBoxBase.cs
- UInt64Converter.cs
- safesecurityhelperavalon.cs
- SendMailErrorEventArgs.cs
- ColumnTypeConverter.cs
- ContactManager.cs
- ObjectManager.cs
- InternalUserCancelledException.cs
- TableRow.cs
- Converter.cs
- HMACSHA1.cs