Click here to Skip to main content
15,899,026 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: ERROR [42000] [Microsoft][ODBC driver for Oracle][Oracle]ORA-00936: missing expression Pin
idsanjeevjha27-Jun-08 20:04
idsanjeevjha27-Jun-08 20:04 
GeneralRe: ERROR [42000] [Microsoft][ODBC driver for Oracle][Oracle]ORA-00936: missing expression Pin
Christian Graus27-Jun-08 20:05
protectorChristian Graus27-Jun-08 20:05 
GeneralRe: ERROR PART Pin
idsanjeevjha30-Jun-08 22:45
idsanjeevjha30-Jun-08 22:45 
GeneralRe: ERROR PART Pin
idsanjeevjha1-Jul-08 1:09
idsanjeevjha1-Jul-08 1:09 
QuestionHow can i give connection from vb.class to default.aspx Pin
chittu2327-Jun-08 15:01
chittu2327-Jun-08 15:01 
AnswerRe: How can i give connection from vb.class to default.aspx Pin
N a v a n e e t h27-Jun-08 20:48
N a v a n e e t h27-Jun-08 20:48 
QuestionWebControls.Menu Problem Pin
dptalt27-Jun-08 8:04
dptalt27-Jun-08 8:04 
QuestionSimple Question---bt nt able to solve Pin
paresh_sarjani27-Jun-08 7:10
paresh_sarjani27-Jun-08 7:10 
here is my code

i m trying to insert all the selected files in database having two tables

in First table (Details) columns are ID,Name and Path no


and in second table (Path ) columns are ID

i hav inserted Dataset (Dataset1 ) which is having both tables

btt sumhoww records couldnt be inserted



private void button1_Click(object sender, EventArgs e)
{
openFileDialog1.Filter = "Image (*.BMP;)|*.BMP|" + "All files (*.*)|*.*";
openFileDialog1.Multiselect = true;
openFileDialog1.Title = "Select BMP Image Files";
openFileDialog1.ShowDialog();
// string flnm = openFileDialog1.FileName;
flnms = openFileDialog1.FileNames;

int file_number = flnms.Length;
int pathno = 0;

DataSet1 dataset1 = new DataSet1();
DataSet1TableAdapters.DetailsTableAdapter detailsTableAdapter = new DataSet1TableAdapters.DetailsTableAdapter();
DataSet1TableAdapters.PathTableAdapter pathTableAdapter = new DataSet1TableAdapters.PathTableAdapter();
// int row_max = dataset1.Tables["bmpFront"].Rows.Count;
//int row_max = 188;
detailsTableAdapter.Connection = new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=\"I:\\Picture to DB\\Picture to DB\\All Files.mdb\"");
detailsTableAdapter.Connection.Open();
pathTableAdapter.Connection = new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=\"I:\\Picture to DB\\Picture to DB\\All Files.mdb\"");
pathTableAdapter.Connection.Open();
pathTableAdapter.Fill(dataset1.Path);
detailsTableAdapter.Fill(dataset1.Details);
int row_max_path = dataset1.Path.Rows.Count;
int row_max_details = dataset1.Details.Rows.Count;

for(int i=0;i<file_number;i++)>
{



string str;
str = flnms[i].ToString();
string[] str1 = str.Split('\\');
string name = str1[str1.Length - 1];

string path = getpath(str1) ;



// DataSet1 dataset1 = new DataSet1();


if (i == 0)
{
pathno = 999;
for (int j = 0; j < dataset1.Tables["Path"].Rows.Count; j++)
{
string str_compare = getpath((dataset1.Path[j][1].ToString()).Split('\\'));

if (str_compare == path)
{
pathno = int.Parse(dataset1.Path[j]["Path Id"].ToString());

}
else
{
continue;
}


}
}
if(pathno == 999)
{
pathTableAdapter.InsertQuery(row_max_path+1, path);
pathno = dataset1.Path.Rows.Count;
}

detailsTableAdapter.InsertQuery(row_max_details+1, name, pathno.ToString());
row_max_path++;
row_max_details++;
}
pathTableAdapter.Connection.Close();
detailsTableAdapter.Connection.Close();
AnswerRe: Simple Question---bt nt able to solve Pin
Parwej Ahamad27-Jun-08 7:13
professionalParwej Ahamad27-Jun-08 7:13 
GeneralRe: Simple Question---bt nt able to solve Pin
paresh_sarjani27-Jun-08 7:34
paresh_sarjani27-Jun-08 7:34 
GeneralRe: Simple Question---bt nt able to solve Pin
Colin Angus Mackay27-Jun-08 10:18
Colin Angus Mackay27-Jun-08 10:18 
QuestionHow to send an email ? Pin
tina->newcoder27-Jun-08 6:58
tina->newcoder27-Jun-08 6:58 
AnswerRe: How to send an email ? Pin
Parwej Ahamad27-Jun-08 7:07
professionalParwej Ahamad27-Jun-08 7:07 
QuestionRe: How to send an email ? Pin
tina->newcoder27-Jun-08 7:25
tina->newcoder27-Jun-08 7:25 
AnswerRe: How to send an email ? Pin
Parwej Ahamad27-Jun-08 7:29
professionalParwej Ahamad27-Jun-08 7:29 
GeneralRe: How to send an email ? Pin
tina->newcoder27-Jun-08 7:49
tina->newcoder27-Jun-08 7:49 
GeneralRe: How to send an email ? Pin
Parwej Ahamad27-Jun-08 8:04
professionalParwej Ahamad27-Jun-08 8:04 
GeneralRe: How to send an email ? Pin
tina->newcoder27-Jun-08 8:16
tina->newcoder27-Jun-08 8:16 
General[Message Deleted] Pin
Parwej Ahamad27-Jun-08 8:17
professionalParwej Ahamad27-Jun-08 8:17 
GeneralRe: How to send an email ? Pin
tina->newcoder27-Jun-08 8:19
tina->newcoder27-Jun-08 8:19 
GeneralRe: How to send an email ? Pin
Parwej Ahamad27-Jun-08 8:21
professionalParwej Ahamad27-Jun-08 8:21 
GeneralRe: How to send an email ? Pin
tina->newcoder27-Jun-08 8:23
tina->newcoder27-Jun-08 8:23 
General[Message Deleted] Pin
Parwej Ahamad27-Jun-08 8:24
professionalParwej Ahamad27-Jun-08 8:24 
GeneralRe: How to send an email ? Pin
tina->newcoder27-Jun-08 8:25
tina->newcoder27-Jun-08 8:25 
GeneralRe: How to send an email ? Pin
tina->newcoder27-Jun-08 8:26
tina->newcoder27-Jun-08 8:26 

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.