Forum


12:00

31/01/2013

Hi,
I'm reading from database about 10 rows, but JQGrid displays me only 7 (I have 1 page, and I have "View 1 - 7 of 7"). I can search by missing rows, or sorting but it always display 7 rows:( . In other place of site it is ok (it displays about 40 rows, which is properly)
Any suggestion?
BTW. Sorry 4 my english
22:20

Moderators
30/10/2007

Hello,
How do you read the database?
Do you use JSON or XML,
Do you have configured the readers correct.
No answer will be, if your description is not approved with a test case.
Regards
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
11:36

31/01/2013

Hi,
Thanks for replying.
Firstly I think I must say that I'm writing in asp.net.
I read DB directly from SQL (using SqlConnection). The same method in other part of my system works perfectly. Only in this part it shows only 7, not 10 (it read from DB 10 rows, which I'm sure because I debug my site). I can search by "hidden" rows, but always display 7.
BTW. Maximum row page is set to 25.
11:50

10/08/2009

Hi,
jqGrid is pure JavaScript solution. So what you can do is to use Fiddler, Firebug, Developer Tools of IE or Chrome or any other tool to catch the exact JSON response of the server. If you save the JSON response in the file with the name like "test.json" you can use url: "test.json" to reproduce the problem without you server environment. You should just provide the HTML page with the JavaScript code which you use. If you see that the problem is do on the server side then you need debug it yourself because it has no relation with jqGrid.
By the way Fiddler works as HTTP proxy. So using Fiddler one can catch any HTTP trafic in any environmat with any servers and then having the traces one can use Fiddler in autoresponse mode. So the fiddler will answer on the requests with the previously saved responses without having the server environment.
In the answer you can find and download an example of ASP.NET code which works with jqGrid without any problems.
Best regards
Oleg
11:59

31/01/2013

Thanks for reply,
Ok, my english is bad:)
I don't use json, I get rows by (C# code):
DataTable dt = module.Search(pageSize, startIndex, orderByColumn, searchExpression);
This function makes query string and return rows.
Like I said the same schema works in other part of site. I thought it could be by polish letters, but when I deleted them it doesn't improve.
12:09

10/08/2009

I am sure that your server returns either JSON or XML because it's only two formats which supports jqGrid. Which value has datatype parameter of jqGrid which you use? If you don't specify any datatype parameter then default value "xml" will be used. Do you tried to use any Tools to catch HTTP trafic like I described before? If you use Windows computer then you have Internet Explorer. If you press F12 in IE the Developer Tools will be started. You can choose "Network" tab and click "Start capturing" button. Developer Tools will catch all HTTP requests and responses and you can examine it.
12:28

31/01/2013

Ok, I see that I get 7 rows in response.
In JQGrid1_DataRequesting(object sender, Trirand.Web.UI.WebControls.JQGridDataRequestEventArgs e) function in debug mode I get 9 rows.
In this function I have:
JQGrid1.DataSource = dt;
JQGrid1.DataBind();
dt = DataTable with 9 rows
OK. I found my error. Function GetRowCount returns 7 not 9 🙂
Now it works:)
Thanks anyone:)
Most Users Ever Online: 715
Currently Online:
51 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
OlegK: 1255
markw65: 179
kobruleht: 144
phicarre: 132
YamilBracho: 124
Renso: 118
Member Stats:
Guest Posters: 447
Members: 11373
Moderators: 2
Admins: 1
Forum Stats:
Groups: 1
Forums: 8
Topics: 10592
Posts: 31289
Newest Members:
, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.comModerators: tony: 7721, Rumen[Trirand]: 81
Administrators: admin: 66