473,387 Members | 1,834 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

How to get data in dhtml grid by clicking the corresponding checkbox?

In java script i have 5 check box having 5 different name,which contain corresponding values...if i check one box i will get corresponding value in a grid below,,if check 2 box then two will come,,,like wise...


please help
Apr 8 '11 #1
3 2747
gits
5,390 Expert Mod 4TB
what do you have so far? please show some code to work with.

kind regards
Apr 9 '11 #2
Expand|Select|Wrap|Line Numbers
  1. var mygrid;
  2.     function doOnLoad() {
  3.  
  4.  
  5.          mygrid = new dhtmlXGridObject('mygrid_container');
  6.  
  7.          mygrid.setImagePath("Resources/javascript/dhtmlxGrid/codebase/imgs/");
  8.          mygrid.setSkin("dhx_skyblue");
  9.          mygrid.setHeader(",<%=defaultmonth1%>,#cspan,#cspan,#cspan,#cspan,<%=defaultmonth2%>,#cspan,#cspan,#cspan,#cspan");
  10.          mygrid.attachHeader("Asset, <%=tempNames.GetData_frm_Location(0,0)%>, <%=tempNames.GetData_frm_Location(1,0)%>, <%=tempNames.GetData_frm_Location(2,0)%>,<%=tempNames.GetData_frm_Location(3,0)%>,<%=tempNames.GetData_frm_Location(4,0)%>,<%=tempNames.GetData_frm_Location(0,0)%>,<%=tempNames.GetData_frm_Location(1,0)%>, <%=tempNames.GetData_frm_Location(2,0)%>,<%=tempNames.GetData_frm_Location(3,0)%>,<%=tempNames.GetData_frm_Location(4,0)%>");
  11.          //mygrid.setIconPath("Resources/javascript/dhtmlxGrid/codebase/imgs/icons_books/");
  12.          mygrid.setInitWidths("100,100,100,100,100,100,100,100,100,100,100");
  13.  
  14.  
  15.  
  16.             mygrid.setColAlign("left,left,left,left,left,left,left,left,left,left,left");
  17.  
  18.             mygrid.setColTypes("ro,ro,ro,ro,ro,ro,ro,ro,ro,ro,ro");
  19.  
  20.              mygrid.attachEvent("onRowDblClicked", function(rId,cInd){});  
  21.  
  22.             mygrid.init();
  23.             //this code enables paging and sets its skin;
  24.            mygrid.enablePaging(true, 100, 10, "pagingArea", true, "infoArea");
  25.           mygrid.setPagingSkin("bricks");
  26.                 mygrid.loadXML('<%=XMLPath%>');
  27.  
  28.            }
Apr 11 '11 #3
in the above code in grid all the temp names are coming on grid head....but i want which checkbox i'll click(those r presents in an another jsp)the corresponding tempname and is value(from database) will come on my grid according to date selected in the same previous jsp
Apr 11 '11 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: John Smith | last post by:
Hi, How can I tell on the double click event of the datagrid whether or not a row was double clicked or a column header was double clicked? My problem is I open a new form on the double click...
1
by: Anthony | last post by:
I am defining the datagridtable style for a grid .... Dim coursekeycol As New DataGridTextBoxColumn coursekeycol.MappingName = COURSEKEYCOLNAME coursekeycol.HeaderText = "" coursekeycol.Width...
0
by: cgsh | last post by:
I do have some problems working with GridView and ObjectDataSource. When clicking Edit / Delete bottoms i grid - no values from grid are passed to routines. Help ! Regards cgsh
2
by: ColliersWNC | last post by:
I know there is probably a simple solution to this, but I haven't figured it out yet or seen it else where. Imagine you had a simple web page that looked like the following: <html> <input...
1
by: fanoftvb | last post by:
Hi, is there a way to update the data in access by clicking on a button on the gridview. I have a columm named "state" in my database. How do i change the "statue" columm by just clicking on the...
3
by: makis | last post by:
hello, How can i send data from grid component to messagebox? which code or process we need?
0
blossam
by: blossam | last post by:
hi friends, i want to add data in grid at runtime means when i click enter or tab i want a new row in grid so i can add value in that i know how to do this in windows application but i want to...
5
by: sasimca007 | last post by:
Hi friends, I have a doubt about checkboxes, i.e if i am creating checkboxes with the same name, in a loop and i have another checkbox down to the above checkboxes, My problem is...
2
by: priyamv | last post by:
Hi all,(Its urgent) I have a asp:radiobutto and asp:checkbox in my page.. Once the checkbox is clicked the radiobutton should be disabled ..how can i do it with javascript or AJAX.. ...
3
by: lauranoel | last post by:
I have 3 button-images in one page, such that when you press 1, it should show the iFrame related to it, and hide the others. I just started learning about webdev, and I've browsed online, but i...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.