Hi and thank you. I have copied the start of the code down to where error lies. I made the text red.
Option Explicit
Global i As Integer ' generic counter
Global sp As SCANPARM ' one and only scanparm instance
Global numpixels As Integer
Global channum As Integer
Global XLVersion As Single
Global first, second, intercept, third As Single
Global coef As USB2000CONSTANTS
Function DoScan(sp As SCANPARM) As Integer
DoScan = OOI_DoScan(sp)
End Function
Sub Config(ByVal spec As Integer, ByVal adc As Integer, ByVal irq As Integer, ByVal base As Integer)
Call OOI_Config(spec, adc, irq, base)
End Sub
Sub SetNLCoefs(ByVal chan As Integer, coefs As Single)
Call OOI_SetNLCoefs(chan, coefs)
End Sub
Sub SetSLCoef(ByVal chan As Integer, ByVal coef As Single)
Call OOI_SetSLCoef(chan, coef)
End Sub
Sub EnableNLCorrection(ByVal chan As Integer, ByVal ena As Integer)
Call OOI_EnableNLCorrection(chan, ena)
End Sub
Sub EnableSLCorrection(ByVal chan As Integer, ByVal ena As Integer)
Call OOI_EnableSLCorrection(chan, ena)
End Sub
Sub ConfigEx(ByVal spec As Integer, ByVal adc As Integer, ByVal irq As Integer, ByVal base As Integer, ByVal port As Integer, ByVal NIDAQ As Integer)
Call OOI_ConfigEx(spec, adc, irq, base, port, NIDAQ)
End Sub
Function GetSpectrometerType() As Integer
GetSpectrometerType = OOI_GetSpectrometerType() <
End Function