Samuel Derenboim Posted July 1, 2023 Share Posted July 1, 2023 (edited) Hello everyone. Given the number of materials both proprietary and generic out there, I was wondering if it would be possible to create a script or marionette that would create materials from a worksheet (including the properties, costs, k-values, and descriptions) Does anyone think this would be possible? Thank you in advance! Edited July 1, 2023 by Samuel Derenboim 2 Quote Link to comment
Pat Stanford Posted July 2, 2023 Share Posted July 2, 2023 @Samuel Derenboim Were the scripts and worksheet in this thread not sufficient for your needs? If not, what were they lacking? It seems like there are enough Vectorscript functions to create simple materials. I have not figured out how to make complex materials by script. Quote Link to comment
Samuel Derenboim Posted July 3, 2023 Author Share Posted July 3, 2023 @Pat Stanford Its not that at all. I actually use those scripts when i have a texture library to convert from and then modify the records, and its the most streamlined process I have to date to come close to creating a library, and for that I am very grateful. The reason why I was asking is because I have dozens of excel spread sheets with parameters set inside and copying that information in bulk into a worksheet does not work very well, even if I created the same number of material to match the excel spreadsheet, the copy and paste command does not copy the information in bulk...i would probably need to re-import it, and then re-copy it inside of vw. Additionally there is another element where if i update something in the excel spreadsheet, I would lose track of what was updated or not. Creating materials and their properties in bulk would be a more streamlined process I thought. My current possibly solution would be to import worksheet using ODBC and then copying the information that way. In this way, the information is streamlined from one location, and can then be imported directly into the document using ODBC and then that information can be copied and pasted into the worksheet with the scripts. I am in the process of using a database editor to centralize all of my spreadsheet libraries with something like nocodb (https://www.nocodb.com/ )or grist (https://www.getgrist.com/) Quote Link to comment
Pat Stanford Posted July 3, 2023 Share Posted July 3, 2023 I have a couple of bugs filed on worksheets that are going to make what you want harder than it should be. 1. There is a "bug" (actually I filed an enhancement request [Wish]) where you can't copy/paste multiple columns into database subrows. It works fine with a single column but trying to do multiple columns is really a pain. 2. There was a problem pasting from Excel (and Numbers) that was supposedly fixed for VW2023, but while the problem is different, paste from Excel still does not seem to work properly. So you may be able to Import from Excel and then use a script to generate the Materials. How do you want to move forward? Quote Link to comment
Samuel Derenboim Posted August 9, 2023 Author Share Posted August 9, 2023 (edited) @Pat Stanford Sorry for the late reply, I have been experimenting with introducing ODBC remotely, and am sharing it on here. In the interim, Ive discovered what I believe the unifying element between material libraries and a custom record database via ODBC (see below) Regarding the question as to the solution - i have a few ideas 1. Idea 1 ---- ODBC -> Object with record / texture / hatch -> script -> generate material with name of record or texture (as with original script) Note - the records would be a 1 - 1 match with material property records -> all that would need to happen is somehow run the script to match the record format with the material record properties. Would something like this be difficult? 2. Idea 2 ---- import csv / excel -> v-lookup material name with table -> if they match -> copy record per category (also 1:1 match in this case) 3. Idea 3 ---- brute force method - copy and paste 😂😂 Edited August 9, 2023 by Samuel Derenboim Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.