Click here to Skip to main content
15,887,596 members
Home / Discussions / C#
   

C#

 
AnswerRe: Remove all characters in a string up to and including a specified pattern Pin
sanforjackass2-Feb-10 5:33
sanforjackass2-Feb-10 5:33 
GeneralRe: Remove all characters in a string up to and including a specified pattern Pin
OriginalGriff2-Feb-10 5:42
mveOriginalGriff2-Feb-10 5:42 
AnswerRe: Remove all characters in a string up to and including a specified pattern Pin
OkkiePepernoot2-Feb-10 6:01
OkkiePepernoot2-Feb-10 6:01 
GeneralRe: Remove all characters in a string up to and including a specified pattern Pin
MarkB1232-Feb-10 8:28
MarkB1232-Feb-10 8:28 
AnswerRe: Remove all characters in a string up to and including a specified pattern Pin
Ramkithepower3-Feb-10 1:38
Ramkithepower3-Feb-10 1:38 
GeneralRe: Remove all characters in a string up to and including a specified pattern Pin
MarkB1233-Feb-10 11:37
MarkB1233-Feb-10 11:37 
Questionzooming/panning Pin
sarai002-Feb-10 5:24
sarai002-Feb-10 5:24 
QuestionC# Create Excelfile Pin
Mschauder2-Feb-10 3:26
Mschauder2-Feb-10 3:26 
Hey guys sorry for disturbing again....

now a new and intressting problem:

I have installed now Office XP && Office 2007. If I create a new excelfile with
worksheet.SaveAs(txtSavePfad.Text, t, t, t, t, t, t, t, t, t);
it become a ".xls"

Previous I only had Office 2007 and the same code created a ".xlsx" file then I used the following code to create a ".xls":
worksheet.SaveAs(txtSavePfad.Text, XlFileFormat.xlExcel8, t, t, t, t, t, t, t, t);

I've a string with the full path, it contains which format I want to use... ("a\b\c\2003.xls" or "a\b\c\2007.xlsx")

if (txtSavePfad.Text.Substring(txtSavePfad.Text.LastIndexOf(".")) == ".xls")
   worksheet.SaveAs(txtSavePfad.Text, XlFileFormat.xlExcel8, t, t, t, t, t, t, t, t);
else if (txtSavePfad.Text.Substring(txtSavePfad.Text.LastIndexOf(".")) == ".xlsx")
   worksheet.SaveAs(txtSavePfad.Text, t, t, t, t, t, t, t, t, t);
excelApp.Quit();


so what could I do to save the file in the right form? Confused | :confused:

greets Mschauder
AnswerRe: C# Create Excelfile Pin
The Man from U.N.C.L.E.2-Feb-10 3:40
The Man from U.N.C.L.E.2-Feb-10 3:40 
QuestionGmail Samples Pin
Anil Kumar.Arvapalli2-Feb-10 3:17
Anil Kumar.Arvapalli2-Feb-10 3:17 
AnswerRe: Gmail Samples Pin
WoutL2-Feb-10 3:23
WoutL2-Feb-10 3:23 
AnswerRe: Gmail Samples Pin
Abhinav S2-Feb-10 3:44
Abhinav S2-Feb-10 3:44 
QuestionTrouble with drawing on winfrom in new thread Pin
Frozzeg2-Feb-10 2:45
Frozzeg2-Feb-10 2:45 
AnswerRe: Trouble with drawing on winfrom in new thread Pin
Luc Pattyn2-Feb-10 3:29
sitebuilderLuc Pattyn2-Feb-10 3:29 
AnswerRe: Trouble with drawing on winfrom in new thread Pin
The Man from U.N.C.L.E.2-Feb-10 3:52
The Man from U.N.C.L.E.2-Feb-10 3:52 
GeneralRe: Trouble with drawing on winfrom in new thread Pin
Frozzeg2-Feb-10 8:00
Frozzeg2-Feb-10 8:00 
GeneralRe: Trouble with drawing on winfrom in new thread Pin
Dave Kreskowiak2-Feb-10 8:53
mveDave Kreskowiak2-Feb-10 8:53 
QuestionComboBox index Databind Pin
Kaikus2-Feb-10 2:22
Kaikus2-Feb-10 2:22 
AnswerRe: ComboBox index Databind Pin
The Man from U.N.C.L.E.2-Feb-10 4:01
The Man from U.N.C.L.E.2-Feb-10 4:01 
Question.NET applications? Pin
ppayal2-Feb-10 0:12
ppayal2-Feb-10 0:12 
AnswerRe: .NET applications? Pin
OriginalGriff2-Feb-10 0:19
mveOriginalGriff2-Feb-10 0:19 
AnswerRe: .NET applications? Pin
Keith Barrow2-Feb-10 0:19
professionalKeith Barrow2-Feb-10 0:19 
GeneralRe: .NET applications? Pin
OriginalGriff2-Feb-10 0:32
mveOriginalGriff2-Feb-10 0:32 
GeneralRe: .NET applications? Pin
Daniel Grunwald2-Feb-10 1:37
Daniel Grunwald2-Feb-10 1:37 
GeneralRe: .NET applications? Pin
OriginalGriff2-Feb-10 2:52
mveOriginalGriff2-Feb-10 2:52 

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.