Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default tasks-Object ??? or an alternative

Hello

i'm new in excel-programming - and have following problem:

i have in word-vba this makro:
*For Each mytask In Tasks
* If mytask.Name = "Document_Work" Then
* Application.Visible = False
* mytask.SendWindowMessage 1024, 0, 0
* End If
*Next mytask
to find out the application who started this word-session and go back to
this application.

now i want do the same in excel - but i saw, that there is no
"tasks"-object - how could i solve this problem in excel-vba - or who know's
an good alternative-solution.

many thank's in advance
Michael E.


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default tasks-Object ??? or an alternative

YOu could use automation to call into word, like so

Dim wordApp As Object

Set wordApp = CreateObject("Word.Application")
If wordApp.Tasks.Exists("Microsoft Powerpoint") = False Then
MsgBox "No powerpoint"
End If
Set wordApp = Nothing


--

HTH

RP
(remove nothere from the email address if mailing direct)


"M.Erlinger" wrote in message
...
Hello

i'm new in excel-programming - and have following problem:

i have in word-vba this makro:
*For Each mytask In Tasks
* If mytask.Name = "Document_Work" Then
* Application.Visible = False
* mytask.SendWindowMessage 1024, 0, 0
* End If
*Next mytask
to find out the application who started this word-session and go back to
this application.

now i want do the same in excel - but i saw, that there is no
"tasks"-object - how could i solve this problem in excel-vba - or who

know's
an good alternative-solution.

many thank's in advance
Michael E.




  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default tasks-Object ??? or an alternative

Or probably easier to just test for the app like so

Dim App As Object

On Error Resume Next
Set App = GetObject(, "Powerpoint.Application")
If App Is Nothing Then
MsgBox "No powerpoint"
End If
Set App = Nothing


--

HTH

RP
(remove nothere from the email address if mailing direct)


"Bob Phillips" wrote in message
...
YOu could use automation to call into word, like so

Dim wordApp As Object

Set wordApp = CreateObject("Word.Application")
If wordApp.Tasks.Exists("Microsoft Powerpoint") = False Then
MsgBox "No powerpoint"
End If
Set wordApp = Nothing


--

HTH

RP
(remove nothere from the email address if mailing direct)


"M.Erlinger" wrote in message
...
Hello

i'm new in excel-programming - and have following problem:

i have in word-vba this makro:
*For Each mytask In Tasks
* If mytask.Name = "Document_Work" Then
* Application.Visible = False
* mytask.SendWindowMessage 1024, 0, 0
* End If
*Next mytask
to find out the application who started this word-session and go back to
this application.

now i want do the same in excel - but i saw, that there is no
"tasks"-object - how could i solve this problem in excel-vba - or who

know's
an good alternative-solution.

many thank's in advance
Michael E.






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
Counting tasks slavenp Excel Discussion (Misc queries) 0 August 6th 09 04:16 PM
Counting tasks slavenp Excel Discussion (Misc queries) 0 July 29th 09 04:48 PM
Exporting tasks se7098 Excel Worksheet Functions 2 January 21st 09 03:37 PM
Too many client tasks? rml Excel Discussion (Misc queries) 0 July 19th 06 05:41 PM
What Tasks Can Be Automated? John Gregory[_2_] Excel Programming 5 February 2nd 04 06:49 AM


All times are GMT +1. The time now is 11:08 PM.

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"