Spread ASP.NET 6.0 Product Documentation
Opening a Spread XML File
Send Feedback
Spread ASP.NET 6.0 Product Documentation > Developer's Guide > Managing File Operations > Opening Existing Files > Opening a Spread XML File

Glossary Item Box

Spread can save data or data and formatting to an XML file or a stream, which you can then open back into the FpSpread component. You can open a Spread XML file or stream of an entire component or a specific sheet.

You can also open a file from inside Spread Designer.

Refer to the SheetView class Open method to save a specific sheet. Use the FpSpread Open method to save the entire control.

For instructions for saving Spread XML files, see Saving to a Spread XML File.

Return to the overview at Opening Existing Files.

Using Code

Use the FpSpread component’s Open method, specifying the path and file name of the Spread XML file to open or the Stream object to open.

Example

This example code opens an existing Spread-compatible XML file.

C# Copy Code
// Open a Spread-compatible XML file.
FpSpread1.Open("c:\spreadfile");
VB Copy Code
' Open a Spread-compatible XML file.
FpSpread1.Open("c:\spreadfile")

Using the Spread Designer

  1. Select the File menu.
  2. Choose the Open option.
  3. A dialog appears warning you that you will overwrite your existing settings if you open a file. Click Yes to continue with the file open.

    The Open dialog appears.

  4. Change the Files of type box to Spread files (*.XML).
  5. Specify the path and file name of the file to open, and then click Open.

    If the file is opened successfully, a message appears stating the file has been opened.

  6. Click OK to close the Spread Designer.
© 2002-2012 GrapeCity, Inc. All Rights Reserved.