Thursday, June 28, 2012

STL Files: Opening an STL file for reading in VBA

STL files when they are stored from solidworks are in Binary format. Thus, VB needs to open a binary file for reading.

The general format of the open command is:

Open pathname For mode [Access access] [lock] As [#]filenumber [Len=reclength]

The format of this command that I used was:

Open "C:\Block.STL" For Binary Access Read As #1

With that, I opened a file located at C:\Block.STL for Binary mode and I associated it with file #1.





No comments:

Post a Comment

Cocktail Jazz for Beginners

  https://pianowithjonny.com/piano-lessons/how-to-play-beginner-cocktail-piano-in-3-steps/ https://www.pianogroove.com/jazz-piano-lessons/co...