Ask for C# equivalent of VB Enum using at method

M

Mullin Yu

At Vb6, we can do the following, and then call typing SendUsingMethod, it
will pop up SendUsingPickup and SendUsingPort option

Public Enum eEDMSMailSendUsing
SendUsingPickup = 1
SendUsingPort = 2
End Enum

Public Sub SendUsingMethod(ByVal eSendUsingMethod As eEDMSMailSendUsing)
.....
.....
End Sub

How can I implement the same thing at C#?

public void SendUsingMethod(...........)
{
......
......
}
 
E

Egbert Nierop \(MVP for IIS\)

Mullin Yu said:
At Vb6, we can do the following, and then call typing SendUsingMethod, it
will pop up SendUsingPickup and SendUsingPort option

Public Enum eEDMSMailSendUsing
SendUsingPickup = 1
SendUsingPort = 2
End Enum

Public Sub SendUsingMethod(ByVal eSendUsingMethod As eEDMSMailSendUsing)
....
....
End Sub

How can I implement the same thing at C#?

public enum eEDMSMailSendUsing
{
SendUsingPickup = 1, //assigning is not necessary
SendUsingPort = 2
}

public void SendUsingMethod(eEDMSMailSendUsing eSendUsingMethod )
{
}
 
M

Mullin Yu

thanks!

Egbert Nierop (MVP for IIS) said:
public enum eEDMSMailSendUsing
{
SendUsingPickup = 1, //assigning is not necessary
SendUsingPort = 2
}

public void SendUsingMethod(eEDMSMailSendUsing eSendUsingMethod )
{
}
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top