Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default make outlook visible

After using a bit of code that send an email to outlook I get the email
warning message. Sometimes that message remains in the backround.

How do I bring the allready open outlook program to the foreground on
my desktop in VBA code?

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default make outlook visible

olApp.Visible = True

--

HTH

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


"gopher" wrote in message
ups.com...
After using a bit of code that send an email to outlook I get the email
warning message. Sometimes that message remains in the backround.

How do I bring the allready open outlook program to the foreground on
my desktop in VBA code?



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default make outlook visible

it's still not working,...

Dim ol As Object, myItem As Object
Set ol = CreateObject("outlook.application")
Set myItem = ol.CreateItem(olMailItem)
myItem.To = Range("E2").Value
myItem.Subject = "A NEW PURCHASE ORDER HAS BEEN CREATED"
myItem.Body = "file:" & F & Chr(13) & Chr(13)
myItem.Body = myItem.Body & "This message was automatically
sent By Master PO 3.0"
myItem.Display
olApp.Visible = True ' i get an error here.

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default make outlook visible

That is because you called it ol, so you would use

ol.Visible = True

--

HTH

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


"gopher" wrote in message
oups.com...
it's still not working,...

Dim ol As Object, myItem As Object
Set ol = CreateObject("outlook.application")
Set myItem = ol.CreateItem(olMailItem)
myItem.To = Range("E2").Value
myItem.Subject = "A NEW PURCHASE ORDER HAS BEEN CREATED"
myItem.Body = "file:" & F & Chr(13) & Chr(13)
myItem.Body = myItem.Body & "This message was automatically
sent By Master PO 3.0"
myItem.Display
olApp.Visible = True ' i get an error here.



  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default make outlook visible

Wrong newsgroup: see microsoft.public.outlook



"gopher" a écrit dans le message de news:
...
After using a bit of code that send an email to outlook I get the email
warning message. Sometimes that message remains in the backround.

How do I bring the allready open outlook program to the foreground on
my desktop in VBA code?





  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default make outlook visible

Right newsgroup, he is doing it from Excel via automation.

--

HTH

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


"Phil" wrote in message
...
Wrong newsgroup: see microsoft.public.outlook



"gopher" a écrit dans le message de news:
...
After using a bit of code that send an email to outlook I get the email
warning message. Sometimes that message remains in the backround.

How do I bring the allready open outlook program to the foreground on
my desktop in VBA code?





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 do I make one column or row always visible? Ao Excel Discussion (Misc queries) 8 April 23rd 23 09:01 PM
Make Object(s) Visible Dennis Excel Discussion (Misc queries) 2 May 19th 09 06:24 PM
Copy and paste visible cells to outlook Tania UK Excel Discussion (Misc queries) 1 June 26th 07 02:56 PM
better search: "make worksheet visible" christo Excel Discussion (Misc queries) 1 December 1st 04 12:20 AM
Make Command Button visible only in .xlt? RPIJG[_23_] Excel Programming 2 May 17th 04 07:14 PM


All times are GMT +1. The time now is 05:04 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"