CrazyTim
CrazyTim

Reputation: 7334

Opening an excel template for editing in VB.NET via Process.Start()

I need to open a .xlt for editing, like so:

System.Diagnostics.Process.Start("Template.xlt", "Editable=True")

But I don't know the correct switch in Excel. This is the same as right-clicking on an .xlt and choosing "Open", whereas the default action is "New".

Thanks.

Upvotes: 1

Views: 1191

Answers (1)

Nick Spreitzer
Nick Spreitzer

Reputation: 10598

Process.Start("Excel.exe", @"C:\Users\Master\Desktop\Book1.xltx");

(Looks like in VB you just omit the @ and ;.)

Upvotes: 3

Related Questions