T
Tarun Mistry
Hello everyone, I am using the data reader to access the information within
a results set and then pass this information onto the constructor of my
classes.
Im using the following syntax to access the information:
dataReader["my_field"].ToString()
This is fine, however it simple will not play ball if i need the value in
integer format, I have to declare a string variable manually, cast the data
to string, then into an integer and then send this to my constructor.
Is there a quick and easy method to cast it into an integer within my
constructor call?
Many thanks,
Taz
a results set and then pass this information onto the constructor of my
classes.
Im using the following syntax to access the information:
dataReader["my_field"].ToString()
This is fine, however it simple will not play ball if i need the value in
integer format, I have to declare a string variable manually, cast the data
to string, then into an integer and then send this to my constructor.
Is there a quick and easy method to cast it into an integer within my
constructor call?
Many thanks,
Taz