jQWidgets Forums

Forum Replies Created

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts

  • Clarence
    Participant

    Thanks for the reply, Ivailo.

    The challenge is to fetch only Name2 and not Name1,Name3. Is this possible ?

    Something like Tag3>Tag4[ID=2]>Name which would fetch Name2 . Please let me know

    <Tag1>
    	<Tag2>
    		<Tag3>
    			<CustomerID> Customer 1 </Customer1>
    			<City> City 1 </City>
    			<Tag4 ID="1">
    				<Name>Name1</Name>
    				<Type>Type1</Type>
    			</Tag4>
    			<Tag4 ID="2">
    				<Name>Name2</Name>
    				<Type>Type2</Type>
    			</Tag4>
    			<Tag4 ID="3">
    				<Name>Name3</Name>
    				<Type>Type3</Type>
    			</Tag4>
    		</Tag3>
    	</Tag2>
    </Tag1>

    Clarence
    Participant

    Hi Ivailo,

    Thanks for the response.
    Curious to know if this can be handled without modifying the XML.
    Just to let you know, we are getting the XML from a different system which cannot be manipulated.

    Thanks.


    Clarence
    Participant

    Thanks Dimitar. Working as expected.

    Thanks a lot


    Clarence
    Participant

    Hi,

    In my above example, I need to disable column 6 (displayfield: ‘Region’) on basis of column 2 (datafield: ‘2’).

    i.e if Column 2 has value Test2, i need to disable the dropdown of column 6.

    Can you please share me the code for the above mentioned scenario.

    Thanks.


    Clarence
    Participant

    Below is the sample code which is not working

    if the value is Test1 then the column should be enabled else if Test2 then disabled

    var cellclass = function (row, columnfield, value) {

    if (value == “Test1”) {
    $(“#jqxgrid”).jqxGrid(‘endcelledit’, row, columnfield, true);
    }
    else if (value == “Test2”) {
    $(“#jqxgrid”).jqxGrid(‘endcelledit’, row, columnfield, false);
    }
    }

    $(“#jqxgrid”).jqxGrid(
    {
    width: 1100,
    source: dataAdapter,
    columnsresize: true,
    sortable: true,
    editable: true,
    pageable: true,
    autoheight: true,
    filterable: true,
    pagesize: 1000,
    enabletooltips: true,
    columns: [
    { text: ‘1’, datafield: ‘1’, width: 250, editable: false },
    { text: ‘2’, datafield: ‘2’, width: 100, cellclassname: cellclass, editable: false },
    { text: ‘3’, datafield: ‘3’, width: 100, editable: false },
    { text: ‘4’, datafield: ‘4’, width: 150 },
    { text: ‘5’, datafield: ‘5’, width: 200 },
    {
    text: ‘6’, datafield: ‘6’, width: 150, displayfield: ‘Region’, columntype: ‘dropdownlist’,
    createeditor: function (row, value, editor) {
    editor.jqxDropDownList({ source: regionssAdapter, displayMember: ‘REGION_NAME’, valueMember: ‘6’ });
    }
    },
    {
    text: ‘7’, datafield: ‘7’, width: 150, displayfield: ‘ECS_GROUP’, columntype: ‘dropdownlist’,
    createeditor: function (row, value, editor) {
    editor.jqxDropDownList({ source: ECSGroupAdapter, displayMember: ‘Text’, valueMember: ‘7’ });
    }
    }

    ]
    });


    Clarence
    Participant

    Hi,

    Even i have the same requirement to disable a cell in the Grid based on its value.

    $(“#jqxgrid”).bind(‘cellbeginedit’, function (event) {

    // Logic to disable column
    });

    The above cellbeginedit code gets executed only when there is any change in the row but my requirement is to disable/enable the cell when the whole data gets populated in the grid at the start.

    Is this possible ?

    in reply to: AutoGenerate Columns AutoGenerate Columns #55961

    Clarence
    Participant

    Any Ideas when will this be implemented in jqxGrid in future ?

    in reply to: Grid UpdateRow Trigger Grid UpdateRow Trigger #55937

    Clarence
    Participant

    Thanks for the solution. Problem resolved

Viewing 8 posts - 1 through 8 (of 8 total)