Jump to content

Declare (String SavePath1 = Server.MapPath("CDS/");)help ??

- - - - -

  • Please log in to reply
No replies to this topic

#1
royvb

royvb

    Newbie

  • Members
  • Pip
  • 5 posts
String SavePath1 = Server.MapPath("CDS/");
if (FileUpload1.HasFile)
{

String upFileName1 = FileUpload1.FileName;
SavePath1 += upFileName1;
FileUpload1.SaveAs(SavePath1);

}
else
{
Label1.Text = "Pls upload Excel File";
}

ExcelDataset eds = new ExcelDataset(); //where ExcelDataset is a name of the class file.
DataSet ds = new DataSet();
ds = eds.FillDatasetExcel(SavePath1);
GridView1.DataSource = ds;
GridView1.DataBind();

----------------------------
please assist me code above. let me know
how to declare this (String SavePath1 = Server.MapPath("CDS/")
inside the ("CDS"), what we can put inside.. is there a path or server name? please help me to show some example. very confuse about that.

Thanks,
R0y




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users