Solved

Launch default email app in vb6

Posted on 2004-08-31
3
405 Views
Last Modified: 2008-01-09
Need a clean, easy way to do this.
0
Comment
Question by:robbperk
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 1

Expert Comment

by:aspirine
ID: 11947081
First declare the shellexecute api like this:

Private Declare Function ShellExecute Lib _
     "shell32.dll" Alias "ShellExecuteA" _
     (ByVal hWnd As Long, ByVal lpOperation _
     As String, ByVal lpFile As String, ByVal _
     lpParameters As String, ByVal lpDirectory _
     As String, ByVal nShowCmd As Long) As Long

Then in your code, insert something like:
ShellExecute 0&, vbNullString, "mailto:your@email.com", vbNullString, vbNullString, SW_SHOWNORMAL

I hope this is what you wanted
0
 

Author Comment

by:robbperk
ID: 11983124
Received error on SW-SHOWNORMAL
0
 
LVL 1

Accepted Solution

by:
aspirine earned 50 total points
ID: 11985579
oops, sorry, forgot about that constant, add this to your code:

Private Const SW_SHOWNORMAL = 1
0

Featured Post

What Is Transaction Monitoring and who needs it?

Synthetic Transaction Monitoring that you need for the day to day, which ensures your business website keeps running optimally, and that there is no downtime to impact your customer experience.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Entering a date in Microsoft Access can be tricky. A typo can cause month and day to be shuffled, entering the day only causes an error, as does entering, say, day 31 in June. This article shows how an inputmask supported by code can help the user a…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
Introduction to Processes

696 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question