Skip to content

Ref Scan

Benjamin edited this page Oct 5, 2020 · 5 revisions

Ref Scan

A quick reference scan is necessary to ensure improved conversion.

why Refscan?

Consider the following snippet in VB6:

  Value = someObject.reference

Format

Format is a colon delimited text file. Colons are used instead of commas (,) because function signatures are stored in some cases (which contain commas) and this prevents value escaping.

Layout

Fields:

  1. Module name
  2. Name
  3. Type (Function, Method, Enum, Control)
  4. Signature (for methods) or Control replacement

Example of refs file

modLinter:LintForms:Function:Function LintForms(Optional ByVal Folder As String, Optional ByVal AutoFix As Boolean = False) As Boolean
modLinter:LintFileList:Function:Function LintFileList(ByVal List As String, ByVal AutoFix As Boolean) As Boolean
modLinter:LintFile:Function:Function LintFile(ByVal FileName As String, Optional ByRef ErrStr As String = "#", Optional ByVal AutoFix As Boolean = False) As Boolean
modLinter:LintFileOptions:Function:Function LintFileOptions(ByVal FileName As String, Optional ByRef ErrStr As String) As Boolean
modLinter:LintFileIndent:Function:Function LintFileIndent(ByVal FileName As String, Optional ByRef ErrStr As String, Optional ByVal AutoFix As Boolean = False) As Boolean
modLinter:LintFileBadCode:Function:Function LintFileBadCode(ByVal FileName As String, Optional ByRef ErrStr As String, Optional ByVal AutoFix As Boolean = False) As Boolean
frm:frm:Form:
frm:frm.fra:Control:VB.Frame
frm:frm.cmdSupport:Control:VB.CommandButton
frm:frm.cmdScan:Control:VB.CommandButton
frm:frm.cmdFile:Control:VB.CommandButton
frm:frm.txtFile:Control:VB.TextBox
frm:frm.cmdLint:Control:VB.CommandButton
frm:frm.cmdConfig:Control:VB.CommandButton
frm:frm.txtStats:Control:VB.TextBox
frm:frm.cmdClasses:Control:VB.CommandButton
frm:frm.cmdModules:Control:VB.CommandButton
frm:frm.cmdAll:Control:VB.CommandButton
frm:frm.cmdForms:Control:VB.CommandButton
frm:frm.cmdExit:Control:VB.CommandButton
frm:frm.txtSrc:Control:VB.TextBox
frm:frm.lblPrg:Control:VB.Label
Clone this wiki locally