Skip to main content
1-Visitor
October 14, 2013
Solved

Repeat Region in WF4 m220

  • October 14, 2013
  • 1 reply
  • 2850 views

If I create a repeat region to show quantity and Part Name:

3 11111_12345678-003

1 11111_12345678-008

1 11111_12345678-007

1 11111_12345678-006

1 11111_12345678-005

1 11111_12345678-004

1 11111_12345678-002

1 11111_12345678-001

I have tried to write several different relations to strip the 11111_ from assembly member name. I am using the extract function but cannot seem to get the relation right.

final_name = extract("asm_mbr_name",6,10)

gives me the table:

10 (and no member name). I am using asm.mbr.user_defined as final_name to generate table. I had one relation that returned 10 12345678-003 but have lost that relation. I know this is a simple fix.

TIA.

Patrick Perry BAE systems


This thread is inactive and closed by the PTC Community Management Team. If you would like to provide a reply and re-open this thread, please notify the moderator and reference the thread. You may also use "Start a topic" button to ask a new question. Please be sure to include what version of the PTC product you are using so another community member knowledgeable about your version may be able to assist.
Best answer by MartinHanak

Patrick,

you have to follow this procedure (see uploaded data):

1.]

Create Repeat Region and put &asm.mbr.name into its column.

2.]

Define relation.

final_name=extract(asm_mbr_name,7,6)

These two steps are saved in 11111_drw.drw.4 drawing.

3.]

Replace &asm.mbr.name with &rpt.rel.final_name.

This third step is saved in 11111_drw.drw.5 drawing.

Martin Hanak

1 reply

24-Ruby III
October 15, 2013

Patrick,

you have to define Relation in Repeat Region and then put &rpt.rel.final_name into Repeat Region cell.

I uploaded test data...

Martin Hanak

pperry1-VisitorAuthor
1-Visitor
October 16, 2013

i have done that and the table becomes one line. One of the issues I have is my relation does not want to accept asm_member_name as a valid attribue. If I use the final_name = asm_mbr_name the relations show and error and will not move forward. The error indicates tha asm_mbr_name (or asm.mbr.name) is an invalid symbol.

24-Ruby III
October 17, 2013

Patrick,

you can find the answer inside my test files (created in WF4). Download repeat_region.zip and do some investigation:

> check Repeat Region properties

> check Repeat Region relations

Martin Hanak