Re: [IronPython] word Automation
Hi, Yes it should work, but I don't have the correct assembly to be able to test it. You should remember that you should just translate the code from VB to IronPython. IronPython is a dynamically bound language, so you don't have to do things like declaring the local variable oWord (i.e. 'oWord = wordApp.ApplicationClass') In python an variable object is bound to a type upon assignment to an Rvalue object If you tell me how to get the assembly having Microsoft.Office.Interop.Word I will try it out for you and post back the code snippet. AnthonyOn 5/9/05, kbond [EMAIL PROTECTED] wrote: Hello,First congratulation of all, thank you for the tremendous work that youhave already done.I am looking forward the day where I will be able to translate all my MSofficeautomation in pythonscripts. Am I correct I say that iron python will allow it?So today I try to give it a try but unfortunatly withou success till now.I am trying to translate this simple vb.net module to iron python, is there someone reading this list that can help me?the VBImports word = Microsoft.Office.Interop.wordModule Module1Sub Main()Dim oWord As Word.ApplicationClass'Start Word and open the document. oWord = CreateObject(Word.Application)oWord.Visible = TrueoWord.Documents.Open(C:\tmp\Doc1.doc)'Run the macros.'oWord.Run(DoKbTest) 'oWord.Run(DoKbTestWithParameter, Hello from VB .NET Client)'Quit Word.oWord.Quit()System.Runtime.InteropServices.Marshal.ReleaseComObject(oWord) oWord = NothingEnd SubEnd ModuleIron Pythonimport syssys.LoadAssemblyByName(Microsoft.Office.Interop.Word)import Microsoft.Office.Interop.Word as wordApp oWord = wordApp.ApplicationClassoWord = CreateObject(wordApp.Application)oWord.Visible = TrueoWord.Documents.Open(C:\tmp\Doc1.doc)oWord.Quit()System.Runtime.InteropServices.Marshal.ReleaseComObject (oWord)oWord = Nothingthank you___users-ironpython.com mailing list users-ironpython.com@lists.ironpython.comhttp://lists.ironpython.com/listinfo.cgi/users-ironpython.com___ users-ironpython.com mailing list users-ironpython.com@lists.ironpython.com http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
Re: [IronPython] word Automation
That should have read you should not just translate the... AnthonyOn 5/9/05, Anthony Tarlano [EMAIL PROTECTED] wrote: Hi, Yes it should work, but I don't have the correct assembly to be able to test it. You should remember that you should just translate the code from VB to IronPython. IronPython is a dynamically bound language, so you don't have to do things like declaring the local variable oWord (i.e. 'oWord = wordApp.ApplicationClass') In python an variable object is bound to a type upon assignment to an Rvalue object If you tell me how to get the assembly having Microsoft.Office.Interop.Word I will try it out for you and post back the code snippet. AnthonyOn 5/9/05, kbond [EMAIL PROTECTED] wrote: Hello,First congratulation of all, thank you for the tremendous work that youhave already done.I am looking forward the day where I will be able to translate all my MSofficeautomation in pythonscripts. Am I correct I say that iron python will allow it?So today I try to give it a try but unfortunatly withou success till now.I am trying to translate this simple vb.net module to iron python, is there someone reading this list that can help me?the VBImports word = Microsoft.Office.Interop.wordModule Module1Sub Main()Dim oWord As Word.ApplicationClass'Start Word and open the document. oWord = CreateObject(Word.Application)oWord.Visible = TrueoWord.Documents.Open(C:\tmp\Doc1.doc)'Run the macros.'oWord.Run(DoKbTest) 'oWord.Run(DoKbTestWithParameter, Hello from VB .NET Client)'Quit Word.oWord.Quit()System.Runtime.InteropServices.Marshal.ReleaseComObject(oWord) oWord = NothingEnd SubEnd ModuleIron Pythonimport syssys.LoadAssemblyByName(Microsoft.Office.Interop.Word)import Microsoft.Office.Interop.Word as wordApp oWord = wordApp.ApplicationClassoWord = CreateObject(wordApp.Application)oWord.Visible = TrueoWord.Documents.Open(C:\tmp\Doc1.doc)oWord.Quit()System.Runtime.InteropServices.Marshal.ReleaseComObject (oWord)oWord = Nothingthank you___users-ironpython.com mailing list users-ironpython.com@lists.ironpython.comhttp://lists.ironpython.com/listinfo.cgi/users-ironpython.com ___ users-ironpython.com mailing list users-ironpython.com@lists.ironpython.com http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
Re: [IronPython] Re: IronPython 0.7.4 released
Did an answer to this ever come (perhaps privately to you)? At 06:54 AM 5/4/2005, Anthony Tarlano wrote Great job geeting 0.7.4 out the door!! Thanks for the heads up that it's possible to just grab the Lib directory from Python-2.3.5 and replace the IPython/bin/Lib directory to get the ball rolling... One big question comes to mind now that I have all those nice stdlib .py files.. Do you intend to adapt the python stdlib to work seamlessly in IronPython 1.0? If you don't think this is the plan then I will start a project to get this work done.. Please let me know as to not re-invent the wheel. Anthony J. Merrill / Analytical Software Corp ___ users-ironpython.com mailing list users-ironpython.com@lists.ironpython.com http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
Re: [IronPython] Re: IronPython 0.7.4 released
James, Yes, I did get a private response. Jim let me know that the issue is being discussed internally and when there has been an agreement on the way forward, which should be relatively soon, he will post that information to the mailing list. AnthonyOn 5/9/05, J. Merrill [EMAIL PROTECTED] wrote: Did an answer to this ever come (perhaps privately to you)?At 06:54 AM 5/4/2005, Anthony Tarlano wroteGreat job geeting 0.7.4 out the door!!Thanks for the heads up that it's possible to just grab the Lib directory from Python-2.3.5 and replace the IPython/bin/Lib directoryto get the ball rolling...One big question comes to mind now that I have all those nice stdlib.py files.. Do you intend to adapt the python stdlib to work seamlessly in IronPython 1.0?If you don't think this is the plan then I will start a project to getthis work done.. Please let me know as to not re-invent the wheel.Anthony ___ users-ironpython.com mailing list users-ironpython.com@lists.ironpython.com http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
RE: [IronPython] Pythalon
So when do you add the turtle to Avalon? :) winmail.dat___ users-ironpython.com mailing list users-ironpython.com@lists.ironpython.com http://lists.ironpython.com/listinfo.cgi/users-ironpython.com