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 / ValidatorCompatibilityHelper.cs / 1 / 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}); } } } // 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.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}); } } } // 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
- ContextMenuAutomationPeer.cs
- NonBatchDirectoryCompiler.cs
- Int16AnimationUsingKeyFrames.cs
- XmlTextEncoder.cs
- PathData.cs
- ScrollPatternIdentifiers.cs
- TransactionScopeDesigner.cs
- DataFormat.cs
- WindowsFormsSynchronizationContext.cs
- Scanner.cs
- BrowserCapabilitiesCompiler.cs
- CapabilitiesRule.cs
- TypeResolvingOptionsAttribute.cs
- CustomAttributeSerializer.cs
- EventLogPermission.cs
- ThreadStateException.cs
- XmlDeclaration.cs
- Version.cs
- UidManager.cs
- SocketAddress.cs
- CodeArrayIndexerExpression.cs
- Type.cs
- ArgumentValueSerializer.cs
- RadioButton.cs
- HttpException.cs
- PrivilegedConfigurationManager.cs
- UIElement.cs
- Point3DAnimationBase.cs
- WebPartCatalogCloseVerb.cs
- ScriptManager.cs
- TraceLevelStore.cs
- HttpClientChannel.cs
- ipaddressinformationcollection.cs
- NativeMethods.cs
- Transform3DGroup.cs
- KerberosSecurityTokenProvider.cs
- RuleSetDialog.cs
- StructuralType.cs
- Matrix3DStack.cs
- UInt16Storage.cs
- StorageConditionPropertyMapping.cs
- RankException.cs
- ItemsControl.cs
- CoreSwitches.cs
- ClientTargetSection.cs
- WindowsFormsSynchronizationContext.cs
- SqlTypeSystemProvider.cs
- ServiceModelConfigurationSectionCollection.cs
- QueryExecutionOption.cs
- InvokeGenerator.cs
- KoreanLunisolarCalendar.cs
- BitmapPalette.cs
- TemplatedAdorner.cs
- FixedLineResult.cs
- ResourceDictionaryCollection.cs
- SecurityTokenAuthenticator.cs
- NativeMethods.cs
- KeyPressEvent.cs
- Html32TextWriter.cs
- MimeWriter.cs
- ExpressionVisitor.cs
- BStrWrapper.cs
- ControlBindingsCollection.cs
- OptimisticConcurrencyException.cs
- RecipientInfo.cs
- AQNBuilder.cs
- ACL.cs
- ZipPackage.cs
- TextStore.cs
- WebUtility.cs
- InputBinding.cs
- ToolboxItemImageConverter.cs
- ErrorReporting.cs
- Module.cs
- MonitorWrapper.cs
- ITextView.cs
- ObjectMemberMapping.cs
- TargetConverter.cs
- UnsafeNativeMethods.cs
- DocobjHost.cs
- ModelPropertyImpl.cs
- InProcStateClientManager.cs
- MD5.cs
- NavigatingCancelEventArgs.cs
- GeometryModel3D.cs
- DesignerTransactionCloseEvent.cs
- OutputCacheSettings.cs
- IndependentlyAnimatedPropertyMetadata.cs
- ReliableMessagingVersionConverter.cs
- SqlTransaction.cs
- StringDictionary.cs
- SettingsPropertyIsReadOnlyException.cs
- StateMachineSubscription.cs
- SliderAutomationPeer.cs
- RectAnimation.cs
- MessageQueueCriteria.cs
- ColorConverter.cs
- Camera.cs
- XmlDigitalSignatureProcessor.cs
- SqlXmlStorage.cs