473,387 Members | 1,757 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 display Records in grid

hi,

i want to display records in datagrid.

strtestids() is a string array. it contains some testids.

based on these ids i've to fill the datagrid.

i wrote code like this

Dim db As New NESDK.DatabaseGrid
Dim i As Integer

For i = 0 To strTestIds.Length - 1

If db.Run("select Testname,TestId,NoOfQues,TotalTime from

TestInfo where testid='" & strTestIds(i) & "'") Then
grdTests.DataSource = db.Result
grdTests.DataBind()
End If
Next
here in grid am getting only the last record. i.e if my string array

contains 2 records in grid am getting last record instead of 2 records.

can any one tell me how to do this one. why am getting last record only?

Thanx in advance
Yoshitha
Nov 19 '05 #1
2 1463
This was answered in microsoft.public.dotnet.framework.aspnet.webcontro ls .

"yoshitha" wrote:
hi,

i want to display records in datagrid.

strtestids() is a string array. it contains some testids.

based on these ids i've to fill the datagrid.

i wrote code like this

Dim db As New NESDK.DatabaseGrid
Dim i As Integer

For i = 0 To strTestIds.Length - 1

If db.Run("select Testname,TestId,NoOfQues,TotalTime from

TestInfo where testid='" & strTestIds(i) & "'") Then
grdTests.DataSource = db.Result
grdTests.DataBind()
End If
Next
here in grid am getting only the last record. i.e if my string array

contains 2 records in grid am getting last record instead of 2 records.

can any one tell me how to do this one. why am getting last record only?

Thanx in advance
Yoshitha

Nov 19 '05 #2
This was answered in microsoft.public.dotnet.framework.aspnet.webcontro ls .

"yoshitha" wrote:
hi,

i want to display records in datagrid.

strtestids() is a string array. it contains some testids.

based on these ids i've to fill the datagrid.

i wrote code like this

Dim db As New NESDK.DatabaseGrid
Dim i As Integer

For i = 0 To strTestIds.Length - 1

If db.Run("select Testname,TestId,NoOfQues,TotalTime from

TestInfo where testid='" & strTestIds(i) & "'") Then
grdTests.DataSource = db.Result
grdTests.DataBind()
End If
Next
here in grid am getting only the last record. i.e if my string array

contains 2 records in grid am getting last record instead of 2 records.

can any one tell me how to do this one. why am getting last record only?

Thanx in advance
Yoshitha

Nov 19 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: William Gill | last post by:
I need to display a couple of labels and a checkbox from each entry in my database. Simple enough, but there are several hundred records, and I only want to display 5 or 10 at a time. Can this be...
1
by: Avi | last post by:
Hi Experts, I would like to display the latest 500 events from a table which contains over a million records. The speed of insertion is about 25 a second. How can I display it and refresh the...
1
by: Nikhil Patel | last post by:
Hi all, I am developing an ASP.Net applicatin that displays data from Sql Server table in a grid. I would like to let the application administrator to pick which columns he want to display in the...
3
by: Jimmy | last post by:
Hi I want to display an empty datagrid if my datasource has zero results. How to do this? thanks J.
1
by: John Phelan-Cummings | last post by:
When I add the name of a new individual in a, bound form, it will not display that person’s name in a label control of a second unbound form. I have a scheduling program that I am working on. ...
3
by: Augustin Prasanna | last post by:
I need to display some 200 records (dynamic) on the screen.. I need to display records from 2 tables (one to many relationship) output would look like Customer Id Name Phone NO 1 abc ...
1
by: Ky_fanatic | last post by:
I am working on an application which returns data from multiple databases. The user enters a pallet ticket and it goes out to the multiple db's and returns data which meets the criteria. My...
1
by: hussainiyad | last post by:
Hi all, Can anyone tell me how to get a record for particular user or Number In my sql i,v Pinvoice table following fields InvNo int 1001 ItemNo 001
2
by: kurtzky | last post by:
i created a form that should function as follows: i will enter a number in a textbox..then it should query from the database all the records which has that number..these records will have a...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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: 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: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

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.