Script manager equivalent... How can I do?

Discussion in 'ASP .Net Web Controls' started by ThunderMusic, Feb 14, 2007.

  1. ThunderMusic

    ThunderMusic Guest

    Hi,
    I know there is something called (something like) Script Manager in asp.net
    AJAX... What is the best way of achieving the kind of behavior it has? I
    mean, maybe I didn't understand it correctly, but as I understand it, many
    (if not all) asp.net AJAX control gets the Script manager (in the Head of
    the page) and send the script is must have in the page header... I want to
    achieve the same... what is the best way?
     
    ThunderMusic, Feb 14, 2007
    #1
    1. Advertising

  2. ThunderMusic

    ThunderMusic Guest

    oups, sorry, I sent it inadvertadly... ;) so, as I was saying, What is the
    best way to achieve this?

    1) Put it in the head, then in my controls, get the page and go through all
    the controls to find the script manager, then keep a reference to it for
    future use?
    2) Create a web control that will also be a singleton (is it possible)
    3) any other ideas?

    thanks

    ThunderMusic

    "ThunderMusic" <> wrote in message
    news:%...
    > Hi,
    > I know there is something called (something like) Script Manager in
    > asp.net AJAX... What is the best way of achieving the kind of behavior it
    > has? I mean, maybe I didn't understand it correctly, but as I understand
    > it, many (if not all) asp.net AJAX control gets the Script manager (in the
    > Head of the page) and send the script is must have in the page header...
    > I want to achieve the same... what is the best way?
    >
     
    ThunderMusic, Feb 14, 2007
    #2
    1. Advertising

  3. ThunderMusic

    Teemu Keiski Guest

    Hi,

    why not using something that's already done? E.g use the ScriptManager
    itself.

    In your control you can use System.Web.UI.ScriptManager.GetCurrent
    (shared/static method taking the Page in) to get the ASP.NET Ajax
    ScriptManager on the Page (method returns null if it doesn't exist)

    --
    Teemu Keiski
    AspInsider, ASP.NET MVP
    http://blogs.aspadvice.com/joteke
    http://teemukeiski.net


    "ThunderMusic" <> wrote in message
    news:%...
    > oups, sorry, I sent it inadvertadly... ;) so, as I was saying, What is
    > the best way to achieve this?
    >
    > 1) Put it in the head, then in my controls, get the page and go through
    > all the controls to find the script manager, then keep a reference to it
    > for future use?
    > 2) Create a web control that will also be a singleton (is it possible)
    > 3) any other ideas?
    >
    > thanks
    >
    > ThunderMusic
    >
    > "ThunderMusic" <> wrote in message
    > news:%...
    >> Hi,
    >> I know there is something called (something like) Script Manager in
    >> asp.net AJAX... What is the best way of achieving the kind of behavior it
    >> has? I mean, maybe I didn't understand it correctly, but as I understand
    >> it, many (if not all) asp.net AJAX control gets the Script manager (in
    >> the Head of the page) and send the script is must have in the page
    >> header... I want to achieve the same... what is the best way?
    >>

    >
    >
     
    Teemu Keiski, Feb 14, 2007
    #3
  4. ThunderMusic

    ThunderMusic Guest

    just because we're not using asp.net Ajax for our site... ;) I used this
    example because I looked at asp.net ajax briefly in the past months, but
    we're not planning on using it right now... but you answered my question
    anyway, asp.net ajax script manager is used by getting a reference using a
    static method... that's what I wanted to know...

    Thanks a lot

    ThunderMusic

    "Teemu Keiski" <> wrote in message
    news:...
    > Hi,
    >
    > why not using something that's already done? E.g use the ScriptManager
    > itself.
    >
    > In your control you can use System.Web.UI.ScriptManager.GetCurrent
    > (shared/static method taking the Page in) to get the ASP.NET Ajax
    > ScriptManager on the Page (method returns null if it doesn't exist)
    >
    > --
    > Teemu Keiski
    > AspInsider, ASP.NET MVP
    > http://blogs.aspadvice.com/joteke
    > http://teemukeiski.net
    >
    >
    > "ThunderMusic" <> wrote in message
    > news:%...
    >> oups, sorry, I sent it inadvertadly... ;) so, as I was saying, What is
    >> the best way to achieve this?
    >>
    >> 1) Put it in the head, then in my controls, get the page and go through
    >> all the controls to find the script manager, then keep a reference to it
    >> for future use?
    >> 2) Create a web control that will also be a singleton (is it possible)
    >> 3) any other ideas?
    >>
    >> thanks
    >>
    >> ThunderMusic
    >>
    >> "ThunderMusic" <> wrote in message
    >> news:%...
    >>> Hi,
    >>> I know there is something called (something like) Script Manager in
    >>> asp.net AJAX... What is the best way of achieving the kind of behavior
    >>> it has? I mean, maybe I didn't understand it correctly, but as I
    >>> understand it, many (if not all) asp.net AJAX control gets the Script
    >>> manager (in the Head of the page) and send the script is must have in
    >>> the page header... I want to achieve the same... what is the best way?
    >>>

    >>
    >>

    >
     
    ThunderMusic, Feb 14, 2007
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. ThunderMusic

    Script manager equivalent... How can I do?

    ThunderMusic, Feb 14, 2007, in forum: ASP .Net
    Replies:
    3
    Views:
    386
    ThunderMusic
    Feb 14, 2007
  2. =?Utf-8?B?UmFq?=

    Script Manager - Confirm dialog box

    =?Utf-8?B?UmFq?=, May 18, 2007, in forum: ASP .Net
    Replies:
    1
    Views:
    2,895
    Thomas Hansen
    May 18, 2007
  3. Valli
    Replies:
    1
    Views:
    1,127
    Mike Placentra II
    Oct 3, 2007
  4. padma
    Replies:
    0
    Views:
    360
    padma
    Oct 3, 2007
  5. Metalone
    Replies:
    0
    Views:
    350
    Metalone
    Jan 6, 2010
Loading...

Share This Page