Click here to Skip to main content
16,005,697 members
Home / Discussions / C#
   

C#

 
GeneralRe: Syntax for passing methods without declaring a delegate Pin
Domenic Denicola13-Oct-07 20:46
Domenic Denicola13-Oct-07 20:46 
GeneralRe: Syntax for passing methods without declaring a delegate Pin
Judah Gabriel Himango14-Oct-07 8:57
sponsorJudah Gabriel Himango14-Oct-07 8:57 
QuestionProblem Reading Excel File ? Pin
zinc_z13-Oct-07 7:00
zinc_z13-Oct-07 7:00 
QuestionUsing streamwriter into xls. file Pin
andredani13-Oct-07 4:11
andredani13-Oct-07 4:11 
AnswerRe: Using streamwriter into xls. file Pin
pmarfleet13-Oct-07 4:37
pmarfleet13-Oct-07 4:37 
GeneralRe: Using streamwriter into xls. file Pin
andredani13-Oct-07 5:12
andredani13-Oct-07 5:12 
GeneralRe: Using streamwriter into xls. file Pin
pmarfleet13-Oct-07 5:19
pmarfleet13-Oct-07 5:19 
GeneralRe: Using streamwriter into xls. file Pin
andredani13-Oct-07 6:16
andredani13-Oct-07 6:16 
ok..
my code to send info from my listview to a .xls file look like this:

string[] lines3 = System.IO.File.ReadAllLines("datainställningar.txt");
string path3 = lines3[0];
string text = textBox1.Text;
string namn = text + ".xls";
if (MessageBox.Show("Vill du skapa diagramet " + text + "?", "Mitt jobb",
MessageBoxButtons.YesNo, MessageBoxIcon.Question)
== DialogResult.Yes)
{
using (StreamWriter sw = new StreamWriter(path3 + namn))
{
for (int listIndex = 0; listIndex < this.listView2.Items.Count; listIndex++)
{
sw.WriteLine(this.listView2.Items[listIndex].Text + this.listView2.Items[listIndex].SubItems[1].Text + this.listView2.Items[listIndex].SubItems[2].Text + this.listView2.Items[listIndex].SubItems[3].Text);
}
Process.Start(namn);
}
}

But now it´s writes in only a1 cells in .xls, but i want it to write every subitems in each cell.

is it more clearly now??

tnx
GeneralRe: Using streamwriter into xls. file Pin
pmarfleet13-Oct-07 6:36
pmarfleet13-Oct-07 6:36 
GeneralRe: Using streamwriter into xls. file Pin
Giorgi Dalakishvili13-Oct-07 6:47
mentorGiorgi Dalakishvili13-Oct-07 6:47 
GeneralRe: Using streamwriter into xls. file Pin
Dave Kreskowiak13-Oct-07 9:21
mveDave Kreskowiak13-Oct-07 9:21 
GeneralRe: Using streamwriter into xls. file Pin
darkelv14-Oct-07 16:02
darkelv14-Oct-07 16:02 
GeneralRe: Using streamwriter into xls. file Pin
Dave Kreskowiak14-Oct-07 16:16
mveDave Kreskowiak14-Oct-07 16:16 
Questioncreate a .csv file using a variable as the name Pin
mocasu13-Oct-07 3:35
mocasu13-Oct-07 3:35 
AnswerRe: create a .csv file using a variable as the name Pin
Guffa13-Oct-07 4:04
Guffa13-Oct-07 4:04 
GeneralRe: create a .csv file using a variable as the name Pin
mocasu13-Oct-07 4:08
mocasu13-Oct-07 4:08 
GeneralRe: create a .csv file using a variable as the name Pin
mocasu13-Oct-07 4:12
mocasu13-Oct-07 4:12 
GeneralRe: create a .csv file using a variable as the name Pin
Colin Angus Mackay13-Oct-07 4:15
Colin Angus Mackay13-Oct-07 4:15 
GeneralRe: create a .csv file using a variable as the name Pin
mocasu13-Oct-07 4:25
mocasu13-Oct-07 4:25 
JokeRe: create a .csv file using a variable as the name Pin
Colin Angus Mackay13-Oct-07 4:30
Colin Angus Mackay13-Oct-07 4:30 
GeneralRe: create a .csv file using a variable as the name Pin
mocasu13-Oct-07 4:34
mocasu13-Oct-07 4:34 
GeneralRe: create a .csv file using a variable as the name Pin
Colin Angus Mackay13-Oct-07 4:41
Colin Angus Mackay13-Oct-07 4:41 
GeneralRe: create a .csv file using a variable as the name Pin
DaveX8613-Oct-07 4:57
DaveX8613-Oct-07 4:57 
GeneralRe: create a .csv file using a variable as the name [modified] Pin
mocasu13-Oct-07 5:05
mocasu13-Oct-07 5:05 
GeneralRe: create a .csv file using a variable as the name Pin
DaveX8613-Oct-07 5:19
DaveX8613-Oct-07 5:19 

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.