We Are GAP Mobilize
Free Assessment Tool

VB to .NET

NOTE #8008

Element xxx is obsolete and should be removed

Description

In this scenario the element xxx is no longer available on the target platform. However it is part of function call, or expression and the statement cannot be removed without user revision. Therefore this note is issued so the user can take proper action.

Note: This line will cause a compilation issue and must be corrected.

 

Sample VB6

In this example the Caption property of an SSPanel has a map that indicates that it will be removed

Private Sub Form_Load()
Dim text As String
Dim SSPanel1 As ThreeD.SSPanel

SSPanel1.Enabled = True

SSPanel1.Caption = ""

text = GetMessage(SSPanel1.Caption)

End Sub

Function GetMessage(text As String)
GetMessage = "Caption is " & text
End Function

Target VB.NET

Private Sub Form_Load()
Dim SSPanel1 As Exact.Win.UI.Panel.Panel

SSPanel1.Enabled = True

'UPGRADE_NOTE: (8008) Element Caption is obsolete and should be removed.
Dim text_Renamed As String = GetMessage(SSPanel1.Caption)

End Sub

'UPGRADE-WARNING: Parameter text was changed from byref to byval.
Function GetMessage(ByVal text_Renamed As String) As String
Return "Caption is " & text_Renamed
End Function

Target C#

private void Form_Load()
{
Exact.Win.UI.Panel.Panel SSPanel1 = null;

SSPanel1.Enabled = true;

//UPGRADE_NOTE: (8008) Element Caption is obsolete and should be removed.
string text = GetMessage(SSPanel1.Caption)
}

//UPGRADE-WARNING: Parameter text was changed from byref to byval.
public string GetMessage(string text)
{
return "Caption is " + text;
}

See also:

Talk To An Engineer