Passing Parameters to Excel.

Passing Parameters to Excel.

Postby byron.hopp » Wed May 06, 2020 11:14 pm

All,

I am puzzeled on how to use some of the methods in Excel, because the parameter passing is unusual.

Dim sheet As Worksheet
Set sheet = ActiveWorkbook.Sheets.Add(After:=ActiveWorkbook.Worksheets(ActiveWorkbook.Worksheets.Count))

Is there a way to make this work in Harbour / Fivewin?

Thanks,

Byron ...
Thanks,
Byron Hopp
Matrix Computer Services
byron.hopp
 
Posts: 372
Joined: Sun Nov 06, 2005 3:55 pm
Location: Southern California, USA

Re: Passing Parameters to Excel.

Postby anserkk » Thu May 07, 2020 6:00 am

byron.hopp wrote:Dim sheet As Worksheet
Set sheet = ActiveWorkbook.Sheets.Add(After:=ActiveWorkbook.Worksheets(ActiveWorkbook.Worksheets.Count))


Try
Code: Select all  Expand view
oSheet := oExcel:ActiveWorkbook:Sheets:Add( oExcel:ActiveWorkbook:Worksheets( oExcel:ActiveWorkbook:Worksheets:Count() ) )
User avatar
anserkk
 
Posts: 1332
Joined: Fri Jun 13, 2008 11:04 am
Location: Kochi, India

Re: Passing Parameters to Excel.

Postby byron.hopp » Thu May 07, 2020 6:25 am

Thank you, if that is "After" then how would you do before?
Thanks,
Byron Hopp
Matrix Computer Services
byron.hopp
 
Posts: 372
Joined: Sun Nov 06, 2005 3:55 pm
Location: Southern California, USA


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot], Jimmy and 52 guests