ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Calling a macro from ActiveX Script. (https://www.excelbanter.com/excel-programming/328498-calling-macro-activex-script.html)

Karunakaran

Calling a macro from ActiveX Script.
 
I have a excel file which I use as a source file for my data import in sql
sever.
One column of this excel file has all email ids and all are as hyperlinks. I
need to remove these hyperlinks and just import the email ids to the
database.

I have a macro which removes the hyperlinks and just keep email address. I
need to run this macro programatically with out user interference. So I need
to have this macro separately and call this on which ever excel file becomes
my source file.

Any way to do this in ActiveXscript.

Thanks and Regards,
Karunakaran

Tushar Mehta

Calling a macro from ActiveX Script.
 
Depending on the scope and definition of 'activex script'..

You can access a macro from 'outside' of the XL workbook containing it
with the Application.Run method. You can even access it with a similar
technique from outside of XL (assuming you are automating XL). In any
case, you should also parameterize the macro so that it accepts as an
argument the range it should operate on.

--
Regards,

Tushar Mehta
www.tushar-mehta.com
Excel, PowerPoint, and VBA add-ins, tutorials
Custom MS Office productivity solutions

In article ,
says...
I have a excel file which I use as a source file for my data import in sql
sever.
One column of this excel file has all email ids and all are as hyperlinks. I
need to remove these hyperlinks and just import the email ids to the
database.

I have a macro which removes the hyperlinks and just keep email address. I
need to run this macro programatically with out user interference. So I need
to have this macro separately and call this on which ever excel file becomes
my source file.

Any way to do this in ActiveXscript.

Thanks and Regards,
Karunakaran



All times are GMT +1. The time now is 12:29 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com