DelPhiÏÂÓÃCDO·¢ËÍÓÊÏäʵÀý
Ïà¶ÔÓõÚÈý·½¿Ø¼þ£¬CDO·¢ËÍÓʼþ»¹ÊǺܼò½à·½±ãµÄ
×¢£ºCDONTSΪCDOµÄ×Ó¼¯£¬½öÖ§³ÖWinNT/Win2K£¬WinXPÒÔÉÏÇëÓÃCDO;
µ¥ÔªÒýÓÃComObj;
procedure TForm1.Button1Click(Sender: TObject);
var
VCDOMessage:oleVariant;
begin
vCDOMessage:=CreateOleObject('CDO.Message');
vcdomessage.from:='MR.F'+'<XXXX@163.com>'; //¼ÓºÅÇ°ÃæΪ·¢¼þÈËÏÔʾÃû³Æ£¬¼ÓºÅºóÃæΪ·¢¼þÈËÓÊÏ䣻
vcdomessage.to:='XXXX@qq.com'; //ÊÕÐÅÈ˵ÄÓÊÏä
vcdomessage.Subject:='²âÊÔ';
vcdomessage.TextBody:='·¢Ëͳɹ¦';
vcdomessage.addAttachment('XXXX'); //¸½¼þ£¬ÒýºÅÄÚΪ¸½¼þ·¾¶Ãû
vcdomessage.Configuration.Fields.item('http://schemas.microsoft.com/cdo/configuration/sendusing'):=2;
vcdomessage.Configuration.Fields.item('http://schemas.microsoft.com/cdo/configuration/smtpserver'):='smtp.163.com'; //ÐÞ¸ÄÏàÓ¦·¢ËÍÓÊÏäµÄsmtp
vcdomessage.Configuration.Fields.item('http://schemas.microsoft.com/cdo/configuration/smtpserverport'):=25;
vcdomessage.Configuration.Fields.item('http://schemas.microsoft.com/cdo/configuration/smtpauthenticate'):=1;
vcdomessage.Configuration.Fields.item('http://schemas.microsoft.com/cdo/configuration/sendusername'):='XXXX';//·¢ÐÅÓÊÏäµÄÓû§Ãû
vcdomessage.Configuration.Fields.item('http://schemas.microsoft.com/cdo/configuration/sendpassword'):='XXXX';//·¢ÐÅÓÊÏäµÄÃÜÂë
vcdomessage.Configuration.Fields.update;
VCDOmessage.send;
end;
Ïà¹ØÎĵµ£º
ÔÚWIN32ÖеĴ®¿ÚͨѶ£¨Delphi£©
ÓÉÔÚWIN32²Ù×÷ϵͳÖнûÖ¹Ó¦ÓóÌÐòÏóDOSÖÐÄÇÑùÖ±½Ó·ÃÎʼÆËã»úÓ²¼þ£¬Òò´Ë£¬ÎÞ·¨ÏóÒÔÇ°ÄÇÑù²ÉÓÃÖж϶Áд´®¿Ú¡£µ«ÊÇÔÚWIN32ÖÐÎÒÃÇ¿É·¢²ÉÓÃÁ½ÖÖ·½·¨·ÃÎÊ´®¿Ú£º1¡¢Ê¹ÓÃVBÖеÄMSCOMM´®¿Ú¿Ø¼þ£»2¡¢²ÉÓÃAPIº¯Êý£¬±¾ÎÄÖ÷Òª½éÉܲÉÓÃAPIº¯ÊýʵÏÖ´®¿ÚͨѶ¡£
ÓÉÓÚWM_COMMNOTIFYÏûÏ¢Òѱ»È¡Ïû£¬¹Ê±¾ÎÄ×Ô¶ ......
procedure TForm2.Panel1MouseMove(Sender: TObject; Shift: TShiftState; X,
Y: Integer);
begin
Screen.Cursor := -2;
end;
const
crDefault = TCursor(0);
crNone = TCursor(-1);
crArrow = TCursor(-2);
&n ......
Óйؿª·¢Ï°¹ßµÄһЩÏë·¨£¬ÈçöáÔÚºí£¬²»Í²»¿ì¡£¾¿Æä·¢Ìù¶¯»ú£¬µ±È»²»ÅųýÓÐÆÈ¡²ÎÓë·ÖµÄ¿ÉÄÜ£¬µ«ÁíÒ»·½Ã棬ҲϣÍûÄܸøͬÐУ¨ÄîXing£©ÕßÌṩһЩ
½¨Ò飬»òÕ߲ο¼(Ï£Íû²»ÊÇÎóÈË×ÓµÜ)¡£Í¬Ê±£¬Ò²Ï£Íû¸÷λÄܹ»¾ÍÎÒµÄÕâЩªϰ£¬·¢±íÒ»µã¿´·¨£¬¸ø³öÅúÆÀºÍÖ¸ÕýµÄÒâ¼û¡£Ð»Ð»¡£
Ò»£®½¨Á¢¹¤³ÌĿ¼
&n ......
ÉÏһƪ£¬½éÉÜÁË×é¼þ¿ª·¢µÄÒ»°ã¸ÅÊö£¬ÒÔ¼°×é¼þÀà²ã´Î½á¹¹µÄ¸÷¸öÀàµÄ´óÖÂÐÅÏ¢£¡ÏÖÔھͿªÊ¼Í¨¹ýʵÀý½øÐÐÀ´¼òµ¥µÄ½²ÊöÒ»ÏÂÒ»°ã×é¼þµÄ¿ª·¢¹ý³Ì£¡ÎÒÕâÀïÏȲÉÓÃ×î
»ù±¾µÄ·½Ê½À´´´½¨Ò»¸ö×é¼þ£¡Ò²¾ÍÊÇʹÓÃDelphi×Ô¼ºµÄ×é¼þ¿ª·¢Ïòµ¼À´½¨Á¢Ò»¸öеÄ×é¼þ¡£ÔÚÕâÀÎÒÒÔÀ©³äTEditΪÀý½øÐн²½â¡£
ÄÇôÊ×ÏÈ£¬Òª½éÉܵľÍÊÇ ......
ÔÚÉÏһƪÖУ¬ÎÒÃǼòµ¥µÄʵÏÖÁËÒ»¸ö¶ÔDelphi×ÔÉíµÄTEdit±à¼¿ò¿Ø¼þµÄÒ»¸öÀ©³ä£¡µ«ÊÇÎÒÃDz¢²»ÄÜÏñDelphi×Ô¼ºµÄTEditÒ»Ñù£¬Äܹ»
ÔÚÉè¼Æ״̬ϽøÐÐÉè¼Æ£¬¶øÊǷǵÃÒª×Ô¼ºÊÖ¶¯´´½¨¿Ø¼þ£¬È»ºó²ÅÄÜʹÓá£Õâ¸öËäȻ˵ҲÊÇ×é¼þ£¬µ«ÊÇȴʧȥÁË×é¼þµÄ¿ÉÉè¼ÆµÄ·½±ãÐÔ£¬½ö½ö¿É×÷Ϊһ¸öÀà¿âÀ´Ê¹Óá£
ÏÖÔÚÎÒ¾ÍÀ´½éÉÜһϣ¬ÈçºÎÈÃÕâ¸ö×é¼þ×¢ ......