Click here to Skip to main content
15,886,100 members
Home / Discussions / C#
   

C#

 
QuestionLoading images into Image list - Problem Pin
S K Y2-Mar-09 14:14
S K Y2-Mar-09 14:14 
AnswerRe: Loading images into Image list - Problem Pin
Luc Pattyn2-Mar-09 14:34
sitebuilderLuc Pattyn2-Mar-09 14:34 
GeneralRe: Loading images into Image list - Problem Pin
S K Y2-Mar-09 14:54
S K Y2-Mar-09 14:54 
AnswerRe: Loading images into Image list - Problem Pin
Luc Pattyn2-Mar-09 15:34
sitebuilderLuc Pattyn2-Mar-09 15:34 
GeneralRe: Loading images into Image list - Problem Pin
S K Y2-Mar-09 16:00
S K Y2-Mar-09 16:00 
AnswerRe: Loading images into Image list - Problem Pin
Luc Pattyn2-Mar-09 16:15
sitebuilderLuc Pattyn2-Mar-09 16:15 
GeneralRe: Loading images into Image list - Problem Pin
S K Y2-Mar-09 16:59
S K Y2-Mar-09 16:59 
QuestionLittle problem. When I get data from excel file Pin
sizers2-Mar-09 12:49
sizers2-Mar-09 12:49 
I'm building some logic.
Inserting data from excel file of microsoft office.
So I made some logic like this

private DataSet ReadXLS(string FileName)
{
 DataSet ds = new DataSet();
 OleDbDataAdapter adapter;
 string connectionString = @"provider=Microsoft.Jet.OLEDB.4.0;data source="
  + FileName + ";Extended Properties=\"Excel 8.0;Imex=1\"";
 OleDbConnection conn = new OleDbConnection(connectionString);
 try
 {
  adapter = new OleDbDataAdapter("SELECT * FROM [Sheet1$]", conn);
  adapter.Fill(ds, strSheet);
 }
 catch
 {
  //
 }
 finally
 {
  if (conn.State == ConnectionState.Open) conn.Close();   }
 return ds;
}



But this code has little problem.
The first line of excel sheet data is set to header column automatically.
In addition the header name automatically replaced to other characters
if it is number type.

I just want to get whole data from a excel sheet.
Help me.
QuestionHow to get default/perferred Network Connection Pin
TheFM2342-Mar-09 11:24
TheFM2342-Mar-09 11:24 
AnswerRe: How to get default/perferred Network Connection Pin
harold aptroot2-Mar-09 13:00
harold aptroot2-Mar-09 13:00 
QuestionHas anybody ever seen this IO exception before? Pin
snorkie2-Mar-09 11:20
professionalsnorkie2-Mar-09 11:20 
AnswerRe: Has anybody ever seen this IO exception before? Pin
harold aptroot2-Mar-09 11:27
harold aptroot2-Mar-09 11:27 
AnswerRe: Has anybody ever seen this IO exception before? Pin
led mike2-Mar-09 11:30
led mike2-Mar-09 11:30 
GeneralRe: Has anybody ever seen this IO exception before? Pin
snorkie2-Mar-09 11:42
professionalsnorkie2-Mar-09 11:42 
GeneralRe: Has anybody ever seen this IO exception before? Pin
led mike2-Mar-09 11:56
led mike2-Mar-09 11:56 
GeneralRe: Has anybody ever seen this IO exception before? Pin
snorkie2-Mar-09 12:03
professionalsnorkie2-Mar-09 12:03 
AnswerRe: Has anybody ever seen this IO exception before? Pin
Yusuf2-Mar-09 12:15
Yusuf2-Mar-09 12:15 
AnswerRe: Has anybody ever seen this IO exception before? Pin
pbarrette3-Mar-09 15:30
pbarrette3-Mar-09 15:30 
QuestionHow to create an instance of a c++ class inside a dll in a c# project Pin
EcK3kO2-Mar-09 11:16
EcK3kO2-Mar-09 11:16 
AnswerRe: How to create an instance of a c++ class inside a dll in a c# project Pin
led mike2-Mar-09 11:32
led mike2-Mar-09 11:32 
QuestionEasy memory optimizations? Pin
bbranded2-Mar-09 10:54
bbranded2-Mar-09 10:54 
AnswerRe: Easy memory optimizations? Pin
Dave Kreskowiak2-Mar-09 11:04
mveDave Kreskowiak2-Mar-09 11:04 
GeneralRe: Easy memory optimizations? Pin
Yusuf2-Mar-09 12:20
Yusuf2-Mar-09 12:20 
GeneralRe: Easy memory optimizations? Pin
Dave Kreskowiak2-Mar-09 16:43
mveDave Kreskowiak2-Mar-09 16:43 
AnswerRe: Easy memory optimizations? Pin
Luc Pattyn2-Mar-09 11:26
sitebuilderLuc Pattyn2-Mar-09 11: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.