Can't use CuteChat with CuteMessenger on the same page

Last post 10-15-2008, 8:52 AM by VasylP. 7 replies.
Sort Posts: Previous Next
  •  10-10-2008, 7:08 AM 44776

    Can't use CuteChat with CuteMessenger on the same page

    When we place CuteChat with CuteMessenger on the same page, following error occurs:
     
    Microsoft JScript runtime error: Already Initialized!
     
    Is not it possible to use chat with messenger simultaneously?
     
    Thanks,
    Vasyl
  •  10-10-2008, 7:47 AM 44777 in reply to 44776

    Re: Can't use CuteChat with CuteMessenger on the same page

    Hi VasylP,
     
    1.Open root\CuteChat\CuteSoft_Client\CuteChat\EmbedChannel.ascx
     
    2.Find the code'<script src='<%=ResolveUrl("EmbedChannel.js")%>'></script>' and comment it
     
    3.Try again
     
     
    Regards,
     
    Ken
     
  •  10-10-2008, 11:42 AM 44786 in reply to 44777

    Re: Can't use CuteChat with CuteMessenger on the same page

    Ken,

    When we comment this code, chat became inoperative. Any other ideas?
     
    Vasyl
  •  10-11-2008, 2:46 AM 44808 in reply to 44786

    Re: Can't use CuteChat with CuteMessenger on the same page

    Hi Vasy,
     
    you can try this way:
     
    Create another 'EmbedChannel.ascx'(you only need to copy the code)
     
    when you need cutechat alone,please use the 'EmbedChannel.ascx' which not comment this code
     
    when you nedd cutechat and messenger use in one page,please use the  'EmbedChannel.ascx' which comment this code
     
     
    Regards,
     
    Ken
  •  10-12-2008, 4:42 AM 44820 in reply to 44776

    Re: Can't use CuteChat with CuteMessenger on the same page

    Vasyl:
     
    That because the HtmlInitialize() function be called twice.
     
    you can try to fix it by this way , put the script after </body> :
     
    <script>
    var old_HtmlInitialize=HtmlInitialize;
    HtmlInitialize=function()
    {
        try{ old_HtmlInitialize() }catch(x){}
    }
    </script>
     
    Regards , Terry .
  •  10-14-2008, 1:54 PM 44881 in reply to 44820

    Re: Can't use CuteChat with CuteMessenger on the same page

    Guys,

    Your solutions hide errors, but I can't work with chat after this. I see neither field to type a message nor button "Send" nor any other controls. Only toolbar (with fonts, smiles, etc.) is available.
    Here is a snip of code I use:

    <%@ Register TagPrefix="CuteChat" TagName="EmbedChannel" Src="EmbedChannel.ascx" %>
    <%@ Register TagPrefix="CuteChat" TagName="EmbedMessenger" Src="EmbedMessenger.ascx" %>

    <!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>Untitled Page</title>
    </head>
    <body>
        <form id="form1" runat="server">
        <div>
           <script>
             Embed_Place='Lobby-1'
           </script>
           <CuteChat:EmbedChannel id="EmbedChannel1" runat="server"></CuteChat:EmbedChannel>
        </div>
        <div>
           <CuteChat:EmbedMessenger id="EmbedMessenger1" runat="server"></CuteChat:EmbedMessenger>
        </div>
        </form>
    </body>

    <script>
    var old_HtmlInitialize=HtmlInitialize;
    HtmlInitialize=function()
    {
        try{ old_HtmlInitialize() }catch(x){}
    }
    </script>

    </html>


     What I am doing wrong?

    Thanks,

    Vasyl

  •  10-14-2008, 8:39 PM 44883 in reply to 44881

    Re: Can't use CuteChat with CuteMessenger on the same page

    Hi,
     
    We have investigated this issue , and have found that it's not possible to make two chat application into same page.
     
    Because all functions/variable is decalred as global , and only one chat connection can be created on one page.
     
    When we design the CuteChat , we did not expect this scene. Sorry.
     
    Regards , Terry.
     
     
     
     
  •  10-15-2008, 8:52 AM 44899 in reply to 44883

    Re: Can't use CuteChat with CuteMessenger on the same page

    I see.
    Thanks a lot for looking!
View as RSS news feed in XML