超链接的简单问题(50分)

  • 主题发起人 tianzhegs
  • 开始时间
T

tianzhegs

Unregistered / Unconfirmed
GUEST, unregistred user!
我想在edit中写邮箱名,然后再使用api函数
ShellExecute(handle,nil,'mailto:edit1.text',nil, nil, SW_SHOWNORMAL);
把outlook调出来,发邮件,但我不知道如何使mailto后面的邮箱名是edit中输入的文字,
请各位帮忙,谢谢了
 
刚开始学吧[:)]

var str: string;

str := 'mailto:'+edit1.text;
ShellExecute(handle,nil,pchar(str),nil, nil, SW_SHOWNORMAL);
 
再在uses中请加入:shellapi就OK了!
 
ShellExecute(Handle, 'Open', 'mailto:BugReport@itfirst.net?subject=错误报告', nil, nil, sw_normal);

这样写就可以了!

别忘了 引用这个单元 ShellApi !
 
ShellExecute(Handle, 'Open', 'mailto:BugReport@itfirst.net?subject=错误报告', nil, nil, sw_normal);

BugReport@itfirst.net这就可以是从Edit中获得的邮件地址!

这样写就可以了!

别忘了 引用这个单元 ShellApi !
 
多人接受答案了。
 
顶部