View Single Post
  #5  
Old March 4th 10, 07:59 AM posted to microsoft.public.outlook.program_vba
Reinfried
external usenet poster
 
Posts: 4
Default Programmatic Access Security Pop up with Wordeditor

We have set the Programmatic Access Security to "Always warn me about
suspicious activity" because we wor with TerminalServer wit Windows Server
2003 and i hope You know that to detect the status of the antivirus software
on client computers, Outlook 2007 depends on the WSC. Currently, antivirus
products that are compatible with Windows XP SP2 and Windows Vista register
status information with the WSC. Outlook first checks for the current status
of antivirus software by querying the WSC. On computers running Microsoft
Windows Server 2003, because the WSC is not available, Outlook is unable to
detect the status of antivirus software and therefore does not disable
security warnings.

And now oncemore to my Question:

Without WordEditor the code runs without security pop up:

Set appOutLook = CreateObject("Outlook.Application")
appOutLook.Session.Logon
Set taskOutLook = appOutLook.CreateItem(olTaskItem)
With taskOutLook
.Subject = "Test hyperlink"
.Importance = olImportanceNormal
.DueDate = "01.03.2010"
.StartDate = "01.03.2010"
.ReminderTime = "01.03.2010" & " " & "08:00"
.ReminderSet = True
.Body = "Das ist der Link zum " & "http://www.google.at" & " Viel
Spass!"
.Importance = olImportanceHigh
.Save
End With

And with WordEditor the code runs with security pop up:

Set appOutLook = CreateObject("Outlook.Application")
appOutLook.Session.Logon
Set taskOutLook = appOutLook.CreateItem(olTaskItem)
With taskOutLook
.Subject = "Test hyperlink"
.Importance = olImportanceNormal
'Only for test fix Date
.DueDate = "01.03.2010"
.StartDate = "01.03.2010"
.ReminderTime = "01.03.2010" & " " & "08:00"
'
.ReminderSet = True
Set objInsp = .GetInspector
' ?????????
Set objDoc = objInsp.WordEditor 'Programmatic Access Security
Check
'
Set objSel = objDoc.Windows(1).Selection
objDoc.Hyperlinks.Add objSel.Range, strLink, "", "", strLinkText,
""
Set objSel = objDoc.Windows(1).Selection
'Text before Hyperlink
With objSel
.Collapse wdCollapseStart
.InsertBefore "Das ist der Link zum "
End With
'Text after Hyperlink
Set objSel = objDoc.Windows(1).Selection
With objSel
.Collapse wdCollapseStart
.MoveEnd WdUnits.wdStory, 1
.Select
.InsertAfter " Viel Spass! "
End With
.Importance = olImportanceHigh
.Save
End With

Reinfried





"Ken Slovak - [MVP - Outlook]" wrote:

What does that tab show for antivirus status? If it's valid then the setting
should be warn me about suspicious activity when my av software is inactive,
etc.

Is this in a corporate setting perhaps where the admins have locked things
down? Or is there no valid antivirus software? If your setting is changeable
then you need to set it to a different setting, which could be dangerous.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm


"Reinfried" wrote in message
...


reinfriedThank's for the Answer.
The Code is running in Word 2007.
In Outlook the security is set to "Always warn me about suspicious
activity"


.

Ads