Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations KootK on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to import attributes pre-defined in Solidworks? 4

Status
Not open for further replies.

JerryWong

Aerospace
Jul 31, 2015
16
When I download a model file from internet,It needs to define several attributes like "Specification""Materail""Part Number"。In UG NX, we can import these from a pre-defined file. It's painful to type in these one by one every time.
 
Replies continue below

Recommended for you

This may not be exactly what you envisioned, but it is very useful to me in my work.

You say "attributes". In Solidworks lingo I think you're talking Custom Properties. I learned a neat trick. Open an existing file for which the Custom Properties are already close to what you want on the new file. Open the Custom Properties dialog box. Select one or more rows. Hit Ctrl-C to copy. Open your new downloaded part. Open Custom Properties. Click in the properties field like you're establishing a new property. Hit Ctril-V to paste. Just like Excel, the properties from the old part are copied into the new one. Edit as needed.
 
Or, you can save part. assy, or dwg custom properties standards. Document properties, Drafting Standard, save to external file. Load from external file to update props.

Chris, CSWP
SolidWorks
ctophers home
 
I use the "Property Tab Builder" to make pre-defined properties that I can load into every part, assy and Drawing.

PTB_-_1_kbcqxb.jpg


When i start a new part I can select the template:
PTB_-_2_sadquw.jpg


It feeds in all the categories I created and now I can enter them in, or if they are preprogrammed to certain aspects of the file (this works well if you have PDM as the Data Card Data can be automatically added) then it will pull that information over automatically. A simple example would be like Weight or Material.
PTB_-_3_yg5owt.jpg


Then when you select "apply" it adds all the properties into the file.
PTB_-_4_fxe8su.jpg


It is a bit of upfront work, but its so much easier in the long run.

Scott Baugh, CSWP [pc2]
Mechanical Engineer
Ciholas

"If it's not broke, Don't fix it!"
faq731-376
 
SBaugh that's exactly what I want.
But I find another problem. To autofill part number in drawing file, I create "Autofill No." in custom property, the value is
"Part.Extension.CustomPropertyManager("").Set("SW-Part Number",Rtrim(Left(Part.GetTitle,InStr(Part.GetTitle,"R")-2)))"
My file is "TZ2500-06-08A-R00.sldprt", which part number is "TZ2500-06-08A"
001_ex8ypq.png

Then in equation like below
002_ruhegp.png

it works well for part(sldprt), after rebuild the "SW-Part Number" will be filled with "TZ2500-06-08A" automatically.
but for assembly(sldasm), problem problem problem
003_zxifru.png

I guess there's something different between part and assembly in globle variables.
 
How are you programming the equation?

are you typing in the part number for the part is it automatically filling the property?

Scott Baugh, CSWP [pc2]
Mechanical Engineer
Ciholas

"If it's not broke, Don't fix it!"
faq731-376
 
handleman, yes, you are right.
It looks confused why SW uses two different extensions for part and assembly. NX uses ".prt" for both part and assembly. Actually There's no difference between them. When creating a part file, it uses part template for it, when creating assembly file, similarly it uses assembly template, that's all. NX has a unified logic for this. Sometimes when I make features in a assembly file, and realize I created the wrong type, it irritated me.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor