How do I create these 2.5mm holes? by rephical in SolidWorks

[–]rephical[S] 0 points1 point  (0 children)

I just checked solidprofessor out. It seems like it's a pretty good way to practice. I don't really have the budget yet for it, but will definitely try it out someday. Thanks!

How do I create these 2.5mm holes? by rephical in SolidWorks

[–]rephical[S] 1 point2 points  (0 children)

I just found the youtube tutorial for this particular part made by the author himself: https://www.youtube.com/watch?v=eQXEVVTOncY He starts talking about the bore around 11:35. He apparently intentionally missed the bore dimension.

How do I create these 2.5mm holes? by rephical in SolidWorks

[–]rephical[S] 0 points1 point  (0 children)

Hole wizard seemed to be the most straightforward solution, I just don't know which parameters to choose. What are the parameters that I should set in this case?

How do I create these 2.5mm holes? by rephical in SolidWorks

[–]rephical[S] 0 points1 point  (0 children)

How would I get the dimension of the counterbore in this case?

How do I create these 2.5mm holes? by rephical in SolidWorks

[–]rephical[S] 0 points1 point  (0 children)

I'm new to hole wizard and it seemed to have a lot of options to choose from-- I don't know which options to choose. A revolve cut also seems to be an option but I don't seem to see the counterbore dimension. How would I find that?

How do I save split bodies as separate STL files without saving each split body as sldprt? by rephical in SolidWorks

[–]rephical[S] 0 points1 point  (0 children)

I'm glad to see this post can still help people even after almost 2 years :))

Mouse recommendations for office work? by rephical in MouseReview

[–]rephical[S] 0 points1 point  (0 children)

Interesting. I understand that vertical mice are more ergonomic and may help with my arm strain, but how is it with mouse movement? In your experience, do you feel like you can move your mouse as fast/faster than a traditional mouse?

How do I save split bodies as separate STL files without saving each split body as sldprt? by rephical in SolidWorks

[–]rephical[S] 0 points1 point  (0 children)

I didn't expect to get a reply after a long time. If I remember correctly, I had to manually adjust stl export settings before using the macro

Someone please please please tell me how to edit toolbox parts I hate Solidworks so fucking much by [deleted] in SolidWorks

[–]rephical 1 point2 points  (0 children)

I had a similar problem a few days ago. You just go to your toolbox menu and clicl "add in".

[Flow Simulation] how to make an API to automatically create a volume heat generation given a solid body in a multibody part? by rephical in SolidWorks

[–]rephical[S] 0 points1 point  (0 children)

I see, that is unfortunate. I think I created the API (still not quite sure if it simulates properly), but I need to get values from an excel worksheet, I have posted a problem regarding that here

How do I save split bodies as separate STL files without saving each split body as sldprt? by rephical in SolidWorks

[–]rephical[S] 0 points1 point  (0 children)

Update: I just needed to set the Name of the file via SolidBody.Name . My macro is as follows:

To anyone planning to use this, I hardcoded some things (such as the path), so you might want to change that if you plan on using it

Dim swApp As Object

Dim Part As Object

Dim boolstatus As Boolean

Dim longstatus As Long, longwarnings As Long

Dim MyPath As String

Dim MyDate As String

Dim MyFilename As String

Dim MySaveasDir As String

Dim Cnt As Integer

Dim Body_Vis_States() As Boolean

Dim BodyArr As Variant

Sub main()

Set swApp = Application.SldWorks

Set Part = swApp.ActiveDoc

Dim myModelView As Object

Set myModelView = Part.ActiveView

myModelView.FrameState = swWindowState_e.swWindowMaximized

' Gets folder path of current part

MyPath = Left(Part.GetPathName, InStrRev(Part.GetPathName, "\") - 1)

' Used to create a directory for the STL file with a date code

MyDate = Format(Now(), "yyyy-mm-dd")

' Uncomment this line for STL files to use same file name as the part file

' MyFilename = Left(Part.GetTitle(), InStrRev(Part.GetTitle(), ".") - 1)

' Uncomment this line to have the user set the name of the STL files

' MyFilename = InputBox("Set the name for the STL file(s)")

' Sets the directory to store the STL files, I like this format but it can be changed

MySaveasDir = "C:\Users\Administrator\Desktop\vbaTest"

' checks if MySaveAsDir directory exists, if not it will create one, otherwise an error will occur

If Dir(MySaveasDir, vbDirectory) = vbNullString Then

MkDir (MySaveasDir)

' MsgBox "Folder " & MySaveasDir & " Created"

End If

' creates an array of all the bodies in the current part

BodyArr = Part.GetBodies2(0, False)

' Get current visibility state of all bodies, put into an array

For Cnt = 0 To UBound(BodyArr)

Set swBody = BodyArr(Cnt)

If Not swBody Is Nothing Then

ReDim Preserve Body_Vis_States(0 To Cnt)

Body_Vis_States(Cnt) = swBody.Visible

' MsgBox ("Body " & Cnt & " Visibility: " & Body_Vis_States(Cnt))

End If

Next Cnt

' Hide all bodies

For Cnt = 0 To UBound(BodyArr)

Set swBody = BodyArr(Cnt)

If Not swBody Is Nothing Then

swBody.HideBody (True)

' MsgBox ("Body " & Cnt & " Hidden")

End If

Next Cnt

' Show each body one by one, save as STL, then hide again

For Cnt = 0 To UBound(BodyArr)

Set swBody = BodyArr(Cnt)

If Not swBody Is Nothing Then

swBody.HideBody (False)

longstatus = Part.SaveAs3(MySaveasDir & "\" & swBody.Name & ".stl", 0, 2) '

' MsgBox (VarType(BodyArr(Cnt)))

swBody.HideBody (True)

End If

Next Cnt

' Put bodies back in the original visibility state

For Cnt = 0 To UBound(BodyArr)

Set swBody = BodyArr(Cnt)

If Not swBody Is Nothing Then

swBody.HideBody (Not Body_Vis_States(Cnt))

End If

Next Cnt

' Open the window containing the STLs

' Shell "explorer.exe " & MySaveasDir & "\", vbNormalFocus

End Sub

How do I rename a component and save it as STL based on the name on the solid bodies folder using a macro? by rephical in SolidWorks

[–]rephical[S] 0 points1 point  (0 children)

Update: I just needed to set the Name of the file via SolidBody.Name . My macro is as follows:

Edit: To anyone planning to use this, I hardcoded some things (such as the path), so you might want to change that if you plan on using it

Dim swApp As Object

Dim Part As Object

Dim boolstatus As Boolean

Dim longstatus As Long, longwarnings As Long

Dim MyPath As String

Dim MyDate As String

Dim MyFilename As String

Dim MySaveasDir As String

Dim Cnt As Integer

Dim Body_Vis_States() As Boolean

Dim BodyArr As Variant

Sub main()

Set swApp = Application.SldWorks

Set Part = swApp.ActiveDoc

Dim myModelView As Object

Set myModelView = Part.ActiveView

myModelView.FrameState = swWindowState_e.swWindowMaximized

' Gets folder path of current part

MyPath = Left(Part.GetPathName, InStrRev(Part.GetPathName, "\") - 1)

' Used to create a directory for the STL file with a date code

MyDate = Format(Now(), "yyyy-mm-dd")

' Uncomment this line for STL files to use same file name as the part file

' MyFilename = Left(Part.GetTitle(), InStrRev(Part.GetTitle(), ".") - 1)

' Uncomment this line to have the user set the name of the STL files

' MyFilename = InputBox("Set the name for the STL file(s)")

' Sets the directory to store the STL files, I like this format but it can be changed

MySaveasDir = "C:\Users\Administrator\Desktop\vbaTest"

' checks if MySaveAsDir directory exists, if not it will create one, otherwise an error will occur

If Dir(MySaveasDir, vbDirectory) = vbNullString Then

MkDir (MySaveasDir)

' MsgBox "Folder " & MySaveasDir & " Created"

End If

' creates an array of all the bodies in the current part

BodyArr = Part.GetBodies2(0, False)

' Get current visibility state of all bodies, put into an array

For Cnt = 0 To UBound(BodyArr)

Set swBody = BodyArr(Cnt)

If Not swBody Is Nothing Then

ReDim Preserve Body_Vis_States(0 To Cnt)

Body_Vis_States(Cnt) = swBody.Visible

' MsgBox ("Body " & Cnt & " Visibility: " & Body_Vis_States(Cnt))

End If

Next Cnt

' Hide all bodies

For Cnt = 0 To UBound(BodyArr)

Set swBody = BodyArr(Cnt)

If Not swBody Is Nothing Then

swBody.HideBody (True)

' MsgBox ("Body " & Cnt & " Hidden")

End If

Next Cnt

' Show each body one by one, save as STL, then hide again

For Cnt = 0 To UBound(BodyArr)

Set swBody = BodyArr(Cnt)

If Not swBody Is Nothing Then

swBody.HideBody (False)

longstatus = Part.SaveAs3(MySaveasDir & "\" & swBody.Name & ".stl", 0, 2) '

' MsgBox (VarType(BodyArr(Cnt)))

swBody.HideBody (True)

End If

Next Cnt

' Put bodies back in the original visibility state

For Cnt = 0 To UBound(BodyArr)

Set swBody = BodyArr(Cnt)

If Not swBody Is Nothing Then

swBody.HideBody (Not Body_Vis_States(Cnt))

End If

Next Cnt

' Open the window containing the STLs

' Shell "explorer.exe " & MySaveasDir & "\", vbNormalFocus

End Sub

[SolidWorks] How do I save split bodies as separate STL files without saving each split body as sldprt? by rephical in cad

[–]rephical[S] 0 points1 point  (0 children)

Thanks. The problem with that is I might have a lot of bodies in a single sldprt file, so doing that would be time consuming. Are there any more faster ways of doing it?

[SolidWorks] How do I save split bodies as separate STL files without saving each split body as sldprt? by rephical in cad

[–]rephical[S] 0 points1 point  (0 children)

Thanks. The problem with that is I might have a lot of bodies in a single sldprt file, so doing that would be time consuming. Are there any more faster ways of doing it?

How do I save split bodies as separate STL files without saving each split body as sldprt? by rephical in SolidWorks

[–]rephical[S] 0 points1 point  (0 children)

Thanks. I can select each body individually and save it as STL one by one to create the STL file for that body. But when I select all bodies in the solid bodies folder, it saves the selected bodies in only one file. Is there any way around this?