B
BobRoyAce
I have a project that I'm working on in Visual Studio 2010. There are
62 Warnings shown for the project right now. Many of the warnings are
for supposed unused variables. The weird thing about this is that the
variables are not unused. They are very much used. Here's an example:
Dim oForm As New MaintCALegalExpenseForm
oForm.AddEditMode = gci_ADD_EDIT_MODE_EDIT
Dim oOriginalLegalExpense As CALegalExpense =
gvLegalExcpenses.GetFocusedRow
Dim oNewLegalExpense As New CALegalExpense
oNewLegalExpense = oOriginalLegalExpense.CloneMe(True)
oForm.CurrentLegalExpense = oNewLegalExpense
If (oForm.ShowDialog = DialogResult.OK) Then
_TheCA.LegalExpenses.ReplaceCALegalExpense(oForm.CurrentLegalExpense)
End If
Visual Studio tells me that the variable oForm, declared in the first
line of code above, is an unused local variable. Is this a known issue
with VS 2010 or am I missing something?
62 Warnings shown for the project right now. Many of the warnings are
for supposed unused variables. The weird thing about this is that the
variables are not unused. They are very much used. Here's an example:
Dim oForm As New MaintCALegalExpenseForm
oForm.AddEditMode = gci_ADD_EDIT_MODE_EDIT
Dim oOriginalLegalExpense As CALegalExpense =
gvLegalExcpenses.GetFocusedRow
Dim oNewLegalExpense As New CALegalExpense
oNewLegalExpense = oOriginalLegalExpense.CloneMe(True)
oForm.CurrentLegalExpense = oNewLegalExpense
If (oForm.ShowDialog = DialogResult.OK) Then
_TheCA.LegalExpenses.ReplaceCALegalExpense(oForm.CurrentLegalExpense)
End If
Visual Studio tells me that the variable oForm, declared in the first
line of code above, is an unused local variable. Is this a known issue
with VS 2010 or am I missing something?