ah yes... //You can access the parameter to which an expression is connected by using the output port. Application.LogMessage("Parameter owner of the expression " + oExpr.OutputPorts(0).Target2.FullName);
the c++ doesn't show OutputPort having GetTarget() but it inherits from Port. http://download.autodesk.com/global/docs/softimage2012/en_us/sdkguide/index.html?url=si_cpp/classXSI_1_1Port.html,topicNumber=si_cpp_classXSI_1_1Port_html s On Mon, Sep 24, 2012 at 2:21 PM, Nicolas Burtnyk <nico...@redshift3d.com>wrote: > @Steve: GetSource works the other way - that is if I have the target > of the expression I can easily find the source, but what I need is to > find the target given the source. > > @César: That does indeed give me (among other things) the name of the > expression object from which I can determine the target of the > expression. > > Thanks guys! > > > On Mon, Sep 24, 2012 at 1:41 PM, César Sáez <cesa...@gmail.com> wrote: > > Oops, I've a typo... should be > > > > from sipyutils import si, siut > > from xml.dom.minidom import parseString > > oParam = > > > si().Dictionary.GetObject("Sources.Materials.DefaultLib.Scene_Material.Phong.diffuse.red") > > sData = siut().DataRepository.GetConnectionStackInfo(oParam) > > for sObj in parseString(sData).getElementsByTagName("object"): > > print sObj.toxml() > > > > > > On Mon, Sep 24, 2012 at 10:38 PM, César Sáez <cesa...@gmail.com> wrote: > >> > >> Hi, > >> I think you can get it using ConnectionStackInfo() and parsing the xml, > >> something like this... > >> > >> from sipyutils import si, siut > >> from xml.dom.minidom import parseString > >> oParam = > >> > si().Dictionary.GetObject("Sources.Materials.DefaultLib.Scene_Material.Phong.diffuse.red") > >> sData = siut().DataRepository.GetConnectionStackInfo(oParam) > >> for sObj in parseString(sData).getElementsByTagName("object"): > >> print sData.toxml() > >> > >> Cheers! > >> > > > >