PDA

Click to See Complete Forum and Search --> : Display "TEXT" type field in VB


judy
Feb 1st, 2000, 10:51 PM
I use ADO to get a recordset that is returned from SQL store procedure.
I can display all of the fields value in the
recordset but I got "Runtime Error" when I try to display the "TEXT" type field.
Here is the one line code that generates the error :

txtMemo.Text = rsep("EpisodeMemo")

in recordset all the text field is not empty.

Why this happen?
Thanks advanced.

judy
Feb 2nd, 2000, 04:40 AM
Thanks. I just found out that I should set the recordset cursor type to "adOpenKeyset" not "adforwardonly".

bsmith
Feb 2nd, 2000, 11:37 AM
What type of runtime error are you getting?

VBfreak
Feb 2nd, 2000, 11:56 AM
It is because of the reference that you are making. I think your code should be something like that.

txtMemo.text = rsep("EpisodeMemo").value

That will put the field value in the text propertie instead of trying to assign the field reference to a the text property of the box.

Good luck