I have a query I'm trying to connect to using Excel but because of this function:
Code:
Public Function ProductItemName(iFGTD As String, iFGMD As String, iRMVID As String, iLGTH As Double, iDIMEN As String) As String
Select Case iFGTD
Case "BENDING"
ProductItemName= iFGMD & " " & iRMVID & " " & iDIMEN
Case "BRC"
ProductItemName= iFGMD & " " & iDIMEN & " (" & iLGTH & "FT)"
Case "S&C"
ProductItemName= iFGMD & " " & iRMVID
Case "DECKING", "REBAR"
SalesItemName = iRMVID & " " & iDIMEN
Case Else
ProductItemName= iFGMD & " " & iRMVID & " " & iDIMEN
End Select
End Function
I use to name the items produced, Excel is unable to see the query. How can I work around this keeping the naming function?