Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Include external file .BAS in Excel VBA


Can i load external .BAS file, with some kind of include or import?
I use this way to get control over the code.

Tks in Advance!

Rafael Porche

--
locoloc
-----------------------------------------------------------------------
locoloco's Profile: http://www.excelforum.com/member.php...fo&userid=1551
View this thread: http://www.excelforum.com/showthread.php?threadid=27084

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Include external file .BAS in Excel VBA


In VB editor you can right click on the project and select Import File.
This allows you to get a .bas into your project. It should work as lon
as none of the code uses commands not included with VBA (i.e. VB onl
commands).

Not sure whether the module is saved again with the spreadsheet o
whether it stays where you found it though. Probably with th
spreadsheet, but you should check.



--
kkkni
-----------------------------------------------------------------------
kkknie's Profile: http://www.excelforum.com/member.php...nfo&userid=754
View this thread: http://www.excelforum.com/showthread.php?threadid=27084

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Include external file .BAS in Excel VBA

Sub AddCode()
ThisWorkbook.VBProject.VBComponents.Import _
FileName:="Y:\Docs\bovey\modAPIPlaySoundA.bas"
End Sub

--
Regards,
Tom Ogilvy



"locoloco" wrote in message
...

Can i load external .BAS file, with some kind of include or import?
I use this way to get control over the code.

Tks in Advance!

Rafael Porcher


--
locoloco
------------------------------------------------------------------------
locoloco's Profile:

http://www.excelforum.com/member.php...o&userid=15511
View this thread: http://www.excelforum.com/showthread...hreadid=270842



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How can I include file properties in an excel spreadsheet Graham Bartlett Excel Discussion (Misc queries) 1 August 29th 07 01:46 PM
Include password in formula that links to a protected excel file PR2000 Excel Discussion (Misc queries) 1 June 26th 07 07:16 PM
how to include fonts file in excel document to send outside? Atul from Solan INDIA Excel Discussion (Misc queries) 1 January 19th 07 08:21 PM
How do I include a supporting help file for a excel function? nmgraham Excel Worksheet Functions 1 February 22nd 06 11:34 PM
How can I include bmp file in excel 2000 header? siv Excel Worksheet Functions 1 November 4th 05 02:58 PM


All times are GMT +1. The time now is 10:35 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"