Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / 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}); } } } // 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
- CollectionEditorDialog.cs
- Executor.cs
- CurrencyWrapper.cs
- _SSPIWrapper.cs
- ManagedFilter.cs
- EdmComplexPropertyAttribute.cs
- VisualStyleRenderer.cs
- DataGridView.cs
- GridToolTip.cs
- CodeAssignStatement.cs
- XmlDeclaration.cs
- ProfileSettings.cs
- ContainerParaClient.cs
- NaturalLanguageHyphenator.cs
- DataGridItemEventArgs.cs
- SqlFacetAttribute.cs
- MobileSysDescriptionAttribute.cs
- MemberDescriptor.cs
- ScriptControlManager.cs
- PropertyChangingEventArgs.cs
- OutputScopeManager.cs
- XmlSchemaAll.cs
- WebSysDisplayNameAttribute.cs
- FigureParagraph.cs
- Logging.cs
- DocumentOrderQuery.cs
- ProviderBase.cs
- TypeBuilder.cs
- CodeDomSerializerBase.cs
- ServiceObjectContainer.cs
- ImmutableObjectAttribute.cs
- XmlText.cs
- HttpConfigurationSystem.cs
- WorkflowOwnershipException.cs
- HtmlTableCellCollection.cs
- WebPartAddingEventArgs.cs
- TreeNodeSelectionProcessor.cs
- XmlSchema.cs
- CompositeDuplexBindingElement.cs
- ScrollBar.cs
- DefaultAssemblyResolver.cs
- Rect.cs
- ArcSegment.cs
- ChunkedMemoryStream.cs
- StringFreezingAttribute.cs
- ExpandableObjectConverter.cs
- TranslateTransform3D.cs
- NetCodeGroup.cs
- TreeWalkHelper.cs
- SchemaCompiler.cs
- FilteredAttributeCollection.cs
- PerfService.cs
- NotSupportedException.cs
- DeferredSelectedIndexReference.cs
- EmptyQuery.cs
- UserControlBuildProvider.cs
- DesignerTransactionCloseEvent.cs
- SqlNamer.cs
- DataGridItemEventArgs.cs
- ClientBuildManagerCallback.cs
- WpfKnownMemberInvoker.cs
- DataFormats.cs
- FontCacheLogic.cs
- Model3DCollection.cs
- DataTemplate.cs
- LabelAutomationPeer.cs
- WebMessageEncoderFactory.cs
- StringSource.cs
- SafeNativeMethodsOther.cs
- PerformanceCounterManager.cs
- InvalidAsynchronousStateException.cs
- SizeChangedEventArgs.cs
- MemoryFailPoint.cs
- LocationUpdates.cs
- PrintPageEvent.cs
- GraphicsPathIterator.cs
- SystemFonts.cs
- ResourcesChangeInfo.cs
- Splitter.cs
- Win32KeyboardDevice.cs
- XmlNavigatorStack.cs
- MethodRental.cs
- ClearTypeHintValidation.cs
- AnnotationHighlightLayer.cs
- jithelpers.cs
- ProfileService.cs
- BulletChrome.cs
- NTAccount.cs
- MediaElementAutomationPeer.cs
- MatrixTransform3D.cs
- CqlParser.cs
- RoutedEventHandlerInfo.cs
- SortAction.cs
- CommonXSendMessage.cs
- WindowsFormsHostAutomationPeer.cs
- Vector3DConverter.cs
- FixUpCollection.cs
- TableParaClient.cs
- IconConverter.cs
- WindowsFormsHelpers.cs