I am new in the community and I am facing an issue, maybe you can help me.
I want to iterate through a data table and order items in an online shop (amazon).
I want to club the orders by brands. And I want to create a shopping basket for each brand.
In the example, I want the shoes, trousers and shirts from nike in a shopping basket and after I ordered that basket, I want to shop the next one with shoes and shirt from adidas and so on.
How can I iterate through the table AND do the actions for each brand? I already sorted data table, but that was not enough.
That is just the sorted table. So far so good. Now I want to do actions (grab article from each row) and place an order for each brand. Something like "if next row is same brand, then put it in same order basket, if not, then create a new basket.
Hi, that is a good idea, but can I say “after you filtered for the brand nr.1, filter then for brand nr.2 and do the same process, until all open positions are ordered?”
Actually, it is not going so well using the switch.
I don’t know how to use the switch correctly.
In this example, I would like to receive 3 datatable (for each brand), so I can proceed with the “filtered” information. Nevertheless, I am not able to create a dynamic filter.
r is like a local variablename for the linq statement and is representing the current looped row
we define the grouping by using the brand column value and assign it to an identifier called b