Click here to Skip to main content
15,884,237 members
Please Sign up or sign in to vote.
2.33/5 (4 votes)
See more:
Hi,
I have a project which was earlier built in vb6. now i want to convert it to C#.net.
so i want to know is their any tool to convert vb6 project into c#.net project.


Thank you
Posted
Comments
shailendrathakur 30-Oct-14 5:53am    
Public Class UHC
Inherits FormatBase

'
'Author : <ashis kumar="" das="">
'Created Date : <03-03-2010>
'Purpose : <modify geteligibilitydates()="" to="" parse="" eligibility="" dates="" for="" the="" code="" "346"="" and="" "347"="" elig-18232="">
'Function Name : <geteligibilitydates()>
'Modified Date : <03-09-2010>
'Modified Comments : <changes made="" when="" code="" 346="" is="" exists="" only="" then="" there="" a="" exception="" occurs="" due="" to="" length="">
Protected Overrides Function GetEligibilityDates(ByVal arr As List(Of Response.Segment)) As String
Dim seg As Response.Segment
Dim strRetValue As String = ""

''''disable sorting functionality by ashis
'Dim arrQualifiersInOrderOfPreference() As String = {"539", "348", "307", "356", "346"}
'Dim arrSortedByPreference(arr.Count - 1) As Accretive.Services.HIPAA.Eligibility.Response.Segment
'Dim arrayCopyIndex As Integer = 0

''sort arr in the order in which we want to look for specific qualifiers
'For preferenceCounter As Integer = 0 To arrQualifiersInOrderOfPreference.Length - 1
' Dim exiting As Boolean = False
' For sortedArrayCounter As Integer = 0 To arrSortedByPreference.Length - 1
' If CType(arr(sortedArrayCounter), Response.Segment).Fields(1).Value = _
' arrQualifiersInOrderOfPreference(preferenceCounter) Then
' arrSortedByPreference(arrayCopyIndex) = arr(sortedArrayCounter)
' arrayCopyIndex += 1
' If arrayCopyIndex = arrSortedByPreference.Length Then
' exiting = True
' Exit For
' End If
' End If
' Next
' If exiting Then Exit For
'Next

For Each seg In arr 'SortedByPreference
If seg Is Nothing Then
Exit For
End If

'policy start date
If seg.Fields(1).Value = "539" Then
strRetValue = seg.Fields(3).Value
Exit For
End If

'Benefit Begin Date
If seg.Fields(1).Value = "348" Then
strRetValue = seg.Fields(3).Value
Exit For
End If

'eligibility date
If seg.Fields(1).Value = "307" Then
strRetValue = seg.Fields(3).Value
Exit For
End If

'Eligibility Begin
If seg.Fields(1).Value = "356" Then
strRetValue = seg.Fields(3).Value
Exit For
End If

'Plan Begin
If seg.Fields(1).Value = "346" Then
strRetValue = seg.Fields(3).Value & "346"
Exit For
End If

Next

For Each seg In arr
If seg Is Nothing Then
Exit For
End If

''policy end date
'If seg.Fields(1).Value = "540" Then
' strRetValue = seg.Fields(3).Value
' Exit For
'End If

''Benefit End Date
'If seg.Fields(1).Value = "349" Then
' strRetValue = seg.Fields(3).Value
' Exit For
'End If

''Eligibility End
'If seg.Fields(1).Value = "357" Then
' strRetValue = seg.Fields(3).Value
' Exit For
'End If

'Plan End
If seg.Fields(1).Value = "347" An

the following tools may be useful for conversion
Convert VB6 forms to C#[^]
Online Tool
 
Share this answer
 
Check this link

http://converter.telerik.com/[^]
 
Share this answer
 
Yes, you can use online converters[^], but i need to warn you:

  1. you have no guarantee that everything would be work perfect
  2. vb6 is 'old' programming language and does not use .net technologies
  3. c# is case sensitive, vb6 not; some variables could not be initialized correctly
  4. vb6 enables to use global variables; c# not
  5. etc.


Final conclusion: write your application in C# from the beginning to the end by yourself!
 
Share this answer
 
You can find VB to C# code converter online.

But complete project conversion could depends upon your own effort from non oops to oops programming.
 
Share this answer
 

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