[CLOSED] Problem with gridpanel column resizing in firefox and chrome

Page 1 of 3 123 LastLast
  1. #1

    [CLOSED] Problem with gridpanel column resizing in firefox and chrome

    Gridpanel works fine on IE8, but on firefox, if i resize the columns only the column gets resized, the header stays with the same width. On chrome it's even worse, because all the columns always stays with the same size.

    Code:

    <ext:GridPanel Height="180px" ID="gvPropriedades" runat="server" StripeRows="true"
                                    TrackMouseOver="true" Title="Propriedades" AutoExpandColumn="cDescricaoPerfil"
                                    Border="false">
                                    <Store>
                                        <ext:Store ID="gvPropriedadesStore" runat="server">
                                            <Reader>
                                                <ext:JsonReader>
                                                    <Fields>
                                                        <ext:RecordField Name="Codigo" Type="String" />
                                                        <ext:RecordField Name="Titulo" Type="String" />
                                                    </Fields>
                                                </ext:JsonReader>
                                            </Reader>
                                        </ext:Store>
                                    </Store>
                                    <ColumnModel ID="ColumnModel2" runat="server">
                                        <Columns>
                                            <ext:CommandColumn Width="30">
                                                <Commands>
                                                    <ext:GridCommand Icon="Delete" CommandName="Remover">
                                                        <ToolTip Text="Remover..." />
                                                    </ext:GridCommand>
                                                </Commands>
                                            </ext:CommandColumn>
                                            <ext:Column ColumnID="cCodigoPerfil" Header="Código" Width="200px" DataIndex="Codigo">
                                            </ext:Column>
                                            <ext:Column ColumnID="cDescricaoPerfil" Header="Descrição" DataIndex="Titulo">
                                            </ext:Column>
                                        </Columns>
                                    </ColumnModel>
                                    <TopBar>
                                        <ext:Toolbar ID="Toolbar3" runat="server">
                                            <Items>
                                                <mxm:HelpField ID="tbAddPropriedade" runat="server" FieldLabel="Propriedade" LabelWidth="60">
                                                </mxm:HelpField>
                                                <ext:Button ID="btnAddPropriedade" runat="server" Icon="Add" ToolTip="Adicionar Perfil">
                                                    <Listeners>
                                                        <Click Handler="btnAddRowPropriedadeClick()" />
                                                    </Listeners>
                                                </ext:Button>
                                            </Items>
                                        </ext:Toolbar>
                                    </TopBar>
                                    <Listeners>
                                        <Command Handler="RemoveColumn(this, record, command);" />
                                    </Listeners>
                                </ext:GridPanel>
    Images:

    Firefox:

    Grid:
    Click image for larger version. 

Name:	grid.JPG 
Views:	165 
Size:	7.2 KB 
ID:	1516

    Grid after resizing:
    Click image for larger version. 

Name:	resizegrid.JPG 
Views:	169 
Size:	10.5 KB 
ID:	1517
    Last edited by Daniil; Aug 30, 2010 at 1:18 PM. Reason: Marked as [CLOSED]. No more information was provided.
  2. #2
    Hi,

    Are you sure that you use latest code from SVN? That problem was fixed already
  3. #3
    Vladsh, i tried to update to last SVN version and i started getting a lot of javascript errors in stuff that worked fine before... I was using version 1.0.0.1914. Now on every blur and button click i get javascript errors saying there in a ')' missing. I went back to the version i was using and everything went back to normal... Is there any other more stable version we can get to make he grid work fine or any workaround to the problem in this version?
  4. #4
    Hi,

    We don't have such errors. Can you provide test sample which demonstrates the problem with latest code?
  5. #5
    Hello!

    It's highly recommended to use the latest version.
    I would suggest you to update and try to localize the issue
    "javascript errors saying there in a ')' missing"
    Then please post the example here and we will help you to solve it.

    By the way I was unable to reproduce the issue using the code you provided. Perhaps the matter is in the rest part of code.

    NOTE: Marked as solved. No more information was provided.
    Last edited by Daniil; Aug 30, 2010 at 1:17 PM.
  6. #6
    Hello Vladsch and Daniil,

    Today i tried again to update my project to the new version (i was using 1.0.0.1914, in which everything worked perfectly, now i'm trying 1.0.3889.20885). Same error (javascript saying there is a ')' missing. The error occurs inside this eval(result.script);, in the following function, in ext.net source:

    function(o,result,response){eval(result.script);}).call(window,o,result,response);}
    In the version that works, "result.script" contains:
    HelpWindow.closable=false;
    HelpWindow.collapsible=false;
    HelpWindow.headerAsText=true;
    HelpWindow.setIconClass("icon-find");
    HelpWindow.maximizable=false;
    HelpWindow.minHeight="290px";
    HelpWindow.minimizable=false;
    HelpWindow.minWidth="430px";
    HelpWindow.resizable=false;
    tbAddPerfilhdnConfig.setValue("{\"HelpIndex\":0,\"HelpClass\":\"MXM.Seguranca.Help.WHPerfilAcesso, MXM.Seguranca, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null\",\"EnvIndex\":0}");
    tbCodigohdnConfig.setValue("{\"HelpIndex\":0,\"HelpClass\":\"MXM.Seguranca.Help.WHUsuario, MXM.Seguranca, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null\",\"EnvIndex\":0}");
    cbTipo.selectByIndex(0);tbCriadoEm.setValue(null);
    tbAlteradoEm.setValue(null);
    tbHomologadoPor.setValue(null);
    tbHomologadoEm.setValue(null);
    tbAddPerfil.setValue(null);
    cbUsuarioAD.setValue(false);
    tbConfirmeSenha.setValue(null);
    tbAlteradoPor.setValue(null);
    tbNome.setValue(null);
    tbEmail.setValue(null);
    cbIdioma.selectByIndex(0);
    tbSenha.setValue(null);
    tbCriadoPor.setValue(null);
    btExcluir.setDisabled(true);
    gvPerfisStore.removeAll();
    tbCriadoEm.setValue("6/9/2010");
    tbAlteradoEm.setValue("6/9/2010");
    tbHomologadoEm.setValue("6/9/2010");
    tbCriadoPor.setValue("GERAL");
    tbAlteradoPor.setValue("GERAL");
    tbHomologadoPor.setValue("GERAL");
    cbUsuarioAD.setValue(false);cbTipo.setValue("0");
    tbCriadoEm.setValue("2/5/1900 00:00:00");
    tbAlteradoEm.setValue("26/8/2010 00:00:00");
    tbHomologadoPor.setValue("MXM");
    tbHomologadoEm.setValue("1/2/1900 00:00:00");
    tbAlteradoPor.setValue("GERAL");
    tbCodigo.setValue("GERAL");
    tbNome.setValue("Usuario Geral Master");
    tbEmail.setValue("geral@mxm.com.br");
    cbIdioma.setValue("PTB");
    tbSenha.setValue("mxm");
    tbCriadoPor.setValue("MXM");
    cbUsuarioAD.setValue(false);
    tbConfirmeSenha.setValue("mxm");
    gvPerfisStore.callbackRefreshHandler(response, {serviceResponse: {success:true,data:{data:[{"Codigo":"ADMIN","Descricao":"Administrador do portal"},{"Codigo":"GERAL","Descricao":"Geral"}], total: 0}}}, gvPerfisStore, o.eventType, o.action, o.extraParams);btExcluir.setDisabled(false);
    In the one with the error, the same "result.script" contains:
    HelpWindow.closable=false;
    HelpWindow.collapsible=false;
    HelpWindow.headerAsText=true;
    HelpWindow.setIconClass("icon-find");
    HelpWindow.maximizable=false;
    HelpWindow.minHeight="290px";
    HelpWindow.minimizable=false;
    HelpWindow.minWidth="430px";
    HelpWindow.resizable=false;
    tbCodigohdnConfig.setValue("{"HelpIndex":0,"HelpClass":"MXM.Seguranca.Help.WHUsuario, MXM.Seguranca, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null","EnvIndex":0}");
    tbAddPerfilhdnConfig.setValue("{"HelpIndex":0,"HelpClass":"MXM.Seguranca.Help.WHPerfilAcesso, MXM.Seguranca, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null","EnvIndex":0}");
    tbEmail.setValue(null);
    tbAlteradoPor.setValue(null);
    tbConfirmeSenha.setValue(null);
    tbNome.setValue(null);
    cbIdioma.selectByIndex(0);
    cbTipo.selectByIndex(0);
    tbSenha.setValue(null);
    tbCriadoPor.setValue(null);
    tbCriadoEm.setValue(null);
    tbAlteradoEm.setValue(null);
    tbHomologadoPor.setValue(null);
    tbHomologadoEm.setValue(null);
    tbAddPerfil.setValue(null);
    cbUsuarioAD.setValue(false);
    btExcluir.setDisabled(true);
    gvPerfisStore.removeAll();
    tbCriadoEm.setValue("6/9/2010");
    tbAlteradoEm.setValue("6/9/2010");
    tbHomologadoEm.setValue("6/9/2010");
    tbCriadoPor.setValue("GERAL");
    tbAlteradoPor.setValue("GERAL");
    tbHomologadoPor.setValue("GERAL");
    cbUsuarioAD.setValue(false);
    tbEmail.setValue("geral@mxm.com.br");
    tbAlteradoPor.setValue("GERAL");
    tbCodigo.setValue("GERAL");
    tbNome.setValue("Usuario Geral Master");
    cbIdioma.setValue("PTB");
    cbTipo.setValue("0");
    tbSenha.setValue("mxm");
    tbCriadoPor.setValue("MXM");
    tbCriadoEm.setValue("2/5/1900 00:00:00");
    tbAlteradoEm.setValue("26/8/2010 00:00:00");
    tbHomologadoPor.setValue("MXM");
    tbHomologadoEm.setValue("1/2/1900 00:00:00");
    cbUsuarioAD.setValue(false);tbConfirmeSenha.setValue("mxm");
    gvPerfisStore.callbackRefreshHandler(response, {serviceResponse: {success:true,data:{data:[{"Codigo":"ADMIN","Descricao":"Administrador do portal"},{"Codigo":"GERAL","Descricao":"Geral"}], total: 0}}}, gvPerfisStore, o.eventType, o.action, o.extraParams);btExcluir.setDisabled(false);
    I guess the problem is with lines 10 and 11: in both values are being set that i obtain using JSON.Serialize. For some reason in the new version the quotes are not being escaped with bars.
  7. #7
    Hi,

    I think the problem in the following lines because slashes for double quotes are missed
    tbCodigohdnConfig.setValue("{"HelpIndex":0,"HelpClass":"MXM.Seguranca.Help.WHUsuario, MXM.Seguranca, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null","EnvIndex":0}");
    tbAddPerfilhdnConfig.setValue("{"HelpIndex":0,"HelpClass":"MXM.Seguranca.Help.WHPerfilAcesso, MXM.Seguranca, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null","EnvIndex":0}");
    Can you provide more details? What is tbCodigohdnConfig and tbAddPerfilhdnConfig? Can you create a test sample which reproduces the problem? I think need to use those two fields in the test sample and set those values during direct event
  8. #8
    Here goes a (very) simplified test sample. The real stuff occurs inside a custom control that would be too complex to provide you a sample, but you can see the same error with this, just run the example, enter and leave the textfield:


    aspx:
    <%@ Page Language="C#" AutoEventWireup="true"  CodeFile="Default.aspx.cs" Inherits="_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">
        <div>
        <ext:ResourceManager runat="server"></ext:ResourceManager>
            <ext:Hidden runat="server" ID="hdnConfig"></ext:Hidden>
            <ext:TextField runat="server" ID="tfTeste">
            
            </ext:TextField>
        </div>
        </form>
    </body>
    </html>

    cs:
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Web;
    using System.Web.UI;
    using System.Web.UI.WebControls;
    using Ext.Net;
    
    public partial class _Default : System.Web.UI.Page 
    {
        private class FieldConfig
        {
            public int HelpIndex { get; set; }
            public string HelpClass { get; set; }
            public int EnvIndex { get; set; }
        }
        protected void Page_Load(object sender, EventArgs e)
        {
            hdnConfig.SetValue(JSON.Serialize(new FieldConfig { EnvIndex = 0, 
                                                                HelpClass = "MXM.Seguranca.Help.WHPerfilAcesso, MXM.Seguranca, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null", 
                                                                HelpIndex = 0 }));
            tfTeste.DirectEvents.Blur.Event += new ComponentDirectEvent.DirectEventHandler(Blur_Event);
        }
    
        void Blur_Event(object sender, DirectEventArgs e)
        {
            
        }
    }
  9. #9
    Hi,

    I tested your sample but unfortunately it doesn't reproduce the problem for me, FieldConfig is serialized correctly and no js errors.
    Can you create test project, ensure that test sample reproduces the problem, include all required assemblies (Ext.Net also) and send it the support email?
  10. #10
    Just sent the full project to the support mail. I've ensured that it reproduces the error. How will we keep contact about this, through this thread or through the support e-mail?
Page 1 of 3 123 LastLast

Similar Threads

  1. [CLOSED] Problem with Firefox and Chrome
    By Stefanaccio in forum 1.x Legacy Premium Help
    Replies: 6
    Last Post: Dec 07, 2011, 12:43 PM
  2. Problem with a example in Chrome and Firefox...
    By Tanielian in forum 1.x Help
    Replies: 2
    Last Post: Apr 07, 2011, 6:14 PM
  3. Replies: 4
    Last Post: Nov 22, 2010, 10:25 AM
  4. Replies: 3
    Last Post: Jul 15, 2010, 2:15 PM
  5. Replies: 2
    Last Post: Feb 05, 2010, 5:20 PM

Posting Permissions