Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / whidbey / NetFXspW7 / 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
- LinkClickEvent.cs
- ToolBarDesigner.cs
- DataGridState.cs
- EventSourceCreationData.cs
- ILGenerator.cs
- AnnotationAuthorChangedEventArgs.cs
- ExceptionHandlersDesigner.cs
- DataFormat.cs
- SqlNotificationRequest.cs
- columnmapfactory.cs
- QuaternionConverter.cs
- SafeNativeMethodsCLR.cs
- BinaryKeyIdentifierClause.cs
- HMACSHA512.cs
- OracleFactory.cs
- dsa.cs
- InputScopeAttribute.cs
- HttpModulesSection.cs
- DbXmlEnabledProviderManifest.cs
- ControlPropertyNameConverter.cs
- TextDecoration.cs
- SmtpAuthenticationManager.cs
- ApplicationSecurityInfo.cs
- FragmentNavigationEventArgs.cs
- List.cs
- TransportBindingElementImporter.cs
- NetCodeGroup.cs
- QueryCacheKey.cs
- SchemaTableColumn.cs
- SynchronizationLockException.cs
- ListBoxAutomationPeer.cs
- DataGridViewColumn.cs
- ObjectDataSourceMethodEventArgs.cs
- ContainerParaClient.cs
- PrePostDescendentsWalker.cs
- DoubleLinkListEnumerator.cs
- ObjectAssociationEndMapping.cs
- SendKeys.cs
- PasswordRecovery.cs
- QuotaExceededException.cs
- TypeDescriptionProvider.cs
- EmbeddedMailObjectsCollection.cs
- SafeEventLogWriteHandle.cs
- DataControlFieldHeaderCell.cs
- Tokenizer.cs
- Identity.cs
- XmlBinaryWriterSession.cs
- PropertyEmitterBase.cs
- XmlHierarchicalEnumerable.cs
- UserControlBuildProvider.cs
- TraceEventCache.cs
- SQLCharsStorage.cs
- TypeListConverter.cs
- SqlCommandBuilder.cs
- TransformerTypeCollection.cs
- PeerHelpers.cs
- BitmapSource.cs
- WebPartDisplayModeCollection.cs
- FileUtil.cs
- TableCellCollection.cs
- WebBrowserBase.cs
- AnnotationResource.cs
- Bold.cs
- WebPartTransformerCollection.cs
- CommandHelper.cs
- FamilyMapCollection.cs
- UndirectedGraph.cs
- DataGridViewRowHeightInfoNeededEventArgs.cs
- WorkflowApplicationUnloadedException.cs
- ConsumerConnectionPoint.cs
- ModelUIElement3D.cs
- CodeAttributeArgument.cs
- Queue.cs
- MediaTimeline.cs
- Pool.cs
- ProfileManager.cs
- FileRecordSequenceHelper.cs
- XpsFontSubsetter.cs
- ProcessRequestArgs.cs
- ParseChildrenAsPropertiesAttribute.cs
- CommonProperties.cs
- BuildResult.cs
- ProjectionCamera.cs
- MetadataArtifactLoaderXmlReaderWrapper.cs
- UrlAuthorizationModule.cs
- Certificate.cs
- CompositeActivityValidator.cs
- Camera.cs
- WindowsListViewScroll.cs
- StylusPointCollection.cs
- EncryptedKey.cs
- Span.cs
- MetadataImporter.cs
- TrackingStringDictionary.cs
- FaultDesigner.cs
- WebPartMinimizeVerb.cs
- DecoderFallbackWithFailureFlag.cs
- RuleEngine.cs
- TextServicesContext.cs
- SamlAuthorityBinding.cs