Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7579791
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T17:45:31+00:00 2026-05-30T17:45:31+00:00

I’m using a jqGrid. For add popup for combobox i’m using default data from

  • 0

I’m using a jqGrid. For add popup for combobox i’m using default data from the database which works fine.
But when edit popup is displayed its not showing the selected value in combobox instead showing 1st value in the list specified.

The following is my code:

$("#list").jqGrid({
    url:'<%=request.getContextPath()%>/getDetail.jsp',
    datatype: 'xml',
    mtype: 'GET',
    colNames:['DataChannel ID','Description','Date Creation(MM/dd/yyyy)','Date Closure(MM/dd/yyyy)','Frequency','Source Type','Source Data Type','Primary Data Source','Secondary Data Source','Data Available From(MM/dd/yyyy)','Lag','Advance Alert','Confidentiality Type','Data Flow Type','PSM Name','Comment','Data Available Upto(MM/dd/yyyy)'],
    colModel :[ 
      {name:'DESCRIPTION', index:'DESCRIPTION',editable:true,editrules:{required:true}, width:120}, 
      {name:'DATE_CREATION', index:'DATE_CREATION', editable:true,editrules:{required:true}, width:80}, 
      {name:'DATE_CLOSURE', index:'DATE_CLOSURE', editable:true,width:80}, 
      {name:'PRIMARY_SOURCE_ID', index:'PRIMARY_SOURCE_ID',editable:true,edittype:"select",     
          edittype:"select",editoptions:   
      {dataInit:function(elem){alert(elem);},value:"<%ctr=0;count=sourceList.size();for (itr=sourceList.iterator(); itr.hasNext(); ) {ctr++;sourceMap=(HashMap)itr.next();it = sourceMap.entrySet().iterator();while (it.hasNext()) {pairs = (Map.Entry)it.next();%><%=pairs.getKey()%>:<%=pairs.getValue()%><% if(ctr < count){%>;<%}}}%>"}, width:120},
      {name:'DATA_AVAILABLE_UPTO', index:'DATA_AVAILABLE_UPTO',editable:false,width:100}],
    pager: $('#pager'),
    rowNum:10,
    rowList:[10,20,30],
    sortname: 'user',
    sortorder: "desc",
    viewrecords: true,
    multiselect:false,
    imgpath: '<%=request.getContextPath()%>/themes/steel/images',
    caption: 'Data Channel Master Data',
    editurl: '<%=request.getContextPath()%>/ChannelUpdate.jsp',
    width:1700
}).navGrid('#pager',{add:true,addtext:'Add',edit:true,edittext:'Edit',del:true,deltext:'Del', search:true,searchtext:'Find',refresh:true}, //options
                    {height:300,width:500,reloadAfterSubmit:true}, // edit options
                    {height:300,width:500,reloadAfterSubmit:true}, // add options
                    {reloadAfterSubmit:true}, // del options
                    {} // search options
);
});

If i use dataUrl istead of value in editoptions of column ‘PRIMARY_SOURCE_ID’ then firebug is throughing an error

options.value is undefined
[Break On This Error] var so = options.value.split(";"),sv, ov;

Please help… How to get selected value in combobox for edit window.

Thanks in advance,
Sandeep Vemula

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T17:45:32+00:00Added an answer on May 30, 2026 at 5:45 pm

    Just needed to add formatter:"select" option to the column in which i want to display combobox with selected value in edit form.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a text area in my form which accepts all possible characters from
I want to construct a data frame in an Rcpp function, but when I
I'm new to using the Perl treebuilder module for HTML parsing and can't figure
That's pretty much it. I'm using Nokogiri to scrape a web page what has
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I want to count how many characters a certain string has in PHP, but
For some reason, after submitting a string like this Jack’s Spindle from a text
I am trying to understand how to use SyndicationItem to display feed which is
I used javascript for loading a picture on my website depending on which small
I am reading a book about Javascript and jQuery and using one of the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.