Good morning to yoo, too, @Claudio K2, I suggest you ask a revisioned question, which describe what you really want to achieve by your own new code. Your code is old from an really old flexsim version: A pointer declaration like "fsnode*" or a use of "itemtype" is today deprecated. There is always a progression in versions and you have to update source code between older and newer versions.
The second part of your question should be asked in a separate thread. It has nothing in common with inserting rows to tables. And it would help if you elaborate a bit more how your cutted log should be transfered as 6 boards to a next station together still as a batch or slice by slice.
At an exit trigger there is a picklist property in visuals to change a shape. If I assume you correctly you cut a log into boards. They are long but thin. They are separated but the shape of the log is still visible and you want get the batch transfered still as a whole. This is a bit difficult because you have after cutting a log in a separator 6 items. Then they are individual objects in your model. You can pack them. One board is becoming the container for the rest of 5 boards. Or you use a taskexecter who transport 6 items at the same time and a next station in your process is capable to let enter 6 items simultaneously because of his enhanced capacity. As you see, there is a need for more information what you really want an answer for and this is placed better in a new thread. I think you describe what you need, instead we are trying to assume. Thanks.