Android Question xClv with BBCodeView Text Having Characters Used as Tags in BCTextEngine

Mahares

Expert
Licensed User
Longtime User
I extract data from a SQLite table and populate a BBCodeView in an xClv. But when the text data contains [ or ], it crashes because it mistakes them for malformed BCTextEngine tags. Example of a text string: BBC Sessions [Disc 1] [Live]. I used the replace function to replace [ with ( and ] with ) as in : s=s.Replace("[", "(").Replace("]", ")").
It works of course, but I was wondering if there is a way to do it perhaps with smart string literals or other means without changing the data
 

Mahares

Expert
Licensed User
Longtime User
Tip: BBCodeView shouldn't be embedded in xCLV.
The project involves using an xClv with expandableCLV feature. The data is populated from a SQLite table. One of the columns is displayed as BBCodeView on the expanded part. When I click on an artist, a list of his/her albums display. The item layout consists of a panel holding a label and a BBCodeView ( see snapshot) . I have used a label instead of a BBCodeView in another project but in this one, I wanted to see how BBCodeView behaves as part of the item layout. I tried BBListItem instead of BBCodeView but could not get it to show more than one album for a given artist.
 

Attachments

  • itembbcodeview.PNG
    itembbcodeview.PNG
    12.9 KB · Views: 130
  • xClvExpandedListWithBBCodeView.png
    xClvExpandedListWithBBCodeView.png
    21.6 KB · Views: 134
Upvote 0

Mahares

Expert
Licensed User
Longtime User
Tip: BBCodeView shouldn't be embedded in xCLV.
Are you saying you should not put a BBCodeView as a customview in an item layout when dealing with an xClv. If so, where do you put it and how do you populate it with a SQLite table data in this case
 
Upvote 0
Top