Click here to Skip to main content
16,007,443 members
Home / Discussions / C#
   

C#

 
GeneralRe: Typed DataSets and casing problems Pin
jparsons22-Jul-02 5:30
jparsons22-Jul-02 5:30 
GeneralRe: Typed DataSets and casing problems Pin
Andrew Connell22-Jul-02 6:55
Andrew Connell22-Jul-02 6:55 
GeneralScrolling in a RichTexBox Pin
jpeg22-Jul-02 3:51
jpeg22-Jul-02 3:51 
GeneralRe: Scrolling in a RichTexBox Pin
Steven Behnke22-Jul-02 7:30
Steven Behnke22-Jul-02 7:30 
GeneralRe: Scrolling in a RichTexBox Pin
jpeg22-Jul-02 21:37
jpeg22-Jul-02 21:37 
GeneralRe: Scrolling in a RichTexBox Pin
Steven Behnke23-Jul-02 4:09
Steven Behnke23-Jul-02 4:09 
GeneralHelp With DataSets Pin
Li Mu Bai22-Jul-02 3:14
Li Mu Bai22-Jul-02 3:14 
GeneralRe: Help With DataSets Pin
Roger Stewart23-Jul-02 6:12
professionalRoger Stewart23-Jul-02 6:12 
Li Mu Bai wrote:
How do I now get at the data in the DataSet myData ive just created?????

Have you tried to access the data like so:
myData.Tables["UserID"]

So your code could possibly look something like:
[WebMethod Description="Returns true if User ID in Database")]
public bool isUserIdValid( int nUserID )
{
   DataSet myData = new DataSet();

   sqlDataAdapter1.SelectCommand.Parameters["@userID"].Value = nUserID;

   // Check to make sure the stored proc returned rows,
   // otherwise accessing the ds could throw an exception.
   //
   if ( sqlDataAdapter1.Fill( myData, "UserID") > 0 )
   {
      // Validate the returned ID. If the value is not 0
      // then the user is valid.
      //
      if ( myData.Tables["UserID"] != 0 )
      {
         return true;
      }
   }
<br><br>
   return false;
}



Roger Stewart
"I Owe, I Owe, it's off to work I go..."

GeneralDataSet Pin
Li Mu Bai22-Jul-02 1:38
Li Mu Bai22-Jul-02 1:38 
GeneralRe: DataSet Pin
James T. Johnson22-Jul-02 1:55
James T. Johnson22-Jul-02 1:55 
GeneralInstalling CollectionGen - How I did it Pin
James T. Johnson22-Jul-02 0:44
James T. Johnson22-Jul-02 0:44 
GeneralRe: Installing CollectionGen - How I did it Pin
Nish Nishant22-Jul-02 3:46
sitebuilderNish Nishant22-Jul-02 3:46 
GeneralRe: Installing CollectionGen - How I did it Pin
James T. Johnson22-Jul-02 6:44
James T. Johnson22-Jul-02 6:44 
QuestionVideo Capture Hardware? Pin
Steven Behnke21-Jul-02 21:08
Steven Behnke21-Jul-02 21:08 
QuestionStatusbar with 3 sliders??? Pin
Daniel Strigl21-Jul-02 21:07
Daniel Strigl21-Jul-02 21:07 
AnswerRe: Statusbar with 3 sliders??? Pin
SHaroz22-Jul-02 5:49
SHaroz22-Jul-02 5:49 
QuestionC# - language design by committee ??? Pin
Christian Graus21-Jul-02 12:55
protectorChristian Graus21-Jul-02 12:55 
AnswerRe: C# - language design by committee ??? Pin
Rama Krishna Vavilala21-Jul-02 15:16
Rama Krishna Vavilala21-Jul-02 15:16 
GeneralRe: C# - language design by committee ??? Pin
Christian Graus21-Jul-02 15:28
protectorChristian Graus21-Jul-02 15:28 
GeneralRe: C# - language design by committee ??? Pin
Rama Krishna Vavilala21-Jul-02 15:38
Rama Krishna Vavilala21-Jul-02 15:38 
GeneralRe: C# - language design by committee ??? Pin
Christian Graus21-Jul-02 15:40
protectorChristian Graus21-Jul-02 15:40 
GeneralRe: C# - language design by committee ??? Pin
jparsons22-Jul-02 5:25
jparsons22-Jul-02 5:25 
GeneralRe: C# - language design by committee ??? Pin
Christian Graus22-Jul-02 12:17
protectorChristian Graus22-Jul-02 12:17 
GeneralRe: C# - language design by committee ??? Pin
Rama Krishna Vavilala22-Jul-02 5:37
Rama Krishna Vavilala22-Jul-02 5:37 
GeneralRe: C# - language design by committee ??? Pin
Christian Graus22-Jul-02 12:18
protectorChristian Graus22-Jul-02 12:18 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.