• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint

Reusing Memo Fields

With ColdFusion, you can use a field as many times as you want for display or for if statements; it doesn’t matter. On the other hand, ASP is a little more finicky when it comes to reusing memo-type fields. Suppose that you want to check to see whether a memo-type field in the database is empty, and if it is, you want to display a message to the user. Then later on the same page you want to put the same memo field in another location. You’re gonna get errors, bubba, or no data—depending on what you’re trying to do. When you need to reuse a memo field, the way to get it working is to assign the memo field’s value to a variable, and then call that variable whenever you need it. Take this, for example:

<% Dim myMemoFieldVariable
myMemoFieldVariable = rsMyRecordset.Fields.Item("memMyActualMemoField").value
%>


					  


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint