Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.vb.general.discussion,microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Excel automation: Why my code is hijacked?

I develop my code with the reference. But when I release it to others, I change
it late binding. I couldn't live without the intellisense, either.

And who knows about quitting the application? I figured that there wasn't
really enough code in that post to venture a guess (no saving, no closing, no
releasing other objects???).

Steve Gerrard wrote:

Dave Peterson wrote:
I should have been more explicit.

My point was since he was using this:

Set moExcelApp = CreateObject("Excel.Application")
instead of
Set moExcelApp = new Excel.application

why not just stick with late binding and drop the reference
completely and declare those variables as Objects?



He would lose intellisense, and have to look all the parameters up to be sure
they were correct, or wait for runtime errors. Also late binding all the calls
would slow the performance down quite a bit. The advantage of using create
object with Excel is that it is not version specific.

Back to the original post, shouldn't there be a
moExcelApp.Quit
before the
Set moExcelApp = Nothing
or is that not needed?


--

Dave Peterson
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
automation code deepika :excel help[_2_] Excel Discussion (Misc queries) 0 February 18th 08 01:48 PM
keyboard shortcut hijacked? jonigr Excel Programming 2 March 19th 06 02:27 AM
Workshoot Menu Bar Hijacked!! Michael Rekas[_3_] Excel Programming 5 July 3rd 05 06:32 AM
Code Librarian automation? R Avery Excel Programming 8 March 21st 05 11:23 PM
Automation Code Problem from Access to Excel Tony Excel Programming 2 April 26th 04 12:58 AM


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

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

About Us

"It's about Microsoft Excel"