Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB
ÈÈÃűêÇ©£º c c# c++ asp asp.net linux php jsp java vb Python Ruby mysql sql access Sqlite sqlserver delphi javascript Oracle ajax wap mssql html css flash flex dreamweaver xml
 ×îÐÂÎÄÕ : delphi

ÌÔ±¦Æ½Ì¨¿ª·¢ delphi ʾÀý

ÌÔ±¦¿ª·Åƽ̨µÄ¿ª·¢Àý×Ó´ó¶à¶¼ÊÇc#£¬php£¬javaµÈ£¬È±ÉÙPascalµÄÀý×Ó¡£
ÏÖÓÃdelphiдÁËÒ»¸öʾÀý£¬
¹Ø¼üµãÊÇÇ©ÃûµÄÉú³É£¬Ç©ÃûÐè°´key×Öĸ˳ÐòÅÅÐò£¬²¢È¥µôµÈÓںźóÊ×βÏàÁ¬¡£
¹Ø¼ü´úÂ룺
 memstr:= TMemoryStream.Create;
 //ÓÃÊÚȨÂë»ñÈ¡ session
  IdHTTP1.Get('http://container.api.tbsandbox.com/container?authcode='+memo1.Text,memstr);
  setlength(ss,memstr.Size);
  memstr.Position:= 0;
  memstr.Read(ss[1],memstr.Size);
   ss:= Utf8ToAnsi(ss);
  //ÇзÖsession top_session=282730527fc47c5e27838f5dd8aeb098afefd&top_sign=LiTSTYs/DQHpRAGA4OPEZA==
  ss:= copy(ss,pos('top_session=',ss)+12,255);
  ss:= copy(ss,1,pos('&',ss)-1);
  memo1.Lines.Add(ss);
  //ÖÆ×÷Ç©Ãû£¬ÏÂÁдúÂëÓÐÈßÓàµÄµ¥ÒýºÅ£¬Ö÷ÒªÊÇΪÁËÏÔʾÂß¼­¹Øϵ¡£
  ss2:=secrect_key+'app_key'+app_Key +
       'fields'+'tid,seller_nick,buyer_nick,status,orders.title,orders.price,orders.num'+
        'format ......

DelphiÎļþ²Ù×÷³£Óú¯Êý

====================================================
Delphi²Ù×÷ÎļþµÄÒ»°ã²½Ö裺
1£©¹ØÁªÎļþ£º
 AssignFile(var F; FileName :string)£»
2£©³õʼ»¯Îļþ£º
 Append(var F :Text);   
 //ֻд£¬ÓÚÎļþ×îºó×·¼ÓÊý¾Ý
 Reset(var F [; RecSize :Word]);      
 //Ö»¶Á£¬Îļþ±ØÐë´æÔÚ£¬ÎļþÖ¸ÕëÖÃÓÚ¿ªÍ·
 //µÚ¶þ²ÎÊýÖ¸¶¨Ö¸ÕëÒƶ¯µÄ´óС£¬¶ÔÓÚÎÞÀàÐÍÎļþÓÐЧ
 //¶ÔÓÚÀàÐÍÎļþ£¬Ôò°´¾ßÌåÀàÐ͵ĴóС£¬¶øÎı¾ÎļþĬÈÏ128×Ö½Ú
 Rewrite(var F :File [; Recsize :Word]);
 //¸²¸Çֻд£¬ÈôÎļþÒÑ´æÔÚ£¬Ôòɾ֮Öؽ¨¿ÕÎļþд
3£©¶ÁдÎļþ£º
 Eof(var F):Boolean; //End of File? ÎļþÖ¸ÕëÊÇ·ñ´¦ÓÚÎļþ½áβ
 Eoln[(var F :Text)]:Boolean; //End of line?
 Seek(var F; N :Longint); //¶ÔÓÚÎı¾ÎļþÎÞЧ
 //Òƶ¯ÎļþÖ¸ÕëN¸öµ¥Î»£¬NΪÕýÔòÏòÇ°ÒÆ£¬NΪ¸ºÔòÏòºóÒÆ
 SeekEof[(var F :Text)]:Boolean;
 //ͬEof£¬Çø±ðÔÚÓÚ±¾º¯ÊýºöÂÔ¿Õ°×·û
 
 SeekEoln[(var F :Text)]:Boolean;
 //ͬEoln£¬Çø±ðÔÚÓÚ±¾º¯Êýºö ......

DelphiÖ÷´Ó±íÀý×Ó

ÔÚsql server µÄnorthwide Öн¨Á¢Ö÷±í
create table sell_h( sell_id char(10),cust_name char(10) Primary key(sell_id) )
go
create table sell_h( sell_id char(10),inv char(10) ,amt float,qty float Primary key(sell_id,inv) )
Ê×ÏÈ,ҪעÒâÒÔÏÂÉèÖÃ
1.ҪעÒⱨ´Ó±íqrydetailÉèÖÃ,Åú±£´æ¿ªÊ½. ¼´.locktype= batchoptimistic ,cursortype=keyset,cursorlocation
=cluseclient
2.
procedure TForm1.FormCreate(Sender: TObject);
begin
qrymain.Close;
qrydetail.Close;
qrymain.SQL.Add(' select *   from   sell_h')   ;
qrydetail.SQL.add('select * from sell_b where sell_id = :sell_id')  ;
qrymain.Open;
qrydetail.Open;
end;
3.
procedure TForm1.qrymainAfterScroll(DataSet: TDataSet);
begin
qrydetail.Close;
qrydetail.Parameters.ParamByName('sell_ID').Value := qrymain.fieldbyname('sell_id').value;
qrydetail.Open;
end;
ÒÔÉϾÍÊÇÖ÷ÒªµÄÉèÖÃ,»¹ÓÐ×¢ÒâÖ÷´Ó±íµÄ±£´æÎÊÌâ:
Ö÷±í²»ÒªÓÃÅú´¦Àí£¬Ö±½Ó±£´æ,°ÑltBatchOptimisticÈ¥µô
Ã÷ϸ±íÓÃÅú´¦Àí¡£ 
±£´æʱÏȱ£´æÃ÷ϸ±í£¬ÔÙ±£´æÖ ......

delphiÈý²ã¼Ü¹¹

Èý²ã¼Ü¹¹Ö¸µÄÊǽçÃ棬ҵÎñÂß¼­ºÍÊý¾Ý´æ´¢·ÖÀë,²»ÊÇÖ¸ÎïÀíÉÏÊÇ·ñ·ÖÀë¡£
ÕâÑù×öµÄºÃ´¦ÊDzã´Î·ÖÃ÷£¬Î¬»¤ºÃ×ö£¬ÏµÍ³×ÊÔ´Ò²ºÃ·Ö²¼Ê½´¦Àí¡£
Êý¾Ý¿â²ãÄľͲ»ËµÁË£¬ÓÃMSSQL¡¢OrcaleËæÄãÁË£¬¾ÍÊÇÊý¾Ý·þÎñ²ã
ÒµÎñÂß¼­µÄ»°Òª·ÖÎöÇå³þ£¬¾ÍÊÇÖмä²ã
½çÃ棬Ҳ½Ð¿Í»§¶Ë¡£ÕâÀï¾ÍÊǵõ½Êý¾ÝºÍÏÔʾÊý¾ÝµÄ²¿·ÖÁË£¬²»×öÆäËü´¦Àí¡£µ«ÊÇÊý¾ÝÓÐЧÐÔ·ÖÎö×îºÃ·ÅÔÚ½çÃæ²ã£¬ÒÔ³ä·ÖÀûÓÿͻ§¶ËµÄÐÔÄÜ¡£²»È»µÄ»°ÒµÎñÂß¼­²ãµÄ¸ºµ£Ì«´óÒ²»áÐγÉÆ¿¾¢¡£
Êý¾Ý¿âµÄ½¨Á¢²»ËµÁË¡£
Èý²ãÌåϵµÄ½¨Á¢
Ò» Êý¾Ý¿â²ãµÄ½¨Á¢
      ʹÓÃsqlserver»òorale½¨Á¢Êý¾Ý¿â¡£
¶þ Öмä²ãµÄ½¨Á¢
      Ò»°ã½«Öмä²ã·ÖΪ¶þ¸ö²¿·Ö£¬Êý¾Ý²¿·ÖºÍÂß¼­²¿·Ö¡£
     Êý¾Ý²¿·Ö¾ÍÊÇʹÓÃԭʼµÄ²éѯ,Ò»¸öadoÁ¬½Ó£¬¶à¸ö³É¶Ô³öÏÖµÄadqºÍdsp¡£adoÁ¬½Ó×îºóѡʹÓÃÎļþÁ¬½Ó£¬ÒÔ±ãÒÔºó¿ÉÒÔÔÚ¿Í»§¶Ë×ÔÓɾö¶¨Á¬½ÓÄĸöÊý¾Ý¿â¶ø²»ÐèÒª¸Ä³ÌÐò¡£
Âß¼­²¿·Ö¸ú¿Í»§¶ËÒ»Ñù£¬Ê¹ÓÃDComÀ´Á¬½Óµ½Êý¾Ý²¿·Ö£¬È»ºóʹÓÃcdsÁ¬½Óµ½DCOM²¢Ö¸Ã÷Êý¾ÝÌṩÆ÷dsp.È»ºóÔÙÔö¼ÓÏàÓ¦µÄº¯ÊýÀ´´¦ÀíÊý¾Ý¡£ÊÂÎñÒ»°ãÈ¡×Ô¶¯Î¬»¤µÄ£¬ÕâÑùº¯Êý¿ªÊ¼ÊÂÎñ×Ô¶¯¿ªÊ¼£¬ÎÒÃÇÖ»ÐèҪά»¤ÊÂÎñ»Ø¹ösetAbout,ºÍÊÂÎñÍê³Ésetc ......

ÔÚDelphiºÍVCÖд´½¨ºÍµ÷Óö¯Ì¬Á´½Ó¿â

´ó¼ÒÔÚÈí¼þ¿ª·¢Ê±¾­³£»áÓöµ½ÕâÑùµÄÇé¿ö£¬ÔÚ²»Í¬µÄ¿ª·¢»·¾³ÖÐΪʵÏÖһЩ¹¦ÄÜÏàͬµÄ¹ý³Ì£¬ÓÉÓÚ¿ª·¢ËùʹÓõÄÉè¼ÆÓïÑÔ²»Í¬£¬Òò¶ø²»µÃ²»±àдÐí¶àÀàËƵĴúÂ룬ÉõÖÁÓÐʱҪÔÚͬһ¸ö¿ª·¢»·¾³²»Í¬ÏîÄ¿ÖÐÖØд´úÂ룬Õâ¾ÍÔì³ÉÁ˺ܴóµÄ×ÊÔ´ÀË·Ñ¡£¶¯Ì¬Á´½Ó¿âÄܽϺõĽâ¾öÕâ¸öÎÊÌ⣬Öظ´ÀûÓôúÂ뽫´ó´óÌá¸ßÁË¿ª·¢Ð§ÂÊ¡£Ò»°ã£¬Óû§ÔÚÓ¦ÓóÌÐòÖлùÓÚÈçÏÂÒªÇó´´½¨ºÍʹÓÃDLL£º
¡¡¡¡1. ÔÚ²»Í¬µÄ¿ÉÖ´ÐÐÎļþÖ®¼ä¹²ÏíµÄ³ÌÐò£»
¡¡¡¡2. ÔÚÉè¼ÆÓ¦ÓóÌÐòʱ£¬½«Æä²ð·Ö³É¸÷¸öÏ໥¶ÀÁ¢¹¦Äܲ¿¼þ£¬ÎªÒÔºóÕâЩ¹¦Äܲ¿¼þ¸÷×ÔÉý¼¶Ìṩ·½±ãµÄ;¾¶¡£
¡¡¡¡¶¯Ì¬Á´½Ó¿â½«¹²Ïí³ÌÐò»ò¹¦Äܲ¿¼þ×ö³É¿âÖеĺ¯Êý£¬ÐγÉDLLÎļþ£¬ÆäËüÓ¦ÓóÌÐòͨ¹ýʹÓÃDLLµ÷ÓÃÕâЩº¯Êý¡£ÔÚÕâÀォ¶ÔDelphiºÍVCÖд´½¨ºÍʹÓö¯Ì¬Á´½Ó¿âµÄ·½·¨×öÒ»½éÉÜ¡£DelphiºÍVC¶¨ÒåµÄ¶¯Ì¬Á´½Ó¿â¾ù¿ÉÔÚÁ½ÕߵĿª·¢»·¾³ÖÐʹÓá£
¡¡¡¡Ò»¡¢ ÓÃDelphi´´½¨DLL
¡¡¡¡DelphiµÄDLL´´½¨²¢²»¸´ÔÓ£¬ÏÂÃæÏò´ó¼Ò½éÉÜDelphiµÄDLL´´½¨·½·¨¡£
¡¡¡¡£¨1£©Ê×ÏÈ´´½¨Ò»¸öеÄDLLÏîÄ¿(NewProject)project1£¬ÎļþÍ·²¿Îª£º
library Project1;
¡¡¡¡£¨2£©USESÓï¾äºóÃæ¼ÓÈëExPortsÓï¾ä£¬Ö¸Ã÷µ÷ÓÃDLLµÄº¯ÊýÃû£¬ÐÎʽΪ£º
exports
checkpwd name 'checkpwd';
¡¡¡¡£¨3£©ÔÚDLLµÄPasÎļþÖÐT ......

javascriptÖе÷ÓÃdelphiº¯Êý


ÒÔÏÂÊÇtest.htmÒ³µÄÄÚÈÝ
Ê×Ïȶ¨ÒåÒ»¸ö²å¼þ¶ÔÏó
 
<object id="Mapupload" name="Mapupload" width="0" height="0" classid="clsid:045FA9B9-B373-4D4C-AE76-128A19A4B6AE">
</object>
<script type="text/javascript">
//´Ëº¯Êý´ò¿ªactivexform´°Ì岢ΪactiveformµÄÊôÐÔ¸³Öµ
function loadUploader(){
 if(window.ActiveXObject){
  try{
  document.getElementById("Mapupload").picname='20060531';  //Ϊ¶ÔÏó¸³Öµ
  document.getElementById("Mapupload").open();   //µ÷ÓöÔÏóµÄopen·½·¨
  }
  catch(e){
  }
 }
 else{
 }
}
</script>
<TEXTAREA style="WIDTH: 400px; HEIGHT: 226px" name="" id='Content' rows=20 cols=40></TEXTAREA>
<button name="start" type="button" onclick="loadUploader();"></button>
<!-- scriptº¯Êý -->
<script Languag ......

javascriptÖе÷ÓÃdelphiº¯Êý


ÒÔÏÂÊÇtest.htmÒ³µÄÄÚÈÝ
Ê×Ïȶ¨ÒåÒ»¸ö²å¼þ¶ÔÏó
 
<object id="Mapupload" name="Mapupload" width="0" height="0" classid="clsid:045FA9B9-B373-4D4C-AE76-128A19A4B6AE">
</object>
<script type="text/javascript">
//´Ëº¯Êý´ò¿ªactivexform´°Ì岢ΪactiveformµÄÊôÐÔ¸³Öµ
function loadUploader(){
 if(window.ActiveXObject){
  try{
  document.getElementById("Mapupload").picname='20060531';  //Ϊ¶ÔÏó¸³Öµ
  document.getElementById("Mapupload").open();   //µ÷ÓöÔÏóµÄopen·½·¨
  }
  catch(e){
  }
 }
 else{
 }
}
</script>
<TEXTAREA style="WIDTH: 400px; HEIGHT: 226px" name="" id='Content' rows=20 cols=40></TEXTAREA>
<button name="start" type="button" onclick="loadUploader();"></button>
<!-- scriptº¯Êý -->
<script Languag ......
×ܼǼÊý:644; ×ÜÒ³Êý:108; ÿҳ6 Ìõ; Ê×Ò³ ÉÏÒ»Ò³ [3] [4] [5] [6] 7 [8] [9] [10] [11] [12]  ÏÂÒ»Ò³ βҳ
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ