473,406 Members | 2,710 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,406 software developers and data experts.

Checking Data set wheather it contain data or not

Hi !

Iam using asp.net vs05 , After Filling the dataset by using some stored procedure ,I need to check the dataset ,wheather it has been fill with the desired data or not other wise is it empty or not, Kindly provide me with the solution code,
Thanks in advance !!!
Jul 17 '07 #1
2 1130
dip_developer
648 Expert 512MB
Hi !

Iam using asp.net vs05 , After Filling the dataset by using some stored procedure ,I need to check the dataset ,wheather it has been fill with the desired data or not other wise is it empty or not, Kindly provide me with the solution code,
Thanks in advance !!!
just check the number of records for empty dataset.....with...
ds.Tables[0].Rows.Count()

Expand|Select|Wrap|Line Numbers
  1.  Dim i As Integer 
  2. i=ds.Tables[0].Rows.Count()
  3. If i= 0 Then
  4. ' do something
  5. Else
  6. 'do something
  7. End If
  8.  
Jul 17 '07 #2
Plater
7,872 Expert 4TB
don't forget to do a
Expand|Select|Wrap|Line Numbers
  1. if (ds.Tables.Count>0)
  2. {
  3. }
  4.  
just check the number of records for empty dataset.....with...
ds.Tables[0].Rows.Count()

Expand|Select|Wrap|Line Numbers
  1.  Dim i As Integer 
  2. i=ds.Tables[0].Rows.Count()
  3. If i= 0 Then
  4. ' do something
  5. Else
  6. 'do something
  7. End If
  8.  
Jul 17 '07 #3

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

Similar topics

9
by: Ronald Fischer | last post by:
Assume the following JavaScript function: function bracketize(s) { return ''; } This function which doesn't assume anything about its argument except that it must be convertible to a string.
1
by: JS | last post by:
I have set up db2audit for checking on win2k v8 db, but when I extract the records from the log and load them into the checking table, I don't get the object name in objname colum. My understanding...
8
by: Brendan | last post by:
There must be an easy way to do this: For classes that contain very simple data tables, I like to do something like this: class Things(Object): def __init__(self, x, y, z): #assert that x,...
16
by: lawrence k | last post by:
I've made it habit to check all returns in my code, and usually, on most projects, I'll have an error function that reports error messages to some central location. I recently worked on a project...
1
by: ravipatil | last post by:
hi i am adding two numbers in C#.net & i want to check wheather first textbox is empty or not. if empty, then it must display "enter the first number" otherwise value is stored in first textbox1....
2
by: sunnysrivastava84 | last post by:
I am using VB6 and i want to check wheather a record is present or not in a table by clicking on the search button,Plz give me the query. the search code is. if tuno.Text = "" Then MsgBox...
2
by: mayaanant | last post by:
Pls Give me gudeline for making software which compare two thump impression How two thump compare wheather they are of same person or not
125
by: jacob navia | last post by:
We hear very often in this discussion group that bounds checking, or safety tests are too expensive to be used in C. Several researchers of UCSD have published an interesting paper about this...
7
by: CaptainnFungi | last post by:
Hi All, I am very new to C and have been working my way through a few C books with the aim of getting more knowledge in programming. However I have hit a wall and I am not sure how to get over it....
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: 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
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...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

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.