I have an array with holes that I have to fill with different materials. My question is there is an easy way to fill them directly? I tried array, array draft and it is annoying to adjust them. In Blender, it easy to select the vertices and fill. Maybe it is a stupid question, but I am not really an expert.
FDM printers slice models in STL or OBJ format. Neither of these formats can transmit properties like Materials: they consist fully of surface definitions.
But... Multi-Material printing is a thing, yes?
Yes, but Multi-material prints use a simple trick: a single STL object can contain more than one surface definition, and you can slice more than one STL at once. But since slicers usually can't separate these from one another, they usually load multiple STLs and define the materials for each differently. For example, Adalinda has 4 different STLs, some containing multiple chunks of material, each STL corresponding to one printed color. And in this video Joel explains how printing that way works for an older version of the MMU.
So, to print the "cubes" in a different material, you'd need to have two STLs: The grid as one export, and the cubes as another. Then the Rest is slicing.
Now, you might not have a Multi-Material Printer? Then you might want to design your item in parts that snap into place or have an interference fit. For example, you might print a plate with all the cubes on one side, and a grid that has a relief on the back where the plate goes. Then you print two times with different materials and push the cube part into the grate, some glue in between, and voila! It looks like one print from the surface. With a clamshell design, you might even completely hide the existence of the carrier plate - by having two grates that surround a hollow cavity for the cube-plate, and the cube plate pushes out into either of the clamshells.
If you are asking for print then it is yes with FDM (fused deposition modeling) with multiple extrusion you can fill with different material easily. But if you are trying to change the material in your digital design then you need to work on every hole in the array, especially with FreeCAD. If you find any, please update here.