/ Published in: C#

I try to call vb.net function in c#.The function pass parameter ref and boolean. It is call in vb.net directly .how can i call in c#.
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
VB.net : Public Shared Function GetIconIndex(ByRef item As CShItem, _ Optional ByVal GetOpenIcon As Boolean = False, _ Optional ByVal GetSelectedIcon As Boolean = False _ ) As Integer C# : public static int GetIconIndex(ref CShItem item, bool GetOpenIcon, bool GetSelectedIcon); Call like: Vb.net: lvi.ImageIndex = SystemImageListManager.GetIconIndex(lvi.Tag, False) It works properly. C#: lvi.ImageIndex = SystemImageListManager.GetIconIndex( lvfile.Tag, false); It gives error: Error 22 No overload for method 'GetIconIndex' takes '2' arguments
Comments
