Solved

Focus between Excel and Word

Posted on 2001-06-26
5
184 Views
Last Modified: 2010-05-02
Why can't I seem to set the focus between Word97/2000 and Excel97/2000?  Some times the programs will get focus but not become topmost other times no focus is granted.  How can I consistantly cycle between the two applications?
0
Comment
Question by:rb982996
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 143

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 100 total points
ID: 6227458
What method did you use?
In VB, my favorite is the AppActivate method:

Dim objWord as Object
set objWord = GetObject(,"Word.Application")
AppActivate objWord.Caption

(same for Excel)

Cheers
0
 
LVL 4

Expert Comment

by:WolfgangKoenig
ID: 6227475
You can do like something:
MyExcelApp.Visible = True
-> This take the focus on it

MyExcelApp.WindowState = xlMaximized
-> This maximize the application window
0
 
LVL 43

Expert Comment

by:TimCottee
ID: 6227945
WolfgangKoenig, please read the guidelines on comments vs answers at the bottom of this page. I know that you have been warned once at least already in respect of your use of the answer option. If you continue to do so I will report your account to customer services. There are currently at least three questions locked due to your behaviour.
0
 
LVL 1

Expert Comment

by:kodiakbear
ID: 6229522
WolfgangKoenig,
You will find that most experts here will generally post comments instead of answers in order
to keep the question in the high traffic "questions awaiting answers" section.
There is no penalty to you, as the questioner can accept any comment as an answer.
You don't see the accept comment as answer but the person posting the question can.

Also, please note that an 'answer' is supposed to be 100% sure to fix the problem.  
Please see:
http://www.experts-exchange.com/jsp/cmtyExpertsOnly.jsp
Please propose an "Answer" only when you are sure it will 100% solve the questioner's problem,
and is the one and only possible solution for the problem,
and doesn't duplicate a previous comment.


It is difficult for Experts to find questions in need of answers when members interested in
only obtaining points have locked questions.
See the Tips on Comments and Answers at the bottom of the page.

kb
Community Support Moderator
Experts Exchange

I am rejecting your proposed answer because of the previous sited reasons. Welcome to EE, you will find it is a very great place to find and give help in a collaborative way
0
 

Author Comment

by:rb982996
ID: 6246519
angelIII, sorry I have been away for a bit.  I've used the appactivated method before but using the getobject is new to me.  I will try this when I get home from work.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
Introduction While answering a recent question (http://www.experts-exchange.com/Q_27402310.html) in the VB classic zone, I wrote some VB code in the (Office) VBA environment, rather than fire up my older PC.  I didn't post completely correct code o…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question