title: How do i pass a class as an argument and then use a shared method of that class?
body: <p>NOTE: This question is NOT asking how to pass an <em>instance</em> of a class.  It is asking how to pass <em>the</em> class which has shared items.  </p>
  
  <p>For example ...
  Any idea on how to make a function that will do this?</p>
  
  <pre><code>Public Function InsertSQL(ByVal xClass As Type) As String
      InsertSQL = "Insert into "
      InsertSQL = InsertSQL &amp; xClass.TableName
      InsertSQL = InsertSQL &amp; " ("
      InsertSQL = InsertSQL &amp; xClass.FieldList
      InsertSQL = InsertSQL &amp; " )"
  End Function
  </code></pre>
  
  <p>With a set of classes like this:</p>
  
  <pre><code>Public Class cClient
      Public Shared TableName = "Clients"
      Public Shared Function FieldList() As String
          FieldList = "Name, Phone"
      End Function
  End Class
  
  Public Class cSale
      Public Shared TableName = "Sales"
      Public Shared Function FieldList() As String
          FieldList = "Name, Amount"
      End Function
  End Class
  </code></pre>
  
  <p>I have search for "How to a pass a class as an argument" on Google, but have not found anything that addresses a way to access shared methods of the class.  I can only get results that think I am wanting to pass an instance of that class.</p>
  
  <p>Note that this code is just an example.
  And - of course, I have no problem if I pass an instance of a class.<br>
  But - that is not what I am trying to figure out.</p>