none
Path of Workbook RRS feed

  • Question

  • Hi,
    I want to know relevant path of the Workbook, per given codes below

                    using (FileStream fs = new FileStream(openFileDialog1.FileName, FileMode.Open, FileAccess.Read, FileShare.ReadWrite))
                    {
                        
                        using (SpreadsheetDocument doc = SpreadsheetDocument.Open(fs, false))
                        {
                            WorkbookPart workbookPart = doc.WorkbookPart;
                            ...


    How?

    Many Thanks & Best Regards, Hua Min

    Tuesday, October 4, 2016 8:37 AM

Answers

  • Hi HuaMin Chen,

    According to your description, you could use Workbook.AbsolutePath property, but this property is only available in Office2013.

    For more information, click here to refer to Workbook.AbsolutePath property

    Thanks for your understanding.

    • Proposed as answer by David_JunFeng Friday, October 14, 2016 9:33 AM
    • Marked as answer by David_JunFeng Friday, October 14, 2016 9:33 AM
    • Unmarked as answer by David_JunFeng Friday, October 14, 2016 9:33 AM
    • Marked as answer by David_JunFeng Monday, October 17, 2016 2:29 PM
    Wednesday, October 5, 2016 2:12 AM