• Access and Thunderbird (All)

    Author
    Topic
    #432584

    Hi

    Does Thunderbird have a macro/VBA type language that would allow it to be controlled from MS Access? I.e. is it possible to generate multiple emails from MS Access through Thunderbird in the same way as can be done through Outlook?

    David

    Viewing 0 reply threads
    Author
    Replies
    • #1015208

      Yes

      I think you could use something like this:

      Public Function fSendThunderbird(strTo As String, strSubject As String, strBody As String)

      ‘This function can be used to send an e-mail from Mozilla Thunderbird.
      ‘The syntax for calling Thunderbird from a command line (DOS prompt) is:

      ‘thunderbird -compose “mailto:somebody@somewhere?cc=address@provider&subject=hi&body=something”

      Dim strCommand As String

      strCommand = “C:Program FilesMozilla Thunderbirdthunderbird”

      strCommand = strCommand & ” -compose ” & Chr$(34) & “mailto:” & strTo & “?”
      strCommand = strCommand & “subject=” & Chr$(34) & strSubject & Chr$(34) & “&”
      strCommand = strCommand & “body=” & Chr$(34) & strBody & Chr$(34)

      Call Shell(strCommand, vbNormalFocus)

      End Function

      I won’t claim this for my own but can be found here: http://forums.mozillazine.org/viewtopic.php?t=399230&%5B/url%5D

      • #1015213

        For simple e-mails, you can use DoCmd.SendObject in Access VBA, e.g.

        DoCmd.SendObject To:=”you@somewhere.com”, Subject:=”Test”, Message:=”Hello World”, EditMessage:=True

        This will use the user’s default e-mail application, there is no need to specify the name and path of the application.

        Using Automation to control Outlook from Access offers more features, such as adding attachments, setting the mail’s priority and specifying HTML for the body of the e-mail. I think David wanted to know whether something similar is possible for Thunderbird.

        • #1015222

          OK

          Read the message differently but see your point.

          • #1015231

            Thanks guys. I think the answer is stick with Outlook for anything other than very simple emails..

            I had hoped to get away with using Outlook for work and Thunderbird for the 2 associations I maintain databases for (using 2 Thunderbird profiles). It looks like the only way forward is to create 3 Windows/Exchange profiles with Outlook in each. Messy having to log out and login to change.

            David

            • #1015393

              Neither Firefox nor THunderbird support using VB/VBA directly.

              As was pointed out elsewhere, you can shell commands, but that’s not really satisfactory.

            • #1015396

              > As pointed out elsewhere

              Where? shrug

              It would be nice to cross reference please

            • #1015446

              in this thread, posted by you.

            • #1015502

              So what do you suggest then? It is quick and easy to say something is not good enough but why don’t you seek a constructive alternative before running an idea down.

    Viewing 0 reply threads
    Reply To: Access and Thunderbird (All)

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: