Quantcast
Channel: Excel IT Pro Discussions forum
Viewing all articles
Browse latest Browse all 11829

how to specify the sheet name while writing data into excel

$
0
0
_Workbook workbook = (_Workbook)(excelapp.Workbooks.Open(@"E:\ScriptTest\c.xlsx"));
                workbook.Sheets.Add();
                _Worksheet worksheet = (_Worksheet)workbook.ActiveSheet;

Line 1 Selection of excel sheet

Line 2:I am intersted in Adding the new sheet

Line3:Selection of Sheet

I want to select may be sheet 2 or sheet 3 like that

How to specify ?

And instead of just Add() can we specify name of sheet to be created also If yes how ?


Viewing all articles
Browse latest Browse all 11829

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>