Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

ShareDevelop3.0½¨Á¢PythonÏîÄ¿ÔËÐÐʱ±¨´í

֮ǰÎҵĵçÄÔÉÏ°²×°ÁËIronPython2.0,ºó°²×°ShareDevelop3.0,²ÉÓÃĬÈÏÉèÖÃ
ÎÒÔÚShareDevelopÖн¨Á¢ÁËÒ»¸öĬÈϵÄPythonµÄ¿ØÖÆ̨»ò´°ÌåÏîÄ¿,ÔËÐÐʱ±¨´íÈçÏÂ:

µ÷ÊÔÆ÷Å׳öÒì³£System.IO.FileNotFoundException:
δÄܼÓÔØÎļþ»ò³ÌÐò¼¯¡°IronPython, Version=1.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35¡±»òËüµÄijһ¸öÒÀÀµÏϵͳÕÒ²»µ½Ö¸¶¨µÄÎļþ¡£


ÏÔÈ»ÊÇ.netÕÒ²»µ½IronPython1.1µÄ³ÌÐò¼¯,ÎÒÔÚ"Ñ¡Ïî"´°¿ÚÖеÄ"¹¤¾ß"Ò»À¸ÖеÄ"Python"Ïî¿´µ½,ΨһµÄÒ»¸ö²ÎÊý"Command"ÒÑÅäÖóÉÁËÖ¸ÏòShareDevelop°²×°Ä¿Â¼ÏµÄ..\PythonBinding\ϵÄipy.exe,¶øÇÒ¸ÃĿ¼ÏÂÒ²ÓÐIronPython.dll(1.1°æ),ÒªÔõôÉèÖòÅÄÜÈÃ.netÕÒµ½IronPython?

ÎÒÒ²ÏëÈÃShareDevelopÄÜʹÓÃIronPython2.0,Ó¦¸ÃÔõôÉèÖÃ?
ÎÒ×Ô¼ºÕÒµ½ÁËÒ»¸ö½â¾ö·½·¨:
°Ñ\PythonBindingĿ¼ÏµÄDllÎļþ¸´ÖƵ½Ð½¨µÄPyÏîÄ¿µÄÔËÐÐĿ¼Ï¾ͿÉÒÔÁË.
²»¹ýÎÒÏëÿ´Î¶¼Òª¸´ÖÆÕâЩDll,ÄÇҲ̫Âé·³ÁË,ÓÐûÓиüºÃµÄ·½·¨.

ÓÃSharpDevelop3.1
ÎÒÖ±½Ó´ÓÁíÈ˵ĵçÄÔÉÏ¿½ÁËÒ»·Ý¹ýÀ´(c:\program\sharpdevelop)£¬¾Í¿ÉÒÔÓÃÁË¡£
ʹÓÃsys.version²é¿´£¬·¢ÏÖ°æ±¾ÊÇ2.5.0

ÎÒÓõÄÒ²ÊÇSharpDevelop3.1µÄ£¬¡±BackendBindings\PythonBinding\¡°ÏµÄIronPython.dll°æ±¾Îª2.0µÄ,Ò²ÊÇ¿ÉÒÔÔËÐеģ¬ÎÒÓÃËüд¹ýÒ»¸öÎļþ¼àÊÓÆ÷£¬Ò»Ö±×Ô¼ºÓÃ×ÅÄØ,ºÇºÇ£¡²»¹ýÓÃËüдµÄÍÐÅ̳ÌÐòºÃÏñ²»Èçvs2008дµÄºÃʹ£¬ÄãpythonÓÐÉîÈëµÄÓ¦ÓÃÂð£¿ÎÒÒ»Ö±²»ÖªµÀÕ¦ÄÜÔÚʵ¼ùÖÐÓ¦ÓÃËü,Óо­Ñé·ÖÏíÏ°ɣ¬ºÇºÇ

ÒýÓÃ
ÎÒÓõÄÒ²ÊÇSharpDevelop3.1µÄ£¬¡±BackendBindings\PythonBinding\¡°ÏµÄIronPython.dll°æ±¾Îª2.0µÄ,Ò²


Ïà¹ØÎÊ´ð£º

ÇóÖú£ºpython¶ÁÈ¡mp3µÄid3±êÇ©ÐÅÏ¢ÎÊÌâ

ÎÒµÄmp3±êÇ©ÐÅÏ¢ÊÇͨ¹ýTag&Rename Èí¼þÀ´Ð޸ĵÄ
Ð޸ĵÄÐÅÏ¢ÈçÏÂ
Album Title ISRC
77 66 99

---python¶ÁÈ¡mp3µÄid3µÄ´úÂë----

from mutagen.mp3 import MP3
import mutagen.id3
......

µÚÒ»´ÎÓÃPythonд³ÌÐò£¬Ê¹ÓÃfindº¯ÊýÓöµ½Ò»¸öÎÊÌâ

//ÏÂÃæµÄ´úÂëÔËÐÐÕý³£

tomstrs=re.findall(......)
mtxx=''
for tomstr in tomstrs:
  tomstr=tomstr.strip()
  if  tomstr:
      mtxx += tomstr ......

PythonÖÐÎÄ´¦Àí£¬Íê³É¹¦ÄܵÄʵÓû¯

±¾ÎÄÕª×Ô¡¶¿É°®µÄPython¡·¡°¹âÅ̹ÊÊ¡±CDay-1 ʵÓû¯ÖÐÎÄ¡£
[img]http://t.douban.com/mpic/s3901817.jpg[/img]
CDay-1 ʵÓû¯ÖÐÎÄÖÐÎÄ´¦Àí£¬Íê³É¹¦ÄܵÄʵÓû¯
ÄãÅöµ½99%µÄÎÊÌ⣬ÆäËûÈË֮ǰÒѾ­Óöµ½¹ýÁË£¬Ë ......

WindowsÏÂÓÃPythonÄã»á¼¸ÖÖcopyÎļþµÄ·½·¨£¿

1. os.system
Python code:
import os
import tempfile
filename1 = tempfile.mktemp (".txt")
open (filename1, "w").close ()
filename2 = filename1 + ".copy"
print fi ......

ÐÂÐͶñÒâ³ÌÐòpythonÔì——µÁÇÔÊÖ»úÕË»§

http://www.cioage.com/art/200906/78173.htm
¾ÝϤ£¬¿¨°Í˹»ùʵÑéÊÒÉÏÖܼì²âµ½Ò»ÖÖ¹¥»÷Èû°àϵͳµÄжñÒâ³ÌÐò£¬¸Ã³ÌÐòµÄ¹¥»÷Ä¿±êÊÇÒ»¼ÒÓ¡¶ÈÄáÎ÷ÑÇÒƶ¯µç»°ÔËÓªÉ̵ÄÓû§¡£¸ÃľÂíÓÉÒ»ÖֽРPythonµÄ½Å±¾ÓïÑÔ±àд£¬Ëü» ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ