Click here to Skip to main content
15,920,438 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
VB
Dim sCode$, sPWT$, nFirma&, nSaveFirma&
           Public Function dvxInit(Optional nFirma&, Optional sCode$, Optional sPWT$) As Boolean


I am in the process of converting a VB Project to C#.I don't understand what are this $ and & symbols. As far I understood $ is for strings and & is for numbers, but I am not sure.
Optional keyword which is also not understood.

What I have tried:
Posted
Updated 4-Mar-19 1:35am
Comments

1 solution

Dim sCode$


in c# is

string sCode;


$ means string, % means int, & means long, # means double. You make params optional in c# by giving them a default value

public bool dvxInit(long nFirma = 0, string sCode = "" ... )
 
Share this answer
 
v2
Comments
Priya Karthish 4-Mar-19 7:59am    
Thank you

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900