Click here to Skip to main content
15,905,238 members
Home / Discussions / C#
   

C#

 
AnswerRe: Session.clear ans session.abandon Pin
Pete O'Hanlon9-Sep-07 22:55
mvePete O'Hanlon9-Sep-07 22:55 
AnswerRe: Session.clear ans session.abandon Pin
Guffa9-Sep-07 23:10
Guffa9-Sep-07 23:10 
GeneralRe: Session.clear ans session.abandon Pin
Sonia Gupta9-Sep-07 23:17
Sonia Gupta9-Sep-07 23:17 
GeneralRe: Session.clear ans session.abandon Pin
Pete O'Hanlon9-Sep-07 23:29
mvePete O'Hanlon9-Sep-07 23:29 
GeneralRe: Session.clear ans session.abandon Pin
Sonia Gupta9-Sep-07 23:34
Sonia Gupta9-Sep-07 23:34 
AnswerRe: Session.clear ans session.abandon Pin
Guffa9-Sep-07 23:41
Guffa9-Sep-07 23:41 
GeneralRe: Session.clear ans session.abandon Pin
Sonia Gupta9-Sep-07 23:55
Sonia Gupta9-Sep-07 23:55 
GeneralRe: Session.clear ans session.abandon Pin
Pete O'Hanlon10-Sep-07 0:01
mvePete O'Hanlon10-Sep-07 0:01 
GeneralRe: Session.clear ans session.abandon Pin
Sonia Gupta10-Sep-07 0:04
Sonia Gupta10-Sep-07 0:04 
GeneralRe: Session.clear ans session.abandon Pin
Pete O'Hanlon10-Sep-07 0:28
mvePete O'Hanlon10-Sep-07 0:28 
GeneralRe: Session.clear ans session.abandon Pin
Virendrak10-Sep-07 1:34
Virendrak10-Sep-07 1:34 
GeneralRe: Session.clear ans session.abandon Pin
Pete O'Hanlon10-Sep-07 1:42
mvePete O'Hanlon10-Sep-07 1:42 
GeneralRe: Session.clear ans session.abandon Pin
Virendrak10-Sep-07 1:36
Virendrak10-Sep-07 1:36 
AnswerRe: Session.clear ans session.abandon Pin
Guffa10-Sep-07 11:02
Guffa10-Sep-07 11:02 
AnswerRe: Session.clear ans session.abandon Pin
Guffa9-Sep-07 23:39
Guffa9-Sep-07 23:39 
GeneralRe: Session.clear ans session.abandon Pin
Sonia Gupta9-Sep-07 23:42
Sonia Gupta9-Sep-07 23:42 
QuestionWrong compilation error message Pin
vikben9-Sep-07 22:12
vikben9-Sep-07 22:12 
AnswerRe: Wrong compilation error message Pin
Pete O'Hanlon9-Sep-07 22:50
mvePete O'Hanlon9-Sep-07 22:50 
GeneralRe: Wrong compilation error message Pin
vikben9-Sep-07 23:44
vikben9-Sep-07 23:44 
GeneralRe: Wrong compilation error message Pin
Pete O'Hanlon10-Sep-07 1:25
mvePete O'Hanlon10-Sep-07 1:25 
QuestionHelp with C# generated Excel documents Pin
dadart9-Sep-07 22:01
dadart9-Sep-07 22:01 
I have 2 Excel files...

1. the original Excel file that was given to me to be converted to a dataset and so I could fill up the SQL Database.
2. the other is the one I retrieved from the database and then generated into an Excel document. used a similar procedure
to that of the tutorial here... a low-tech version of generating Excel files... using the XML spreadsheet style in one of the tutorials...

I open both Excel files (the original and generated excel file) and they look identical and they even contain the exact same data in each cells...

now here's the problem...I need to make a method that checks whether or not they're equivalent or not to see if any data is lost since checking each
cell of a large excel file would take a lot of time...

so I use OleDB that comes with C# Express since we're not suppose to use any 3rd party dlls...
for a temporary method to test whether they're equal is, I try to convert the 2 excel documents to 2 datasets and then compare the two generated datasets
whether or not they are equivalent to each other...


public static DataSet Method()
{
    string connectionString = @"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=FILE_PATH;Extended Properties=""Excel 8.0;HDR=YES;""";

    OleDbConnection conn = new OleDbConnection(connectionString);
    OleDbCommand cmd = new OleDbCommand("Select * from [Project List$]", conn);
    cmd.CommandType = CommandType.Text;
    OleDbDataAdapter myAdapter = new OleDbDataAdapter(cmd);
    DataSet ds = new DataSet();

    try
    {
        myAdapter.Fill(ds);
        return ds;
    }
    catch(OleDbException ex)
    {
        throw ex;
    }
}


the original converts to a dataset with no problem but when I try to convert the one generated from the database is catches an OleDbException...

OleDBException was caught:
External table is not in the expected format.

how come? and is there any word around to this problem without using any 3rd party dlls? or downloading any additional dlls from Microsoft?

so we tried another method... used XmlDocument to get the dataset... and then compared it to one another and yet they were not equal? any suggestions?
AnswerRe: Help with C# generated Excel documents Pin
Giorgi Dalakishvili9-Sep-07 22:17
mentorGiorgi Dalakishvili9-Sep-07 22:17 
QuestionNUnit tests issue [modified] Pin
Johan Lombaard9-Sep-07 21:53
Johan Lombaard9-Sep-07 21:53 
AnswerRe: NUnit tests issue Pin
Pete O'Hanlon9-Sep-07 22:44
mvePete O'Hanlon9-Sep-07 22:44 
GeneralRe: NUnit tests issue Pin
Johan Lombaard9-Sep-07 23:07
Johan Lombaard9-Sep-07 23:07 

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.