G
Guest
I am storing an array which contains about a dozen chracter items to a
Session variable. Later, I need to use this array so I am doing the
following:
Dim eventTypes As String() = DirectCast(Session("EventTypes"), String())
If Date.Today <= closeDate Then
If eventTypes(cblEntries.SelectedIndex) = "J" Then thisFee =
Session("JRFee") Else thisFee = Session("PEFee")
Else
If eventTypes(cblEntries.SelectedIndex) = "J" Then thisFee =
Session("JRFee") Else thisFee = Session("DOSFee")
End If
I have determined that the values are properly being stored into the initial
array. I then assign a session variable to store this array. When I try to
use the array in the segment above, I get the error "Object reference not set
to an instance of an object - use the "new keyword".
Obviously when I dim the eventTypes() something is wrong here. Please help.
Thanks for the information.
Session variable. Later, I need to use this array so I am doing the
following:
Dim eventTypes As String() = DirectCast(Session("EventTypes"), String())
If Date.Today <= closeDate Then
If eventTypes(cblEntries.SelectedIndex) = "J" Then thisFee =
Session("JRFee") Else thisFee = Session("PEFee")
Else
If eventTypes(cblEntries.SelectedIndex) = "J" Then thisFee =
Session("JRFee") Else thisFee = Session("DOSFee")
End If
I have determined that the values are properly being stored into the initial
array. I then assign a session variable to store this array. When I try to
use the array in the segment above, I get the error "Object reference not set
to an instance of an object - use the "new keyword".
Obviously when I dim the eventTypes() something is wrong here. Please help.
Thanks for the information.