Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / fx / src / xsp / System / Web / UI / WebControls / ValidatorCompatibilityHelper.cs / 3 / ValidatorCompatibilityHelper.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls { using System.Globalization; using System.Reflection; using System.Web.Util; // Needed to support Validators in AJAX 1.0 (Windows OS Bugs 2015831) internal static class ValidatorCompatibilityHelper { public static void RegisterArrayDeclaration(Control control, string arrayName, string arrayValue) { Type scriptManagerType = control.Page.ScriptManagerType; Debug.Assert(scriptManagerType != null); scriptManagerType.InvokeMember("RegisterArrayDeclaration", BindingFlags.Public | BindingFlags.Static | BindingFlags.InvokeMethod, null, /*binder*/ null, /*target*/ new object[] {control, arrayName, arrayValue}); } public static void RegisterClientScriptResource(Control control, Type type, string resourceName) { Type scriptManagerType = control.Page.ScriptManagerType; Debug.Assert(scriptManagerType != null); scriptManagerType.InvokeMember("RegisterClientScriptResource", BindingFlags.Public | BindingFlags.Static | BindingFlags.InvokeMethod, null, /*binder*/ null, /*target*/ new object[] {control, type, resourceName}); } public static void RegisterExpandoAttribute(Control control, string controlId, string attributeName, string attributeValue, bool encode) { Type scriptManagerType = control.Page.ScriptManagerType; Debug.Assert(scriptManagerType != null); scriptManagerType.InvokeMember("RegisterExpandoAttribute", BindingFlags.Public | BindingFlags.Static | BindingFlags.InvokeMethod, null, /*binder*/ null, /*target*/ new object[] {control, controlId, attributeName, attributeValue, encode}); } public static void RegisterOnSubmitStatement(Control control, Type type, string key, string script) { Type scriptManagerType = control.Page.ScriptManagerType; Debug.Assert(scriptManagerType != null); scriptManagerType.InvokeMember("RegisterOnSubmitStatement", BindingFlags.Public | BindingFlags.Static | BindingFlags.InvokeMethod, null, /*binder*/ null, /*target*/ new object[] {control, type, key, script}); } public static void RegisterStartupScript(Control control, Type type, string key, string script, bool addScriptTags) { Type scriptManagerType = control.Page.ScriptManagerType; Debug.Assert(scriptManagerType != null); scriptManagerType.InvokeMember("RegisterStartupScript", BindingFlags.Public | BindingFlags.Static | BindingFlags.InvokeMethod, null, /*binder*/ null, /*target*/ new object[] {control, type, key, script, addScriptTags}); } } }
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- EventDriven.cs
- ToolStripStatusLabel.cs
- TextCollapsingProperties.cs
- ClientBuildManager.cs
- SqlProviderUtilities.cs
- Classification.cs
- BatchServiceHost.cs
- Clock.cs
- ProtocolsSection.cs
- CodeAttributeArgument.cs
- RegisteredDisposeScript.cs
- TypedServiceChannelBuilder.cs
- ServicePointManager.cs
- UrlMapping.cs
- Tile.cs
- HyperLinkField.cs
- SignatureConfirmationElement.cs
- TreeView.cs
- DependencyObjectProvider.cs
- CallId.cs
- Asn1IntegerConverter.cs
- SuppressMergeCheckAttribute.cs
- BindingOperations.cs
- RenderData.cs
- TriggerActionCollection.cs
- SqlBulkCopyColumnMapping.cs
- httpserverutility.cs
- RecoverInstanceLocksCommand.cs
- XamlTreeBuilderBamlRecordWriter.cs
- TrackBar.cs
- InputBinder.cs
- EmptyStringExpandableObjectConverter.cs
- IdentitySection.cs
- ObjectParameterCollection.cs
- ProxyGenerationError.cs
- WeakReferenceList.cs
- JulianCalendar.cs
- MouseActionConverter.cs
- VisualStyleInformation.cs
- HttpVersion.cs
- ToolStripContentPanel.cs
- TextParagraphView.cs
- ObjectHelper.cs
- QuadraticEase.cs
- SelectionEditingBehavior.cs
- EpmCustomContentWriterNodeData.cs
- CodeGenerator.cs
- SourceChangedEventArgs.cs
- TextSpan.cs
- Pool.cs
- FormatVersion.cs
- LinkedResource.cs
- Margins.cs
- Rule.cs
- ContextMenuAutomationPeer.cs
- InputMethodStateChangeEventArgs.cs
- RuleSetBrowserDialog.cs
- TableHeaderCell.cs
- ManagementPath.cs
- DataServiceException.cs
- ImageKeyConverter.cs
- BindingContext.cs
- TextEditorTyping.cs
- DriveInfo.cs
- XPathNodeHelper.cs
- CredentialManagerDialog.cs
- CustomAttributeBuilder.cs
- IndexingContentUnit.cs
- UntrustedRecipientException.cs
- CRYPTPROTECT_PROMPTSTRUCT.cs
- ExternalException.cs
- WindowsStatic.cs
- TableLayoutPanelCellPosition.cs
- ActivityBindForm.cs
- XmlSchemaSimpleTypeList.cs
- XmlSchemaInclude.cs
- LinkTarget.cs
- XamlContextStack.cs
- DoubleAnimationUsingKeyFrames.cs
- AdjustableArrowCap.cs
- HitTestParameters3D.cs
- WindowsComboBox.cs
- XmlTextAttribute.cs
- EventHandlersStore.cs
- TypeSource.cs
- FlowDocument.cs
- CheckBox.cs
- EDesignUtil.cs
- EntityDataSourceChangedEventArgs.cs
- GenericTextProperties.cs
- FileDetails.cs
- HttpHandlerActionCollection.cs
- CatalogPart.cs
- PageContentCollection.cs
- Array.cs
- AudioSignalProblemOccurredEventArgs.cs
- InsufficientMemoryException.cs
- UnsafeNativeMethods.cs
- DeclaredTypeElementCollection.cs
- IPipelineRuntime.cs