Compare strings by custom sort order
Naming  

The name CompareCode does not express ll what this method is doing. Try to name it more meaningful.  

General  

You don't need a List(Of String) here. Add a private const string like  

Private Const orderedCode As String = "ICMF"
Private Function CompareCode(ByVal code As String, ByVal otherCode As String) As Boolean
    Return orderedCode.IndexOf(code) &lt; orderedCode.IndexOf(otherCode)
End Function