Hi Marina,
I also told you about the second part in my last paragraph in the above post. Let me try to elaborate that part here as well. For achieving this as well, you can go by two approaches. The first approach is basically what I have suggested as it is the in-house Blue Prism solution whereas the second approach is related to create your own custom business object using a code stage which will require some knowledge of VB .NET which might a bit difficult to understand if you are new to the tool but it is a can also be considered as a good solution. I will explain the first approach only here since it can work well in your case.
Coming to the first method, what you can do is let say I have read the entire data from excel in form of a collection and also have filtered the collection where the defined value had the string '@'. As per your use case, you only need selected columns and not the entire range if I understand correctly. In order to achieve it let us take an example and understand the same.
In my case I am taking a small collection named
'Input Collection' with 6 columns having some data as shown below. This you can consider to the filtered collection that you have got till what my post says so far:
Let us assume that I only need to fetch the columns: '
Field3', '
Field5' and '
Field6', leaving aside the rest of the columns which will be written in the excel file as well. This is similar to what you mean by "
selecting the columns H,I,J,U,X,Z,AA,AB", you just need to know the header names in your collection that correspond to the column names in excel
. In order to achieve this I would first need to create two templates which denote each half of my collection once I split it vertically. So technically I need to create two collections with
a single blank row among which one will consist of the columns '
Field1', '
Field2' and '
Field4' and another one will have the columns '
Field3', '
Field5' and '
Field6' as we desire those columns as our target. In my case I name these collections as '
Collection Template I' and '
Collection Template II' as you can see below:
As a good practice I also check the highlighted button while preparing the template collections as they will automatically add a single row for me.
After this you would need to create two blank collections which will be used to store the output results once the split operation has been performed. You need not create any field definition for these you have done for the template collections as the field will added automatically with the data during runtime.
In my case I name these output collections as '
Output Collection I' and '
Output Collection II' which will constitute of their own individual halves of data as shown below:
Now you can use the '
Split Collection' action from the '
Utility - Collection Manipulation' VBO with the below shown parameters:
Upon running the action, you can see the results as follows:
Here you can see that I am able to fetch the result into
'Output Collection II' which I can use now to write into excel.
------------------------------
----------------------------------
Hope it helps you and if it resolves you query please mark it as the best answer so that others having the same problem can track the answer easily
Regards,
Devneet Mohanty
Intelligent Process Automation Consultant | Sr. Consultant - Automation Developer,
Wonderbotz India Pvt. Ltd.
Blue Prism Community MVP | Blue Prism 7x Certified Professional
Website:
https://devneet.github.io/Email: devneetmohanty07@gmail.com
----------------------------------
------------------------------
---------------------------------------------------------------------------------------------------------------------------------------
Hope this helps you out and if so, please mark the current thread as the 'Answer', so others can refer to the same for reference in future.
Regards,
Devneet Mohanty,
SS&C Blueprism Community MVP 2024,
Automation Architect,
Wonderbotz India Pvt. Ltd.