<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
	<title>jQuery Grid Plugin - jqGrid - Topic: Column Width: stopped working after jqgrid upgrade</title>
	<link>http://www.trirand.com/blog/?page_id=393/discussion/column-width-stopped-working-after-jqgrid-upgrade</link>
	<description><![CDATA[Grid plugin]]></description>
	<generator>Simple:Press Version 5.7.5.3</generator>
	<atom:link href="http://www.trirand.com/blog/?page_id=393/discussion/column-width-stopped-working-after-jqgrid-upgrade/rss" rel="self" type="application/rss+xml" />
        <item>
        	<title>josecoronel on Column Width: stopped working after jqgrid upgrade</title>
        	<link>http://www.trirand.com/blog/?page_id=393/discussion/column-width-stopped-working-after-jqgrid-upgrade#p25994</link>
        	<category>Discussion</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/discussion/column-width-stopped-working-after-jqgrid-upgrade#p25994</guid>
        	        	<description><![CDATA[<p>Hello,</p>
<p>Recently I upgrade to jGrid 4.3.1. After that, the setColProp with option WIDTH stopped workingand the columns do not change their size.</p>
<p>Here is my code:</p>
<div id="sfcode4561" class="sfcode">
<p>&#8230;</p>
<p>var columnNameWidth = getGridCookie(name+"colwidth").split("-");&#160;</p>
<p>// columnNameWidth =&#160;["rn.25", "veh_id.452", "veh_nombre.110", 18 m&#225;s...]</p>
<p>for( k = 0; k &#60; columnNameWidth.length; k++ ) {</p>
<p>var columnNW = columnNameWidth[k].split(".");</p>
<p>&#160;// columnNW = ["veh_id", "452"]</p>
<p>tableDivObject.jqGrid(&#39;setColProp&#39;, columnNW[0], {width:columnNW[1]});</p>
<p>// &#160;	 &#160;tableDivObject.setColProp(columnNW[0], {width:columnNW[1]});&#160;</p>
<p>}</p>
<p>var totalwidth = tableDivObject.jqGrid(&#39;getGridParam&#39;,&#39;width&#39;);</p>
<p>tableDivObject.jqGrid(&#39;setGridWidth&#39;, totalwidth);&#160;</p>
<p>var grid_param &#160;= tableDivObject.jqGrid(&#39;getGridParam&#39;);</p>
<p>&#8230;</p>
</div>
<p>The grid_param shows the width correctly but the changes aren&#39;t reflected in the grid.</p>
<p>I found this comment in the jqgrid source of setColProp. This is real ? the width property didn&#39;t work ?</p>
<div id="sb25-L3466" class="sourceRow ">
<div id="&#34;&#34;sb25-L3466&#34;&#34;" class="&#34;&#34;sourceRow&#34;">
<p><input type='button' class='sfcodeselect' name='sfselectit193' value='Select Code' data-codeid='sfcode193' /></p>
<div class='sfcode' id='sfcode193'>
<div id=&#34;&#34;&#34;sb25-L3466&#34;&#34;&#34; class=&#34;&#34;&#34;sourceRow&#34;&#34;>setColProp : function(colname, obj){</div>
<div id="sb25-L3467" class="sourceRow ">//do not set width will not work</div>
<div id="sb25-L3468" class="sourceRow">return this.each(function(){</div>
<div id="sb25-L3469" class="sourceRow">if ( this.grid ) {</div>
<div id="sb25-L3470" class="sourceRow">if ( obj ) {</div>
<div id="sb25-L3471" class="sourceRow">var cM = this.p.colModel;</div>
<div id="sb25-L3472" class="sourceRow">for ( var i =0;i&#60;cM.length;i++ ) {</div>
<div id="sb25-L3473" class="sourceRow">if ( cM[i].name == colname ) {</div>
<div id="sb25-L3474" class="sourceRow">$.extend(this.p.colModel[i],obj);</div>
<div id="sb25-L3475" class="sourceRow">break;</div>
<div id="sb25-L3476" class="sourceRow">}</div>
<div id="sb25-L3477" class="sourceRow">}</div>
<div id="sb25-L3478" class="sourceRow">}</div>
<div id="sb25-L3479" class="sourceRow">}</div>
<div id="sb25-L3480" class="sourceRow">});</div>
<div id="sb25-L3481" class="sourceRow">},&#160;</div>
</div>
</div>
</div>
<p>Looking forward for your reply !</p>
<p>Thanks Jose</p>
]]></description>
        	        	<pubDate>Wed, 22 Feb 2012 18:04:44 +0200</pubDate>
        </item>
</channel>
</rss>