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

MapiTable in OL 2000 slow



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old November 18th 07, 02:10 PM posted to microsoft.public.outlook.program_vba
Peter Marchert
external usenet poster
 
Posts: 116
Default MapiTable in OL 2000 slow

Hello,

in OL 2000 sql queries are unnormally slow. The following code
sometimes take more then 1 second to finnish (without logon):

Option Explicit

Dim g_objRDOSession As Object

Public Sub Test()

Dim objFolder As Object
Dim sglStart As Single
Dim sglEnd As Single

If g_objRDOSession Is Nothing Then
Set g_objRDOSession = CreateObject("Redemption.RDOSession")
Call g_objRDOSession.Logon("", "", False, False, 0)
End If

Set objFolder = Outlook.Session.GetDefaultFolder(olFolderCalendar)
sglStart = Timer
Debug.Print ExecuteSQL(objFolder)
sglEnd = Timer
Debug.Print "Duration: " & sglEnd - sglStart & " seconds"

End Sub

Public Function ExecuteSQL(ByVal objFolder As Object) As String

Dim objTable As Object
Dim objRecordSet As Object
Dim strSQL As String

Set objTable = CreateObject("Redemption.MAPITable")

objTable.Item = g_objRDOSession.GetFolderFromID(objFolder.EntryID,
_
objFolder.Parent.StoreID).Items

strSQL = "SELECT Subject FROM Folder WHERE (Subject '')"

Set objRecordSet = objTable.ExecSQL(strSQL)

ExecuteSQL = "TEST"

End Function

I tried this code with OL 2000/SP3 on a Win 2000/SP4 machine and an
Exchange Server 2003. I also tried it without Exchange and a local pst
file. Seems to be a little bit faster but not significant. On 2002 and
higher it works fine (tried on XP and Vista machines).

So the question is: Is this a known issu from OL/WIN 2000 or may be
the redemption can cause the problem?

Thanks for any hints.

Peter

--
Infos, workshops & software for
Outlook(R): www.outlook-stuff.com
Ads
  #2  
Old November 18th 07, 02:11 PM posted to microsoft.public.outlook.program_vba
Peter Marchert
external usenet poster
 
Posts: 116
Default MapiTable in OL 2000 slow

Redemption version is 4.5.0.780 but I think to remember I tested it
with 730 too.

On 18 Nov., 15:10, Peter Marchert wrote:
Hello,

in OL 2000 sql queries are unnormally slow. The following code
sometimes take more then 1 second to finnish (without logon):

Option Explicit

Dim g_objRDOSession As Object

Public Sub Test()

Dim objFolder As Object
Dim sglStart As Single
Dim sglEnd As Single

If g_objRDOSession Is Nothing Then
Set g_objRDOSession = CreateObject("Redemption.RDOSession")
Call g_objRDOSession.Logon("", "", False, False, 0)
End If

Set objFolder = Outlook.Session.GetDefaultFolder(olFolderCalendar)
sglStart = Timer
Debug.Print ExecuteSQL(objFolder)
sglEnd = Timer
Debug.Print "Duration: " & sglEnd - sglStart & " seconds"

End Sub

Public Function ExecuteSQL(ByVal objFolder As Object) As String

Dim objTable As Object
Dim objRecordSet As Object
Dim strSQL As String

Set objTable = CreateObject("Redemption.MAPITable")

objTable.Item = g_objRDOSession.GetFolderFromID(objFolder.EntryID,
_
objFolder.Parent.StoreID).Items

strSQL = "SELECT Subject FROM Folder WHERE (Subject '')"

Set objRecordSet = objTable.ExecSQL(strSQL)

ExecuteSQL = "TEST"

End Function

I tried this code with OL 2000/SP3 on a Win 2000/SP4 machine and an
Exchange Server 2003. I also tried it without Exchange and a local pst
file. Seems to be a little bit faster but not significant. On 2002 and
higher it works fine (tried on XP and Vista machines).

So the question is: Is this a known issu from OL/WIN 2000 or may be
the redemption can cause the problem?

Thanks for any hints.

Peter

--
Infos, workshops & software for
Outlook(R):www.outlook-stuff.com


  #3  
Old November 18th 07, 04:00 PM posted to microsoft.public.outlook.program_vba
Dmitry Streblechenko
external usenet poster
 
Posts: 2,116
Default MapiTable in OL 2000 slow

How many items does that folder contain? Is Outlook 2000 using online mode
vs cached in the odler versions of Outlook.
1 second sounds very much reasonable to me...

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool

"Peter Marchert" wrote in message
...
Hello,

in OL 2000 sql queries are unnormally slow. The following code
sometimes take more then 1 second to finnish (without logon):

Option Explicit

Dim g_objRDOSession As Object

Public Sub Test()

Dim objFolder As Object
Dim sglStart As Single
Dim sglEnd As Single

If g_objRDOSession Is Nothing Then
Set g_objRDOSession = CreateObject("Redemption.RDOSession")
Call g_objRDOSession.Logon("", "", False, False, 0)
End If

Set objFolder = Outlook.Session.GetDefaultFolder(olFolderCalendar)
sglStart = Timer
Debug.Print ExecuteSQL(objFolder)
sglEnd = Timer
Debug.Print "Duration: " & sglEnd - sglStart & " seconds"

End Sub

Public Function ExecuteSQL(ByVal objFolder As Object) As String

Dim objTable As Object
Dim objRecordSet As Object
Dim strSQL As String

Set objTable = CreateObject("Redemption.MAPITable")

objTable.Item = g_objRDOSession.GetFolderFromID(objFolder.EntryID,
_
objFolder.Parent.StoreID).Items

strSQL = "SELECT Subject FROM Folder WHERE (Subject '')"

Set objRecordSet = objTable.ExecSQL(strSQL)

ExecuteSQL = "TEST"

End Function

I tried this code with OL 2000/SP3 on a Win 2000/SP4 machine and an
Exchange Server 2003. I also tried it without Exchange and a local pst
file. Seems to be a little bit faster but not significant. On 2002 and
higher it works fine (tried on XP and Vista machines).

So the question is: Is this a known issu from OL/WIN 2000 or may be
the redemption can cause the problem?

Thanks for any hints.

Peter

--
Infos, workshops & software for
Outlook(R): www.outlook-stuff.com



  #4  
Old November 18th 07, 05:23 PM posted to microsoft.public.outlook.program_vba
Peter Marchert
external usenet poster
 
Posts: 116
Default MapiTable in OL 2000 slow

Thanks for your reply, Dmitry.

How many items does that folder contain?

The folder is empty (I`m only testing).


Is Outlook 2000 using online mode?


I´m not sure. Right now I`m testing without an Exchange Server.

Here some results:
1 seconds
0,64 seconds
0,61 seconds
0,54 seconds
0,57 seconds
0,77 seconds

Peter

On 18 Nov., 17:00, "Dmitry Streblechenko" wrote:
How many items does that folder contain? Is Outlook 2000 using online mode
vs cached in the odler versions of Outlook.
1 second sounds very much reasonable to me...

Dmitry Streblechenko (MVP)http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool

"Peter Marchert" wrote in message

...



Hello,


in OL 2000 sql queries are unnormally slow. The following code
sometimes take more then 1 second to finnish (without logon):


Option Explicit


Dim g_objRDOSession As Object


Public Sub Test()


Dim objFolder As Object
Dim sglStart As Single
Dim sglEnd As Single


If g_objRDOSession Is Nothing Then
Set g_objRDOSession = CreateObject("Redemption.RDOSession")
Call g_objRDOSession.Logon("", "", False, False, 0)
End If


Set objFolder = Outlook.Session.GetDefaultFolder(olFolderCalendar)
sglStart = Timer
Debug.Print ExecuteSQL(objFolder)
sglEnd = Timer
Debug.Print "Duration: " & sglEnd - sglStart & " seconds"


End Sub


Public Function ExecuteSQL(ByVal objFolder As Object) As String


Dim objTable As Object
Dim objRecordSet As Object
Dim strSQL As String


Set objTable = CreateObject("Redemption.MAPITable")


objTable.Item = g_objRDOSession.GetFolderFromID(objFolder.EntryID,
_
objFolder.Parent.StoreID).Items


strSQL = "SELECT Subject FROM Folder WHERE (Subject '')"


Set objRecordSet = objTable.ExecSQL(strSQL)


ExecuteSQL = "TEST"


End Function


I tried this code with OL 2000/SP3 on a Win 2000/SP4 machine and an
Exchange Server 2003. I also tried it without Exchange and a local pst
file. Seems to be a little bit faster but not significant. On 2002 and
higher it works fine (tried on XP and Vista machines).


So the question is: Is this a known issu from OL/WIN 2000 or may be
the redemption can cause the problem?


Thanks for any hints.


Peter


--
Infos, workshops & software for
Outlook(R):www.outlook-stuff.com- Zitierten Text ausblenden -


- Zitierten Text anzeigen -


  #5  
Old November 18th 07, 05:31 PM posted to microsoft.public.outlook.program_vba
Peter Marchert
external usenet poster
 
Posts: 116
Default MapiTable in OL 2000 slow

Some more information: If I run the code in a loop:

For lngLoop = 1 To 25
Set objFolder =
Outlook.Session.GetDefaultFolder(olFolderCalendar)
sglStart = Timer
Call ExecuteSQL(objFolder)
sglEnd = Timer
Debug.Print "Duration: " & sglEnd - sglStart & " seconds"
Next lngLoop

It takes for every loop nearly exactly 1 second to finnish.

Peter

On 18 Nov., 18:23, Peter Marchert wrote:
Thanks for your reply, Dmitry.

How many items does that folder contain?


The folder is empty (I`m only testing).

Is Outlook 2000 using online mode?


I´m not sure. Right now I`m testing without an Exchange Server.

Here some results:
1 seconds
0,64 seconds
0,61 seconds
0,54 seconds
0,57 seconds
0,77 seconds

Peter

On 18 Nov., 17:00, "Dmitry Streblechenko" wrote:



How many items does that folder contain? Is Outlook 2000 using online mode
vs cached in the odler versions of Outlook.
1 second sounds very much reasonable to me...


Dmitry Streblechenko (MVP)http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool


"Peter Marchert" wrote in message


...


Hello,


in OL 2000 sql queries are unnormally slow. The following code
sometimes take more then 1 second to finnish (without logon):


Option Explicit


Dim g_objRDOSession As Object


Public Sub Test()


Dim objFolder As Object
Dim sglStart As Single
Dim sglEnd As Single


If g_objRDOSession Is Nothing Then
Set g_objRDOSession = CreateObject("Redemption.RDOSession")
Call g_objRDOSession.Logon("", "", False, False, 0)
End If


Set objFolder = Outlook.Session.GetDefaultFolder(olFolderCalendar)
sglStart = Timer
Debug.Print ExecuteSQL(objFolder)
sglEnd = Timer
Debug.Print "Duration: " & sglEnd - sglStart & " seconds"


End Sub


Public Function ExecuteSQL(ByVal objFolder As Object) As String


Dim objTable As Object
Dim objRecordSet As Object
Dim strSQL As String


Set objTable = CreateObject("Redemption.MAPITable")


objTable.Item = g_objRDOSession.GetFolderFromID(objFolder.EntryID,
_
objFolder.Parent.StoreID).Items


strSQL = "SELECT Subject FROM Folder WHERE (Subject '')"


Set objRecordSet = objTable.ExecSQL(strSQL)


ExecuteSQL = "TEST"


End Function


I tried this code with OL 2000/SP3 on a Win 2000/SP4 machine and an
Exchange Server 2003. I also tried it without Exchange and a local pst
file. Seems to be a little bit faster but not significant. On 2002 and
higher it works fine (tried on XP and Vista machines).


So the question is: Is this a known issu from OL/WIN 2000 or may be
the redemption can cause the problem?


Thanks for any hints.


Peter


--
Infos, workshops & software for
Outlook(R):www.outlook-stuff.com-Zitierten Text ausblenden -


- Zitierten Text anzeigen -- Zitierten Text ausblenden -


- Zitierten Text anzeigen -


  #6  
Old November 19th 07, 06:40 AM posted to microsoft.public.outlook.program_vba
Dmitry Streblechenko
external usenet poster
 
Posts: 2,116
Default MapiTable in OL 2000 slow

What id you take the GetDefaultFolder call from the loop?
Is Outlook 2000 installed in the C/W or IMO mode (see Help | About)?

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool

"Peter Marchert" wrote in message
...
Some more information: If I run the code in a loop:

For lngLoop = 1 To 25
Set objFolder =
Outlook.Session.GetDefaultFolder(olFolderCalendar)
sglStart = Timer
Call ExecuteSQL(objFolder)
sglEnd = Timer
Debug.Print "Duration: " & sglEnd - sglStart & " seconds"
Next lngLoop

It takes for every loop nearly exactly 1 second to finnish.

Peter

On 18 Nov., 18:23, Peter Marchert wrote:
Thanks for your reply, Dmitry.

How many items does that folder contain?


The folder is empty (I`m only testing).

Is Outlook 2000 using online mode?


I´m not sure. Right now I`m testing without an Exchange Server.

Here some results:
1 seconds
0,64 seconds
0,61 seconds
0,54 seconds
0,57 seconds
0,77 seconds

Peter

On 18 Nov., 17:00, "Dmitry Streblechenko" wrote:



How many items does that folder contain? Is Outlook 2000 using online
mode
vs cached in the odler versions of Outlook.
1 second sounds very much reasonable to me...


Dmitry Streblechenko (MVP)http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool


"Peter Marchert" wrote in message


...


Hello,


in OL 2000 sql queries are unnormally slow. The following code
sometimes take more then 1 second to finnish (without logon):


Option Explicit


Dim g_objRDOSession As Object


Public Sub Test()


Dim objFolder As Object
Dim sglStart As Single
Dim sglEnd As Single


If g_objRDOSession Is Nothing Then
Set g_objRDOSession = CreateObject("Redemption.RDOSession")
Call g_objRDOSession.Logon("", "", False, False, 0)
End If


Set objFolder = Outlook.Session.GetDefaultFolder(olFolderCalendar)
sglStart = Timer
Debug.Print ExecuteSQL(objFolder)
sglEnd = Timer
Debug.Print "Duration: " & sglEnd - sglStart & " seconds"


End Sub


Public Function ExecuteSQL(ByVal objFolder As Object) As String


Dim objTable As Object
Dim objRecordSet As Object
Dim strSQL As String


Set objTable = CreateObject("Redemption.MAPITable")


objTable.Item = g_objRDOSession.GetFolderFromID(objFolder.EntryID,
_
objFolder.Parent.StoreID).Items


strSQL = "SELECT Subject FROM Folder WHERE (Subject '')"


Set objRecordSet = objTable.ExecSQL(strSQL)


ExecuteSQL = "TEST"


End Function


I tried this code with OL 2000/SP3 on a Win 2000/SP4 machine and an
Exchange Server 2003. I also tried it without Exchange and a local pst
file. Seems to be a little bit faster but not significant. On 2002 and
higher it works fine (tried on XP and Vista machines).


So the question is: Is this a known issu from OL/WIN 2000 or may be
the redemption can cause the problem?


Thanks for any hints.


Peter


--
Infos, workshops & software for
Outlook(R):www.outlook-stuff.com-Zitierten Text ausblenden -


- Zitierten Text anzeigen -- Zitierten Text ausblenden -


- Zitierten Text anzeigen -



  #7  
Old November 19th 07, 07:12 AM posted to microsoft.public.outlook.program_vba
Peter Marchert
external usenet poster
 
Posts: 116
Default MapiTable in OL 2000 slow

Hmm, sorry I don`t know which id you mean.

OL is installed in the IMO.

Peter

On 19 Nov., 07:40, "Dmitry Streblechenko" wrote:
What id you take the GetDefaultFolder call from the loop?
Is Outlook 2000 installed in the C/W or IMO mode (see Help | About)?

Dmitry Streblechenko (MVP)http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool

"Peter Marchert" wrote in message

...
Some more information: If I run the code in a loop:

For lngLoop = 1 To 25
Set objFolder =
Outlook.Session.GetDefaultFolder(olFolderCalendar)
sglStart = Timer
Call ExecuteSQL(objFolder)
sglEnd = Timer
Debug.Print "Duration: " & sglEnd - sglStart & " seconds"
Next lngLoop

It takes for every loop nearly exactly 1 second to finnish.

Peter

On 18 Nov., 18:23, Peter Marchert wrote:



Thanks for your reply, Dmitry.


How many items does that folder contain?


The folder is empty (I`m only testing).


Is Outlook 2000 using online mode?


I´m not sure. Right now I`m testing without an Exchange Server.


Here some results:
1 seconds
0,64 seconds
0,61 seconds
0,54 seconds
0,57 seconds
0,77 seconds


Peter


On 18 Nov., 17:00, "Dmitry Streblechenko" wrote:


How many items does that folder contain? Is Outlook 2000 using online
mode
vs cached in the odler versions of Outlook.
1 second sounds very much reasonable to me...


Dmitry Streblechenko (MVP)http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool


"Peter Marchert" wrote in message


....


Hello,


in OL 2000 sql queries are unnormally slow. The following code
sometimes take more then 1 second to finnish (without logon):


Option Explicit


Dim g_objRDOSession As Object


Public Sub Test()


Dim objFolder As Object
Dim sglStart As Single
Dim sglEnd As Single


If g_objRDOSession Is Nothing Then
Set g_objRDOSession = CreateObject("Redemption.RDOSession")
Call g_objRDOSession.Logon("", "", False, False, 0)
End If


Set objFolder = Outlook.Session.GetDefaultFolder(olFolderCalendar)
sglStart = Timer
Debug.Print ExecuteSQL(objFolder)
sglEnd = Timer
Debug.Print "Duration: " & sglEnd - sglStart & " seconds"


End Sub


Public Function ExecuteSQL(ByVal objFolder As Object) As String


Dim objTable As Object
Dim objRecordSet As Object
Dim strSQL As String


Set objTable = CreateObject("Redemption.MAPITable")


objTable.Item = g_objRDOSession.GetFolderFromID(objFolder.EntryID,
_
objFolder.Parent.StoreID).Items


strSQL = "SELECT Subject FROM Folder WHERE (Subject '')"


Set objRecordSet = objTable.ExecSQL(strSQL)


ExecuteSQL = "TEST"


End Function


I tried this code with OL 2000/SP3 on a Win 2000/SP4 machine and an
Exchange Server 2003. I also tried it without Exchange and a local pst
file. Seems to be a little bit faster but not significant. On 2002 and
higher it works fine (tried on XP and Vista machines).


So the question is: Is this a known issu from OL/WIN 2000 or may be
the redemption can cause the problem?


Thanks for any hints.


Peter


--
Infos, workshops & software for
Outlook(R):www.outlook-stuff.com-ZitiertenText ausblenden -


- Zitierten Text anzeigen -- Zitierten Text ausblenden -


- Zitierten Text anzeigen -- Zitierten Text ausblenden -


- Zitierten Text anzeigen -


  #8  
Old November 19th 07, 07:19 AM posted to microsoft.public.outlook.program_vba
Peter Marchert
external usenet poster
 
Posts: 116
Default MapiTable in OL 2000 slow

On 19 Nov., 08:12, Peter Marchert wrote:

OL is installed in the IMO.


Ups! It was in CW-Mode with an pop account. Now I changed to IMO and
it works.

But on the other vpc (Exhange C/W) the problem still exists.

Peter

--
Infos, workshops & software for
Outlook(R): www.outlook-stuff.com
  #9  
Old November 19th 07, 07:26 AM posted to microsoft.public.outlook.program_vba
Dmitry Streblechenko
external usenet poster
 
Posts: 2,116
Default MapiTable in OL 2000 slow

I mean "if":
What if you take the GetDefaultFolder call from the loop?

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool

"Peter Marchert" wrote in message
...
Hmm, sorry I don`t know which id you mean.

OL is installed in the IMO.

Peter

On 19 Nov., 07:40, "Dmitry Streblechenko" wrote:
What id you take the GetDefaultFolder call from the loop?
Is Outlook 2000 installed in the C/W or IMO mode (see Help | About)?

Dmitry Streblechenko (MVP)http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool

"Peter Marchert" wrote in message

...
Some more information: If I run the code in a loop:

For lngLoop = 1 To 25
Set objFolder =
Outlook.Session.GetDefaultFolder(olFolderCalendar)
sglStart = Timer
Call ExecuteSQL(objFolder)
sglEnd = Timer
Debug.Print "Duration: " & sglEnd - sglStart & " seconds"
Next lngLoop

It takes for every loop nearly exactly 1 second to finnish.

Peter

On 18 Nov., 18:23, Peter Marchert wrote:



Thanks for your reply, Dmitry.


How many items does that folder contain?


The folder is empty (I`m only testing).


Is Outlook 2000 using online mode?


I´m not sure. Right now I`m testing without an Exchange Server.


Here some results:
1 seconds
0,64 seconds
0,61 seconds
0,54 seconds
0,57 seconds
0,77 seconds


Peter


On 18 Nov., 17:00, "Dmitry Streblechenko" wrote:


How many items does that folder contain? Is Outlook 2000 using online
mode
vs cached in the odler versions of Outlook.
1 second sounds very much reasonable to me...


Dmitry Streblechenko (MVP)http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool


"Peter Marchert" wrote in message


...


Hello,


in OL 2000 sql queries are unnormally slow. The following code
sometimes take more then 1 second to finnish (without logon):


Option Explicit


Dim g_objRDOSession As Object


Public Sub Test()


Dim objFolder As Object
Dim sglStart As Single
Dim sglEnd As Single


If g_objRDOSession Is Nothing Then
Set g_objRDOSession = CreateObject("Redemption.RDOSession")
Call g_objRDOSession.Logon("", "", False, False, 0)
End If


Set objFolder =
Outlook.Session.GetDefaultFolder(olFolderCalendar)
sglStart = Timer
Debug.Print ExecuteSQL(objFolder)
sglEnd = Timer
Debug.Print "Duration: " & sglEnd - sglStart & " seconds"


End Sub


Public Function ExecuteSQL(ByVal objFolder As Object) As String


Dim objTable As Object
Dim objRecordSet As Object
Dim strSQL As String


Set objTable = CreateObject("Redemption.MAPITable")


objTable.Item =
g_objRDOSession.GetFolderFromID(objFolder.EntryID,
_
objFolder.Parent.StoreID).Items


strSQL = "SELECT Subject FROM Folder WHERE (Subject '')"


Set objRecordSet = objTable.ExecSQL(strSQL)


ExecuteSQL = "TEST"


End Function


I tried this code with OL 2000/SP3 on a Win 2000/SP4 machine and an
Exchange Server 2003. I also tried it without Exchange and a local
pst
file. Seems to be a little bit faster but not significant. On 2002
and
higher it works fine (tried on XP and Vista machines).


So the question is: Is this a known issu from OL/WIN 2000 or may be
the redemption can cause the problem?


Thanks for any hints.


Peter


--
Infos, workshops & software for
Outlook(R):www.outlook-stuff.com-ZitiertenText ausblenden -


- Zitierten Text anzeigen -- Zitierten Text ausblenden -


- Zitierten Text anzeigen -- Zitierten Text ausblenden -


- Zitierten Text anzeigen -



  #10  
Old November 19th 07, 07:33 AM posted to microsoft.public.outlook.program_vba
Peter Marchert
external usenet poster
 
Posts: 116
Default MapiTable in OL 2000 slow

On 19 Nov., 08:26, "Dmitry Streblechenko" wrote:

I mean "if":


:-)

This makes no difference.

Peter

What if you take the GetDefaultFolder call from the loop?

Dmitry Streblechenko (MVP)http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool

"Peter Marchert" wrote in message

...
Hmm, sorry I don`t know which id you mean.

OL is installed in the IMO.

Peter

On 19 Nov., 07:40, "Dmitry Streblechenko" wrote:



What id you take the GetDefaultFolder call from the loop?
Is Outlook 2000 installed in the C/W or IMO mode (see Help | About)?


Dmitry Streblechenko (MVP)http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool


"Peter Marchert" wrote in message


...
Some more information: If I run the code in a loop:


For lngLoop = 1 To 25
Set objFolder =
Outlook.Session.GetDefaultFolder(olFolderCalendar)
sglStart = Timer
Call ExecuteSQL(objFolder)
sglEnd = Timer
Debug.Print "Duration: " & sglEnd - sglStart & " seconds"
Next lngLoop


It takes for every loop nearly exactly 1 second to finnish.


Peter


On 18 Nov., 18:23, Peter Marchert wrote:


Thanks for your reply, Dmitry.


How many items does that folder contain?


The folder is empty (I`m only testing).


Is Outlook 2000 using online mode?


I´m not sure. Right now I`m testing without an Exchange Server.


Here some results:
1 seconds
0,64 seconds
0,61 seconds
0,54 seconds
0,57 seconds
0,77 seconds


Peter


On 18 Nov., 17:00, "Dmitry Streblechenko" wrote:


How many items does that folder contain? Is Outlook 2000 using online
mode
vs cached in the odler versions of Outlook.
1 second sounds very much reasonable to me...


Dmitry Streblechenko (MVP)http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool


"Peter Marchert" wrote in message


...


Hello,


in OL 2000 sql queries are unnormally slow. The following code
sometimes take more then 1 second to finnish (without logon):


Option Explicit


Dim g_objRDOSession As Object


Public Sub Test()


Dim objFolder As Object
Dim sglStart As Single
Dim sglEnd As Single


If g_objRDOSession Is Nothing Then
Set g_objRDOSession = CreateObject("Redemption.RDOSession")
Call g_objRDOSession.Logon("", "", False, False, 0)
End If


Set objFolder =
Outlook.Session.GetDefaultFolder(olFolderCalendar)
sglStart = Timer
Debug.Print ExecuteSQL(objFolder)
sglEnd = Timer
Debug.Print "Duration: " & sglEnd - sglStart & " seconds"


End Sub


Public Function ExecuteSQL(ByVal objFolder As Object) As String


Dim objTable As Object
Dim objRecordSet As Object
Dim strSQL As String


Set objTable = CreateObject("Redemption.MAPITable")


objTable.Item =
g_objRDOSession.GetFolderFromID(objFolder.EntryID,
_
objFolder.Parent.StoreID).Items


strSQL = "SELECT Subject FROM Folder WHERE (Subject '')"


Set objRecordSet = objTable.ExecSQL(strSQL)


ExecuteSQL = "TEST"


End Function


I tried this code with OL 2000/SP3 on a Win 2000/SP4 machine and an
Exchange Server 2003. I also tried it without Exchange and a local
pst
file. Seems to be a little bit faster but not significant. On 2002
and
higher it works fine (tried on XP and Vista machines).


So the question is: Is this a known issu from OL/WIN 2000 or may be
the redemption can cause the problem?


Thanks for any hints.


Peter


--
Infos, workshops & software for
Outlook(R):www.outlook-stuff.com-ZitiertenTextausblenden -


- Zitierten Text anzeigen -- Zitierten Text ausblenden -


- Zitierten Text anzeigen -- Zitierten Text ausblenden -


- Zitierten Text anzeigen -- Zitierten Text ausblenden -


- Zitierten Text anzeigen -


 




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
Outlook 2000 slow to load on Hosted Exchange Server [email protected] Outlook - General Queries 0 January 19th 07 08:18 PM
Outlook 2000 rtf html plain very slow Dariusz Kukus Outlook - General Queries 1 January 11th 07 02:57 PM
Outlook 2000 slow response, busy, unresponsive, freeze Phong Outlook - General Queries 0 December 8th 06 12:12 AM
Contacts are slow to open with Outlook 2000 Shane Outlook - Using Forms 0 March 9th 06 03:56 PM
Outlook 2000 slow to attach files [email protected] Outlook - General Queries 0 March 7th 06 06:15 PM


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