A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Outlook and VBA
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

O2003 - Open Group Calendar connected to public folder



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old August 18th 06, 10:57 AM posted to microsoft.public.outlook.program_vba
Frank Bouillon
external usenet poster
 
Posts: 3
Default O2003 - Open Group Calendar connected to public folder

Hi,

I made a macro (O 2003), wich changes to a public calendar folder and opens
a group calendar connected to this calendar via SendKeys.

On my machine that's working fine even if I am in an email or contacts
folder.

On my clients machines the macro overhauls itself and the menubar for the
calendar is not yet available when I trigger SendKeys.

************** CODE ****************
Function OpenGroupCalendar(strGTP As String)
Dim ALL_VAR As OBJECT_XY

Set myOlApp = CreateObject("Outlook.Application")
Set myNameSpace = myOlApp.GetNamespace("MAPI")

Set myFolder = myNameSpace.Folders("Public Folder").Folders("All Public
Folders").Folders("CompanyXY").Folders("CalendarAc counting")


Set myExplorer = myOlApp.ActiveExplorer
Set myExplorer.CurrentFolder = myFolder

Set cbb = ActiveExplorer.CommandBars.FindControl(, 7002)
SendKeys "%ö"
If Not cbb Is Nothing Then cbb.Execute

Set ALL_VAR = Nothing
End Function
************ END OF CODE **************

Thank you
Frank


Ads
  #2  
Old August 19th 06, 09:22 AM posted to microsoft.public.outlook.program_vba
Michael Bauer [MVP - Outlook]
external usenet poster
 
Posts: 1,885
Default O2003 - Open Group Calendar connected to public folder

Am Fri, 18 Aug 2006 10:57:31 +0200 schrieb Frank Bouillon:

Frank, SendKeys is never a stable solution. In your case, what should that
be good for?

If you want to make that group calendar the current one then you could do
that directly:

Dim Folder as Outlook.MapiFolder
Set Folder = ....
Set Application.ActiveExplorer.CurrentFolder = Folder

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
-- www.VBOffice.net --


Hi,

I made a macro (O 2003), wich changes to a public calendar folder and

opens
a group calendar connected to this calendar via SendKeys.

On my machine that's working fine even if I am in an email or contacts
folder.

On my clients machines the macro overhauls itself and the menubar for the
calendar is not yet available when I trigger SendKeys.

************** CODE ****************
Function OpenGroupCalendar(strGTP As String)
Dim ALL_VAR As OBJECT_XY

Set myOlApp = CreateObject("Outlook.Application")
Set myNameSpace = myOlApp.GetNamespace("MAPI")

Set myFolder = myNameSpace.Folders("Public Folder").Folders("All

Public
Folders").Folders("CompanyXY").Folders("CalendarAc counting")


Set myExplorer = myOlApp.ActiveExplorer
Set myExplorer.CurrentFolder = myFolder

Set cbb = ActiveExplorer.CommandBars.FindControl(, 7002)
SendKeys "%í±€í»Š If Not cbb Is Nothing Then cbb.Execute

Set ALL_VAR = Nothing
End Function
************ END OF CODE **************

Thank you
Frank

  #3  
Old August 19th 06, 02:08 PM posted to microsoft.public.outlook.program_vba
Sue Mosher [MVP-Outlook]
external usenet poster
 
Posts: 11,651
Default O2003 - Open Group Calendar connected to public folder

Michael, I think Frank is talking not about a calendar folder but about a group calendar item. Those aren't accessible programmatically, except to set properties with CDO or Redemption.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003
http://www.turtleflock.com/olconfig/index.htm
and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
http://www.outlookcode.com/jumpstart.aspx

"Michael Bauer [MVP - Outlook]" wrote in message .. .
Am Fri, 18 Aug 2006 10:57:31 +0200 schrieb Frank Bouillon:

Frank, SendKeys is never a stable solution. In your case, what should that
be good for?

If you want to make that group calendar the current one then you could do
that directly:

Dim Folder as Outlook.MapiFolder
Set Folder = ....
Set Application.ActiveExplorer.CurrentFolder = Folder

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
-- www.VBOffice.net --


Hi,

I made a macro (O 2003), wich changes to a public calendar folder and

opens
a group calendar connected to this calendar via SendKeys.

On my machine that's working fine even if I am in an email or contacts
folder.

On my clients machines the macro overhauls itself and the menubar for the
calendar is not yet available when I trigger SendKeys.

************** CODE ****************
Function OpenGroupCalendar(strGTP As String)
Dim ALL_VAR As OBJECT_XY

Set myOlApp = CreateObject("Outlook.Application")
Set myNameSpace = myOlApp.GetNamespace("MAPI")

Set myFolder = myNameSpace.Folders("Public Folder").Folders("All

Public
Folders").Folders("CompanyXY").Folders("CalendarAc counting")


Set myExplorer = myOlApp.ActiveExplorer
Set myExplorer.CurrentFolder = myFolder

Set cbb = ActiveExplorer.CommandBars.FindControl(, 7002)
SendKeys "%í±€í»Š If Not cbb Is Nothing Then cbb.Execute

Set ALL_VAR = Nothing
End Function
************ END OF CODE **************

Thank you
Frank

  #4  
Old August 20th 06, 08:16 AM posted to microsoft.public.outlook.program_vba
Michael Bauer [MVP - Outlook]
external usenet poster
 
Posts: 1,885
Default O2003 - Open Group Calendar connected to public folder

Am Sat, 19 Aug 2006 08:08:33 -0400 schrieb Sue Mosher [MVP-Outlook]:

Oh, you´re right.

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
-- www.VBOffice.net --


Michael, I think Frank is talking not about a calendar folder but about a

group calendar item. Those aren't accessible programmatically, except to set
properties with CDO or Redemption.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003
http://www.turtleflock.com/olconfig/index.htm
and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
http://www.outlookcode.com/jumpstart.aspx

"Michael Bauer [MVP - Outlook]" wrote in message

.. .
Am Fri, 18 Aug 2006 10:57:31 +0200 schrieb Frank Bouillon:

Frank, SendKeys is never a stable solution. In your case, what should

that
be good for?

If you want to make that group calendar the current one then you could do
that directly:

Dim Folder as Outlook.MapiFolder
Set Folder = ....
Set Application.ActiveExplorer.CurrentFolder = Folder

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
-- www.VBOffice.net --


Hi,

I made a macro (O 2003), wich changes to a public calendar folder and

opens
a group calendar connected to this calendar via SendKeys.

On my machine that's working fine even if I am in an email or contacts
folder.

On my clients machines the macro overhauls itself and the menubar for

the
calendar is not yet available when I trigger SendKeys.

************** CODE ****************
Function OpenGroupCalendar(strGTP As String)
Dim ALL_VAR As OBJECT_XY

Set myOlApp = CreateObject("Outlook.Application")
Set myNameSpace = myOlApp.GetNamespace("MAPI")

Set myFolder = myNameSpace.Folders("Public Folder").Folders("All

Public
Folders").Folders("CompanyXY").Folders("CalendarAc counting")


Set myExplorer = myOlApp.ActiveExplorer
Set myExplorer.CurrentFolder = myFolder

Set cbb = ActiveExplorer.CommandBars.FindControl(, 7002)
SendKeys "%í±€í»Š If Not cbb Is Nothing Then cbb.Execute

Set ALL_VAR = Nothing
End Function
************ END OF CODE **************

Thank you
Frank

  #5  
Old August 21st 06, 06:12 PM posted to microsoft.public.outlook.program_vba
Frank Bouillon
external usenet poster
 
Posts: 3
Default O2003 - Open Group Calendar connected to public folder

Hi Sue,
you're right.

.... but unfortunately that doesn't help me any further.

It works with SendKeys but if the menubar is not yet available its useless.

I thought doing a little Loop until the menubar is available but I don't
know how to check this.

Something like:
Do until Application.MenuBars("CalendarMenuBar") = True
x = x + 1
Loop

Thanks for any futher help.
Frank


"Sue Mosher [MVP-Outlook]
" Michael, I think Frank is talking not about a calendar folder but about a
group calendar item. Those aren't accessible programmatically, except to set
properties with CDO or Redemption.

"Michael Bauer [MVP - Outlook]"
Frank, SendKeys is never a stable solution. In your case, what should that
be good for?

If you want to make that group calendar the current one then you could do
that directly:

Dim Folder as Outlook.MapiFolder
Set Folder = ....
Set Application.ActiveExplorer.CurrentFolder = Folder


Hi,

I made a macro (O 2003), wich changes to a public calendar folder and

opens
a group calendar connected to this calendar via SendKeys.

On my machine that's working fine even if I am in an email or contacts
folder.

On my clients machines the macro overhauls itself and the menubar for the
calendar is not yet available when I trigger SendKeys.

************** CODE ****************
Function OpenGroupCalendar(strGTP As String)
Dim ALL_VAR As OBJECT_XY

Set myOlApp = CreateObject("Outlook.Application")
Set myNameSpace = myOlApp.GetNamespace("MAPI")

Set myFolder = myNameSpace.Folders("Public Folder").Folders("All

Public
Folders").Folders("CompanyXY").Folders("CalendarAc counting")


Set myExplorer = myOlApp.ActiveExplorer
Set myExplorer.CurrentFolder = myFolder

Set cbb = ActiveExplorer.CommandBars.FindControl(, 7002)
SendKeys "%?? If Not cbb Is Nothing Then cbb.Execute

Set ALL_VAR = Nothing
End Function
************ END OF CODE **************

Thank you
Frank



 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Search folder with no categories in O2003? [email protected] Outlook - General Queries 2 June 16th 06 08:41 AM
Outlook 2007 - can't open a calendar within a public folder Bryan S. Outlook - Calandaring 1 June 6th 06 09:25 PM
O2003: exchange and imap emails arriving in same folder [email protected] Outlook - General Queries 5 May 13th 06 02:25 AM
O2003+SBS: Automatic formatting in views of public folders Jan Serpieters Outlook - Installation 5 April 6th 06 08:50 PM
O2003+SBS: Automatic formatting in views of public folders Jan Serpieters Outlook - Installation 0 March 21st 06 08:00 AM


All times are GMT +1. The time now is 10:25 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.