Skip to main content
Solved

I'm looking for a way to populate a list based on current list value without exploding it.

  • October 13, 2020
  • 5 replies
  • 21 views

rva1
Contributor
Forum|alt.badge.img+1

Hi ! I hope someone can help.

 

I'm trying to create more attributes within existing list without exploding and rebuilding it. Like this:

 

_list{0}.aaa : A_123

_list{1}.aaa : A_234

_list{2}.aaa : B_245

 

to

 

_list{0}.aaa : A

_list{0}.bbb :123

_list{1}.aaa : A

_list{1}.bbb: 234

_list{2}.aaa : B

_list{2}.bbb: 245

 

Is there a way?

 

I'm specially looking for help on the list creating part. I can manage renaming the list values;)

 

I was looking for a way to first do this:

_list{0}.aaa : A_123

_list{0}.bbb : A_123

 

and than do this:

_list{0}.aaa : A

_list{0}.bbb : 123

 

cheers,

ronald

 

Best answer by stalknecht

My best guess is to use a pythonCaller. I have attached a small example.

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

5 replies

stalknecht
Contributor
Forum|alt.badge.img+22
  • Contributor
  • Best Answer
  • October 14, 2020

My best guess is to use a pythonCaller. I have attached a small example.


rva1
Contributor
Forum|alt.badge.img+1
  • Author
  • Contributor
  • October 15, 2020

My best guess is to use a pythonCaller. I have attached a small example.

marvelous wilko!

tnx

ronald


rva1
Contributor
Forum|alt.badge.img+1
  • Author
  • Contributor
  • October 15, 2020

My best guess is to use a pythonCaller. I have attached a small example.

strange... i can access the original list in transformers, but not the lists created by the python script.

 

_list{0}.IfcContent (encoded: UTF-8) < created with python script

_list{0}.IfcLine (encoded: UTF-8) < created with python script

_list{0}.text_line_data (encoded: windows-1252) < original list

 

Could it be encoding?

 


stalknecht
Contributor
Forum|alt.badge.img+22
  • Contributor
  • October 15, 2020

strange... i can access the original list in transformers, but not the lists created by the python script.

 

_list{0}.IfcContent (encoded: UTF-8) < created with python script

_list{0}.IfcLine (encoded: UTF-8) < created with python script

_list{0}.text_line_data (encoded: windows-1252) < original list

 

Could it be encoding?

 

No I've forgot to expose the list in the PythonCaller in the example. See screenshotCapture


rva1
Contributor
Forum|alt.badge.img+1
  • Author
  • Contributor
  • October 15, 2020

strange... i can access the original list in transformers, but not the lists created by the python script.

 

_list{0}.IfcContent (encoded: UTF-8) < created with python script

_list{0}.IfcLine (encoded: UTF-8) < created with python script

_list{0}.text_line_data (encoded: windows-1252) < original list

 

Could it be encoding?

 

thank you!