Copy DataView Row and add to another DataView

I’m back with another question!!

I want to take a row from DataView A and add it to DataView B. Does anyone know how to do this?

I have tried this, but it is not working.



Row Copy seems to do the trick

1 Like

Maybe I am trying to do the wrong thing. I have always said I don’t know what I am doing.

Dataview before event.

Dataview after event.

You can just create a Custom Data View and use it to drive all your dropdowns then use that Copy Row to move it around (if you need to)
DataViews in KineticUX are “free” just add a new one if you don’t want to clutter transview.

That is what I did with my AllData. Before the event, it has the first row in it from drop down 1. Trying to copy the associated row to the dataview from drop down 2 cleared the whole view.

Did you make a new view for each drop down? I don’t follow…

I would either use TransView or make a view called…ConfiguratorPartName

Then bind each drop down to a different column in COnfiguratorPartName

DropDown1 → COnfiguratorPartName.Column1…
DropDown2 → COnfiguratorPartName.Column2…

Then “when done” I’d just copy or set the expression value fo Part.Description to be COnfiguratorPartName.Column1 + COnfiguratorPartName.Column2 etc…

Unless I misunderstood what you are trying to do.

No, I made one view to add each associated row from the drop downs to it.

I’m going to past more specifics, just give me some time to write it up.

1 Like

First off, I should not have to do this, but apparently I work with people who are unable to follow any procedures. The problem is that parts are not entered consistently and therefore it is impossible to find if there is an existing part already in the system. When they can’t find one, they create a new part, which results in multiple part numbers for the same exact part. So, since we are doing a re-implementation, I am trashing all raw material parts and am going to make them recreate them when needed. To drive consistency, I am creating this customization.

I am storing all of the data in a UD table. Below is a snippet of the table and I will explain how I am using it after. This is all being done in a slider and I am bringing the UD table in as a dataview from a BAQ.

Key1 Key2 Key3 Key4 CheckBox01 ShortChar01
1 Hardware Screw 01 Style
2 Hardware Bolt 02
3 Hardware Nut 03
4 Hardware Washer 04
5 Hardware Stud 05
6 Style Wood TRUE Head
7 Style Machine TRUE Head
8 Style ThreadCutting TRUE Head
9 Style SheetMetal TRUE Head
10 Style Hex
11 Style HeavyHex
12 Style HexFlanged
13 Style Shoulder
14 Style Set TRUE Head

Key1 is just a number to be an ID.
Key2 stores the drop down “group” name.
Key3 stores the drop down values.
Key4 stores the column extension. So when you select Screw, I am using that to drive the CheckBox and ShortChar (eg. they become CheckBox01 and ShortChar01).
CheckBox01 stores whether or not that is a valid selection in the drop down for the group.
ShortChar01 stores the next drop down group.

Drop down 1 asks “What are you creating?”. The selections are Hardware, Metal, Other. If you select Hardware, I have events that makes drop down 2 appear and filters the options on Key2 and names the drop down label as Hardware Type.

Drop down 2 now has Screw, Bolt, Nut, Washer, Stud in it. If the user selects Screw, drop down 3 appears. The filters for drop down 3 are Key2 (which comes from ShortChar01 of the selected row) and CheckBox01 (the way I have built it, the column to filter on is dynamically created with Key4).

So on and so forth. Users keep selecting until the ShortChar shows End, and I have not figured out exactly what will happen at that point yet because I have not gotten there.

I am open to suggestions. If you say I should just create fields in TransView to store each drop down value and related fields that are needed, I can do that. Since I don’t know what I am doing, I don’t know how things are affected. You say TransView is “free”, but I don’t know what that means (@klincecum , sounds like something for your Coding Camp).

1 Like

If I knew how to correctly access curDataRow, I would not need to create the extra data views as once a value in a drop down is selected, it sets it as the curDataRow.

Are you trying to create new rows in the UDTable to store the results of the user selection? Or is the UD table just the source of the option sets in the drop downs?

This one

Are you saving the results anywhere? Or is this just an onscreen display to generate the correct part description syntax?

I’m not understanding/following why you would need to copy rows…

DropDown1 references UD0X.Key1.
Resulting selection gets bound to AllData.DropDown1Value

DropDown2 references UD0X.Key2 filtered on the value of AllData.DropDown1Value
That dropdown field gets bound to AllData.DropDown2Value

DropDown3 references UD0X.Key3 filtered on the value of AllData.DropDown2Value
That dropdown field gets bound to AllData.DropDown3Value

I guess in my mind, you’re not looking to add ROWS… you’re looking to add values to COLUMNS within (1) row.

UD01Data is the dataview I created to store the UD01 table I am loading from a BAQ.

Drop down 1 is a hard coded list that is bound to TransView.PartType

Drop down 2 is bound to TransView.T1 and the values come from UD01Data which is filtered on Key2 = DD1.value, displays Key3, and returns Key1 to TransView

Drop down 3 is bound to TransView.T2 and the values come from UD01Data which is filtered on Key2 = DD2.ShortChar01, displays Key3, and returns Key1 to TransView

The reason I am copying rows is because I need multiple columns from the same row that is selected. I have columnChanged events when the user selects a value in a drop down. They select Screw and I also need the Key4 value and ShortChar01 values. To get them, I thought it was easier to just copy the row to another dataview. It would be easier if I could just get at the current row to grab the values, but I don’t know how to do that. I also thought it would be easier to just copy all of the selected rows into a dataview so I could do an iterative event to build the part description. I could just add all of the fields I need to TransView, but I would have to copy rows again to be able to get to the other fields I need.

I am a complete hack when it comes to coding, it’s all self taught. So don’t assume I know what I am doing and if there is something painfully obvious that I am missing, it’s because I don’t know about it. :laughing:

I would have to understand it before I can explain it.

I myself have yet to do the deep dive necessary to be proficient in the new UI.

The Future Vintage GIF

1 Like

Ah, damnit! I just did some testing to make sure I was speaking correctly, and the value in curDataRow IS NOT updating. So I can’t use that.

1 Like

There’s a row-current-set event component.

Could you combine that with @josecgomez’s row-copy in an event?

But then what do I enter here? I checked and using the row-current-set does set curDataRow to whatever I selected.


Do you have a pre-determined “length” of configuration that is how many dropdowns will there be at the end are you putting those drop downs on the screen ahead of time?

Yes. Not every configuration will use all of them, but it is built for the longest one. That is where the ShortChar field comes into play. It stores the next group id or end.

1 Like