Infoga bakgrundsbild till Excel

Inställning av arkbakgrund i Microsoft Excel

Så här ställer du in ett arks bakgrundsbild i Microsoft Excel (till exempel Microsoft Excel 2019):

  1. FrånSidlayout menyn, hittaUtskriftsformat och klicka sedan påBakgrund alternativ.

  2. Välj en bild för att ställa in arkets bakgrundsbild.

    Ställa in en arkbakgrund

todo:image_alt_text

Inställningsarkbakgrund med Aspose.Cells

Koden nedan ställer in en bakgrundsbild med en bild från en ström.

// For complete examples and data files, please go to https://github.com/aspose-cells/Aspose.Cells-for-.NET
// Create a new Workbook.
Workbook workbook = new Workbook();
// Get the first worksheet.
Worksheet sheet = workbook.Worksheets[0];
// Set the background image for the worksheet.
sheet.BackgroundImage = File.ReadAllBytes("background.jpg");
// Save the Excel file
workbook.Save("outputBackImageSheet.xlsx");
// Save the HTML file
workbook.Save("outputBackImageSheet.html", SaveFormat.Html);

relaterade artiklar