<code>Oh, by the way, here's the VB code I'm using:<br>
<br>
<a
href='<a href="http://www.blendedtechnologies.com/wp-content/VB_uses_Python.zip">http://www.blendedtechnologies.com/wp-content/VB_uses_Python.zip</a>'
title='Help me do this!'></code><code><a href="http://www.blendedtechnologies.com/wp-content/VB_uses_Python.zip">http://www.blendedtechnologies.com/wp-content/VB_uses_Python.zip</a></code><code></a></code><br><br>

I wonder if this question should go to some kind of VB list instead?<br>
<br>
-Greg<br>
<br>
<br><div><span class="gmail_quote">On 8/26/05, <b class="gmail_sendername">Gregory Piņero</b> <<a href="mailto:gregpinero@gmail.com">gregpinero@gmail.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hey guys, <br>
<br>
This question inpsired me to try this in VB6.  I did a search and copied what I saw at <br>
<a href="http://forums.devshed.com/t158692/s.html" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://forums.devshed.com/t158692/s.html <img src="chrome://targetalert/content/skin/new.png" border="0">
</a><br>
<br>
However I'm running into the same problem they are.  When I try to run:<br>
res = Python.PyRun_SimpleString("5+7")<br>
<br>
I get the error message:<br>
Bad DLL calling convention (Error 49)<br>
<br>
Which VB help describes as:<br>
<p>
<a>Arguments</a> passed to a
<a>dynamic-link library</a> (DLL) must exactly 
match those expected by the routine. Calling conventions deal with number, type, 
and order of arguments. This error has the following causes and solutions: 
</p>
<ul type="disc">
<li>Your program is calling a routine in a DLL that's being passed the wrong 
type of arguments.
<p>Make sure all argument types agree with those specified in the 
declaration of the routine you are calling.</p>
</li><li>Your program is calling a routine in a DLL that's being passed the wrong 
number of arguments.
<p>Make sure you are passing the same number of arguments indicated in 
the declaration of the routine you are calling.</p>
</li><li>Your program is calling a routine in a DLL, but isn't using the StdCall 
calling convention.
<p>If the DLL routine expects arguments
<a>by value</a>, then make sure <b>ByVal</b> is 
specified for those arguments in the declaration for the routine.</p>
</li><li>Your <b>Declare</b> statement for a Windows DLL includes <b>CDecl</b>.<br>
</li>
</ul>
<br>
Any ideas?<br>
<br>
-Greg<div><span class="e" id="q_105f3a6fe0559b9d_1"><br>
<br><br><div><span class="gmail_quote">On 8/26/05, <b class="gmail_sendername">Gregory Piņero</b> <<a href="mailto:gregpinero@gmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">gregpinero@gmail.com 
<img src="chrome://targetalert/content/skin/mailto.png" border="0"></a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
How do I get it into VB6?  Now that's an answer that would save my life many times over.<br>
<br>
-Greg<div><span><br><br><div><span class="gmail_quote">On 8/26/05, <b class="gmail_sendername">Alessandro Bottoni</b> <<a href="mailto:alessandro.bottoni@infinito.it" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">

alessandro.bottoni@infinito.it <img border="0"></a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">

Thomas Bartkus wrote:<br><br>> Name: lib64python2.4-devel<br>> Summary: The libraries and header files needed for Python development<br>><br>> Description: The Python programming language's interpreter can be extended
<br>> with dynamically loaded extensions and can be embedded in other programs.<br>> This package contains the header files and libraries needed to do these<br>> types of tasks.<br>> ------------------------------------------------------
<br>><br>><br>> *** The Python programming language's interpreter ... can be embedded in<br>> other programs. ***<br>><br>> That's very intriguing!<br>> But I can't seem to locate much information about this.
<br>><br>> Can anyone direct me to greater enlightenment?<br>> Thomas Bartkus<br><br>There is a section of the official documentation devoted to extending and<br>embedding python:<br><br><a href="http://docs.python.org/ext/ext.html" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">


http://docs.python.org/ext/ext.html <img border="0"></a> <br><br>There are a few articles on this topics on the web, as well. Search<br>"embedding python" with Google.
<br>-----------------------------------<br>Alessandro Bottoni
<br>--<br><a href="http://mail.python.org/mailman/listinfo/python-list" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://mail.python.org/mailman/listinfo/python-list <img border="0">
</a> <br></blockquote></div><br><br clear="all"><br></span></div><span>-- <br>Gregory Piņero<br>Chief Innovation Officer
<br>Blended Technologies<br>(<a href="http://www.blendedtechnologies.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">www.blendedtechnologies.com <img border="0">
</a>)

</span></blockquote></div><br><br clear="all"><br>-- <br>Gregory Piņero<br>Chief Innovation Officer<br>Blended Technologies<br>(<a href="http://www.blendedtechnologies.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
www.blendedtechnologies.com</a>)

</span></div></blockquote></div><br><br clear="all"><br>-- <br>Gregory Piņero<br>Chief Innovation Officer<br>Blended Technologies<br>(<a href="http://www.blendedtechnologies.com">www.blendedtechnologies.com</a>)