Click here to Skip to main content
15,565,146 members
Home / Discussions / C#
   

C#

 
AnswerRe: error ---Cannot find table 0. Pin
dan!sh 26-Jun-09 21:51
professional dan!sh 26-Jun-09 21:51 
GeneralRe: error ---Cannot find table 0. Pin
KIDYA26-Jun-09 22:07
KIDYA26-Jun-09 22:07 
AnswerRe: error ---Cannot find table 0. Pin
Christian Graus26-Jun-09 22:04
mveChristian Graus26-Jun-09 22:04 
GeneralRe: error ---Cannot find table 0. Pin
KIDYA26-Jun-09 22:11
KIDYA26-Jun-09 22:11 
GeneralRe: error ---Cannot find table 0. Pin
Christian Graus26-Jun-09 22:23
mveChristian Graus26-Jun-09 22:23 
AnswerRe: error ---Cannot find table 0. Pin
Rajesh Anuhya26-Jun-09 22:14
professionalRajesh Anuhya26-Jun-09 22:14 
GeneralRe: error ---Cannot find table 0. Pin
Christian Graus26-Jun-09 22:23
mveChristian Graus26-Jun-09 22:23 
AnswerRe: error ---Cannot find table 0. Pin
fly90426-Jun-09 22:55
fly90426-Jun-09 22:55 
Where do you add a DataTable to you DataSet? Nowhere; that's why you are getting a problem.

DataSet.Tables is a read-only property (as shown in the documentation[^]), so mysdset.Tables["tblImgData"].Rows[0]["Picture"] = GetImageData(s); would fail anyway.

I hope this clears things up a little:

//Create a new Table called tblImgData
DataTable dt = new DataTable("tblImgData");

//Adds a column called picture
dt.Columns.Add("Picture", typeof(Byte[]));

//Add a row to the table
dt.Rows.Add(GetImageData(s));

//Then add it to the DataSet
DataSet ds = new DataSet("NewDataSetName");
ds.Tables.Add(dt);
NOTE: I wrote this on the fly so it may not be syntactically correct.

If at first you don't succeed, you're not Chuck Norris.

GeneralRe: error ---Cannot find table 0. Pin
KIDYA27-Jun-09 2:29
KIDYA27-Jun-09 2:29 
Questionprint a webform (asp.net 2.0 with c#) Pin
Sudhirg kumar26-Jun-09 21:30
Sudhirg kumar26-Jun-09 21:30 
AnswerRe: print a webform (asp.net 2.0 with c#) [modified] Pin
dan!sh 26-Jun-09 21:57
professional dan!sh 26-Jun-09 21:57 
QuestionIE Toolbar not "selectable" Pin
Jerome Caldwell26-Jun-09 19:35
Jerome Caldwell26-Jun-09 19:35 
Questionsql c# connection for sign_in Pin
A_A26-Jun-09 19:18
A_A26-Jun-09 19:18 
AnswerRe: sql c# connection for sign_in Pin
Christian Graus26-Jun-09 19:26
mveChristian Graus26-Jun-09 19:26 
AnswerRe: sql c# connection for sign_in Pin
padmanabhan N26-Jun-09 19:55
padmanabhan N26-Jun-09 19:55 
GeneralRe: sql c# connection for sign_in Pin
Christian Graus26-Jun-09 21:21
mveChristian Graus26-Jun-09 21:21 
GeneralRe: sql c# connection for sign_in Pin
padmanabhan N26-Jun-09 21:41
padmanabhan N26-Jun-09 21:41 
GeneralRe: sql c# connection for sign_in Pin
A_A27-Jun-09 0:29
A_A27-Jun-09 0:29 
GeneralRe: sql c# connection for sign_in Pin
padmanabhan N27-Jun-09 0:40
padmanabhan N27-Jun-09 0:40 
GeneralRe: sql c# connection for sign_in Pin
A_A27-Jun-09 4:17
A_A27-Jun-09 4:17 
QuestionHow to get DiskDrive model if I know the Drive letter Pin
lexx_zone26-Jun-09 11:40
lexx_zone26-Jun-09 11:40 
AnswerRe: How to get DiskDrive model if I know the Drive letter Pin
I Believe In GOD26-Jun-09 14:44
I Believe In GOD26-Jun-09 14:44 
GeneralRe: How to get DiskDrive model if I know the Drive letter Pin
lexx_zone27-Jun-09 2:05
lexx_zone27-Jun-09 2:05 
GeneralRe: How to get DiskDrive model if I know the Drive letter Pin
padmanabhan N27-Jun-09 2:14
padmanabhan N27-Jun-09 2:14 
QuestionArbitrary length bitfields? Pin
Trollslayer26-Jun-09 11:32
mentorTrollslayer26-Jun-09 11:32 

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.