Open Document Code

I am a beginner with VB.net and Solid Works and I need anexampleof opening a document and printing it to the defaultprinter.
I can call SW and have it open but the document does not openjustthe app. Here is what I have so far:

Dim swApp As SldWorks.SldWorks
foundFile = "C:\In\6.slddrw"
swApp = New SldWorks.SldWorks
swApp.OpenDoc(foundFile, 0)
swApp.Visible = True

I have a stop here to look at the application for the file:

swApp.CloseDoc(foundFile)

I have tried OpenDoc6 but I do not understand what theargumentswhere all about. Do I need to dim them and set the value.
Any help would be wonderful.

Thanks,
Jim
SolidworksApi macros