When using programatically Editor.CustomCulture = "de-DE" and clicking SAVE-Button, the event PostBackCommand is not fired.

Last post 01-16-2006, 4:53 PM by joergbauer. 6 replies.
Sort Posts: Previous Next
  •  01-14-2006, 8:17 PM 14730

    When using programatically Editor.CustomCulture = "de-DE" and clicking SAVE-Button, the event PostBackCommand is not fired.

    Hello,

    when setting the language programatically (.NET 2.0) like this for example:

    Page_Load
      Editor1.CustomCulture = "de-DE"
    ...

    and then clicking the SAVE Button, the event for PostBackCommand is not fired.

    Regards
    J.Bauer

  •  01-16-2006, 1:52 AM 14747 in reply to 14730

    Re: When using programatically Editor.CustomCulture = "de-DE" and clicking SAVE-Button, the event PostBackCommand is not fired.

    J.Bauer,
     
    Which version of CuteEditor are you using?
     
    The CustomCulture property should not have any impact to the PostBackCommand event.

    Please test the following example:
     
     
     

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  01-16-2006, 6:48 AM 14757 in reply to 14747

    Re: When using programatically Editor.CustomCulture = "de-DE" and clicking SAVE-Button, the event PostBackCommand is not fired.

    Hello,
     
    I downloaded the trial version last Week. I guess it is Version 5.0.

    Can you solve this problem?

    Regards,

    J. Bauer
  •  01-16-2006, 1:33 PM 14773 in reply to 14757

    Re: When using programatically Editor.CustomCulture = "de-DE" and clicking SAVE-Button, the event PostBackCommand is not fired.

    J.bauer,
     
    I have no problem with ASP.NET 2.0 using the following code: If you still have problems, can you post your code?
     
    <%@ Page Language="C#"%>
    <%@ Register TagPrefix="CE" Namespace="CuteEditor" Assembly="CuteEditor" %>
    <html>
     <body>
            <form runat="server" defaultfocus="txtOtherTextBox">
       <CE:Editor id="Editor1" CustomCulture = "de-DE" runat="server"></CE:Editor><br />
       <asp:Button id="btnUpdate" onclick="Submit" Runat="server" Text="Show HTML"></asp:Button>
       <asp:Literal ID="Literal1" Runat="server" />
      </form>
     </body>
    </html>
    <script runat="server">
     void Page_Load(object sender, System.EventArgs e)
      {
         if (IsPostBack)
      {
       Literal1.Text = "<h2>The HTML you typed is...</h2><br>";
       Literal1.Text += Server.HtmlEncode(Editor1.Text);
         }
      else
      {
       Editor1.Text = "Type Here";
            } 
     }
     public void Submit(object sender, System.EventArgs e)
     {
      Literal1.Text = "<h2>The HTML you typed is...</h2><br>";
      Literal1.Text += Server.HtmlEncode(Editor1.Text);
     }
    </script>

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  01-16-2006, 3:21 PM 14777 in reply to 14773

    Re: When using programatically Editor.CustomCulture = "de-DE" and clicking SAVE-Button, the event PostBackCommand is not fired.

    Hello,
     
    here is the code. When I hit the SAVE-Button the event Editor1_PostBackCommand is not fired.

    default3.aspx
    <%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default3.aspx.vb" Inherits="Default3" %>
    <%@ Register TagPrefix="CE" Namespace="CuteEditor" Assembly="CuteEditor" %>
    <head runat="server">
        <title>Untitled Page</title>
    </head>
    <body>
        <form id="form1" runat="server">
        <CE:Editor id="Editor1" runat="server" AutoConfigure="Full"></CE:Editor>
        </form>
    </body>
    </html>

    default3.aspx.vb
    Partial Class Default3
        Inherits System.Web.UI.Page

        Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
            Me.Editor1.CustomCulture = "de-DE"
        End Sub

        Protected Sub Editor1_PostBackCommand(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.CommandEventArgs) Handles Editor1.PostBackCommand
            Response.Write("Event fired!")
        End Sub

    End Class
  •  01-16-2006, 3:46 PM 14778 in reply to 14777

    Re: When using programatically Editor.CustomCulture = "de-DE" and clicking SAVE-Button, the event PostBackCommand is not fired.

    You forgot add the following code:

    AddHandler Editor1.PostBackCommand, AddressOf Editor1_PostBackCommand
     
    Please check the capture_save_button_click.aspx.vb file included in the download package.
     
     

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  01-16-2006, 4:53 PM 14779 in reply to 14778

    Re: When using programatically Editor.CustomCulture = "de-DE" and clicking SAVE-Button, the event PostBackCommand is not fired.

    Hello,
     
    when I insert the line in the Page_Load:

    AddHandler Editor1.PostBackCommand, AddressOf Editor1_PostBackCommand

    it still doesn't work! Editor1_PostBackCommand will not be fired.
    Can you please try my code?


    It only works when I delete in Page_Load
    Me.Editor1.CustomCulture = "de-DE"
    and add CustomCulture = "de-DE" in the default3.aspx file.
     
     
    Why doesn't it work when I set the CustomCultur dynamically?

    Regards,
    J. Bauer
View as RSS news feed in XML