Add ScriptManager to Page Programmatically?

后端 未结 7 2041
夕颜
夕颜 2020-12-13 00:30

I am developing a WebPart (it will be used in a SharePoint environment, although it does not use the Object Model) that I want to expose AJAX functionality in. Because of t

相关标签:
7条回答
  • 2020-12-13 01:36

    I had this similar problem and found the best way was to add a global ScriptManager to the masterpage then in the code behind you can add to it by:

    ScriptManager.GetCurrent(Page).Services.Add(new ServiceReference(virtualPath));
    
    0 讨论(0)
提交回复
热议问题