Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 588977
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T15:22:32+00:00 2026-05-13T15:22:32+00:00

I have been banging my head against this for a little while now. I

  • 0

I have been banging my head against this for a little while now. I just can’t seem to get intellisense to work in a ascx user control, but it works fine in a plain old aspx.

Here is a sample aspx page:

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="TestScriptLoader._Default" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
    <asp:ScriptManager ID="scriptManager" ScriptMode="Debug" runat="server" >
        <Scripts>
            <asp:ScriptReference Path="http://ajax.microsoft.com/ajax/beta/0910/Start.js" ScriptMode="Inherit" />
        </Scripts>
    </asp:ScriptManager>

    </form>
    <script type="text/javascript">

    </script>
</body>
</html>

I get intellisense for MicrosoftAjax in the script tag there, once I’ve updated javascript intellisense (CTR+SHIFT+J).

In the ascx file

<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="Test.ascx.cs" Inherits="TestScriptLoader.Test" %>

<asp:ScriptManagerProxy ID="scriptManagerProxy" runat="server">
    <Scripts>
        <asp:ScriptReference Path="http://ajax.microsoft.com/ajax/beta/0910/Start.js" ScriptMode="Inherit" />
    </Scripts>
</asp:ScriptManagerProxy>

<script type="text/javascript">

</script>

I get no such joy.

The only thing I can think of is to do all the coding for the user controls in a seperate JS file, but there is a one to one mapping for the functionality that I want in specific usercontrols to the javascript I will write for them, and the user control will only appear once in a page. Basically I don’t want to go down this path if not absolutely neccesary.

EDIT

I also need to be able to add service references to these controls, and have intellisense available.

EDIT

It just struck me that the problem I’m up against is that I’m using a scriptmanagerproxy inside a usercontrol. The usercontrol has no way of knowing which ScriptManager it is to associate with, so that is why the javascript intellisense is not being updated.

I can verify this by changing the scriptmanagerproxy to a scriptmanager control, and intellisense works for both the script and service references.

EDIT

I also thought I could just stick an <asp:ScriptManager> into the page, wrapped in alligator clips:

<% if(false) { %>
    <asp:ScriptManager ID="fakeScriptManager" runat="server"/>
<% } %>


<asp:ScriptManagerProxy ID="scriptManagerProxy" runat="server">
    <Services>
        <asp:ServiceReference Path="~/path/to/your.svc" />
    </Services>
</asp:ScriptManagerProxy>

That appeared to work, but the <% if(false) %> does not prevent the control from being built…

Any ideas on how to get this to happen?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T15:22:32+00:00Added an answer on May 13, 2026 at 3:22 pm

    As this question has gone dead, I’m going to put an answer in here.

    No. It is not possible. The reason is that there is no way for Visual Studio to know which scriptmanager control the scripmanagerproxy is supposed to be referencing, so it doesn’t reference any script manager. Therefore the intellisense is unavailable whilst editing the control.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have been banging my head against this one for a while now and
I have been banging my head against this for some time now: I want
I've been banging my head against this issue for a while now and I'm
I have been banging my head against the wall with this odd behaviour on
I have been banging my head on and on, i cant seem to work
I've been banging my head against this for the past two days and can't
Been banging my head against this problem all morning. I have setup a connection
Been banging my head against this for a while. I cant figure out why
So, I've been banging my head against the wall with this, and I can't
I've been banging my head against this for too long. I have two ViewControllers

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.