<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 12 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Tahoma;
panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
span.hoenzb
{mso-style-name:hoenzb;}
span.wrc0
{mso-style-name:wrc0;}
span.EmailStyle19
{mso-style-type:personal-reply;
font-family:"Calibri","sans-serif";
color:#1F497D;}
.MsoChpDefault
{mso-style-type:export-only;}
@page WordSection1
{size:8.5in 11.0in;
margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-US link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Sure. I’m trying to use the example here:<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><a href="http://dl.dropbox.com/u/1633130/PyQt%20tuts/example1.py">http://dl.dropbox.com/u/1633130/PyQt%20tuts/example1.py</a><o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><a href="http://dl.dropbox.com/u/1633130/PyQt%20tuts/example1.ui">http://dl.dropbox.com/u/1633130/PyQt%20tuts/example1.ui</a><o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>This is from </span><a href="http://nathanhorne.com/?p=451">http://nathanhorne.com/?p=451</a><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p></o:p></span></p><p class=MsoNormal><a name="_MailEndCompose"><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p> </o:p></span></a></p><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'><p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> Panupat Chongstitwattana [mailto:panupatc@gmail.com] <br><b>Sent:</b> Monday, January 23, 2012 11:11 AM<br><b>To:</b> Rapczak, Jesse<br><b>Subject:</b> Re: [PyQt] Problem with uic.loadUiType<o:p></o:p></span></p></div><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal style='margin-bottom:12.0pt'>Can we see your code?<br><br><o:p></o:p></p><div><p class=MsoNormal>On Tue, Jan 24, 2012 at 12:04 AM, Rapczak, Jesse <<a href="mailto:jrapczak@soe.sony.com">jrapczak@soe.sony.com</a>> wrote:<o:p></o:p></p><p class=MsoNormal>Hey all,<br><br>I'm relatively new to PyQt and am trying to use uic.loadUiType to load<br>up a .ui file at runtime. However, I'm getting the following error. I<br>must be doing something wrong... any ideas?<br><br># Error: <type 'exceptions.SyntaxError'>: invalid syntax (<string>, line<br>31)<br># Traceback (most recent call last):<br># File "<maya console>", line 1, in <module><br># File "c:\Tools\Maya\Common\Utilities\BranchSelector\example1.py",<br>line 40, in <module><br># listExample_form, listExample_base =<br>uic.loadUiType('C:\Tools\Maya\Common\Utilities\BranchSelector\example1.u<br>i')<br># File "c:\Tools\Maya\Version\2012\Utilities\PyQt4\uic\__init__.py",<br>line 200, in loadUiType<br># winfo = compiler.UICompiler().compileUi(uifile, code_string,<br>from_imports)<br># File<br>"c:\Tools\Maya\Version\2012\Utilities\PyQt4\uic\Compiler\compiler.py",<br>line 55, in __init__<br># CompilerCreatorPolicy())<br># File "c:\Tools\Maya\Version\2012\Utilities\PyQt4\uic\uiparser.py",<br>line 127, in __init__<br># self.factory = QObjectCreator(creatorPolicy)<br># File "c:\Tools\Maya\Version\2012\Utilities\PyQt4\uic\objcreator.py",<br>line 91, in __init__<br># if load_plugin(open(filename), plugin_globals, plugin_locals):<br># File<br>"c:\Tools\Maya\Version\2012\Utilities\PyQt4\uic\port_v2\load_plugin.py",<br>line 47, in load_plugin<br># raise WidgetPluginError("%s: %s" % (e.__class__, str(e)))<br># WidgetPluginError: <type 'exceptions.SyntaxError'>: invalid syntax<br>(<string>, line 31) #<br><br><br>Thanks!<br><span style='color:#888888'><br><span class=hoenzb>--</span><br><span class=hoenzb>Jesse Rapczak</span><br><span class=hoenzb>_______________________________________________</span><br><span class=hoenzb>PyQt mailing list <a href="mailto:PyQt@riverbankcomputing.com">PyQt@riverbankcomputing.com</a></span><br><span class=hoenzb><a href="http://www.riverbankcomputing.com/mailman/listinfo/pyqt" target="_blank">http://www.riverbankcomputing.com/mailman/listinfo/pyqt</a></span></span><o:p></o:p></p></div><p class=MsoNormal><o:p> </o:p></p></div></body></html>