Your project is down to just the Enum/Int issue (being worked on now) and one new error (or one I didn’t see before):
If records.Count > 0 Then
Return records(0) // E626 Member "records" of type "sequence of RelationshipEntity" is a variable but is used as a method
Else
Return Nothing
End If
this seems valid, record is an ISequence, and this should not be indexable!?
I’m not sure I’m following your question, and unfortunately I’m on my way out the door. But if this helps: records is a type of collection, and there is a default property of Item(index of integer). Because it is a default property, instead of syntax:
Yeah, this seams to be an Option Strict Off hack; I’ve logged to add it, but this is a really bad idea. (0) is fine, but imagine doing this in a for loop — an IEnumerable doesnt provide random access, so the sequence has to be reiterated for each access…
That being said, I probably use that syntax more than I should. Option Strict On is something I keep assuming is already on for my projects, but isn’t necessarily, especially for this type of project which is initially created by LLBLGen. But I really should make sure it is turned on everywhere and clean up my code faux pas.
Assuming that it isn’t used in the code generated by LLBLGen (and I don’t think it is), it is less of an issue for me to change my own code.
In your case. replacing record(0) with record.First() did the trick, and your solution now compiles clean for me with latest, after that change. What we’ll did, compiler side is translate sequence(x) to sequence.Skip(x-1).First.
I can send you a new build with the other fixes (not the sequence one) in a short while.