Consulting

Results 1 to 6 of 6

Thread: Sleeper: Opening MS Outlook outside of remote desktop via VBA

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    VBAX Newbie
    Joined
    May 2023
    Posts
    3
    Location

    Sleeper: Opening MS Outlook outside of remote desktop via VBA

    Hi All
    *Yes I have posted on another forum but with no resolution hence why I am trying this forum
    https://www.accessforums.net/showthread.php?t=88083

    We have recently moved our Microsoft Access Database to a RD Web Access - RemoteApp and Desktop Connection, all VBA / Macros all work as it should apart from one issue.

    Prior to moving to RD Web we had VBA code that when a button is pressed by the user it opens op MS Outlook fills out an Email template automatically and all the user has to to is click send.

    Since moving to RD Web using VBA to open Outlook no longer works as security does not allow outlook to open within the RD Web. I am hoping there is a way that I can force MS Outlook to open outside of the Remote window and complete the task instead and create an Email. anyone have any ideas how we can do this as I am not afraid to so it this is well above my knowledge of VBA?


    Unfortunately the security levels do not allow outlook to be opened within the remote access so trying to force it open outside of this remote window,

    Below is my current code that worked on the standalone system, but since moving to the RD Web I currently get a run-time error of '429', ActiveX Component cant create object.



     Dim oWo  As Object 'Outlook.Application
        Dim oDoc1 As Object 'Word.Document
        'Set oWd = New Word.Application
        Set myOlApp = CreateObject("Outlook.Application")
        Set myitem = myOlApp.CreateItemFromTemplate(CurrentProject.Path & "\TemplateFiles\PasswordEmail.oft")
     
        myitem.Subject = UCase("HR RECORDS - " & "[" & [Forms]![FRM_TBLALL_FullDetails].[Form]![LblHRRef])
     
        myitem.To = UCase([Forms]![FRM_TBLALL_FullDetails]![SFRM_TBLALL_STAFFDetails]![SSFRM_TBLALL_INTERVDetails].[Form]![CmbStaffNo].Column(0))
     
        myitem.display
     
        myitem.body = "Hello" & Chr(13) & Chr(10) & "You will receive an encrypted report and all relevant files required." & Chr(13) & Chr(10) & _
     
        "Your encryption password is:" & [Forms]![FRM_TBLALL_FullDetails]![SFRM_TBLALL_STAFFDetails]![SSFRM_TBLALL_INTERVDetails].[Form]![Password]
      
    End Function
    Thank you in Advance!
    Stu
    Last edited by Stu_c; 05-11-2023 at 02:39 AM.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •