Android Question How to hide empty row (from database) in BBCodeview

omo

Active Member
Licensed User
Longtime User
One of the great features of bbcodeview is its dynamism in content adaptation; whenever it is visible, text is drawn while content is removed when it becomes invisible. However, when text drawn from database is empty, bbcodeview seems to create empty row space for each empty database row as demonstrated below in the attached picture. Is there any function in bbcodeview that can be set by programmers to hide or collapse such empty left behind by bbcodeview similar to what we have in b4xtable.. I purposely put "dot" in each empty row/column in mysql database for all to see, all those dots are empty spaces drawn by bbcodeview. Setting SQL queries using null or "" can not alter this empty rows, it should be from bbcodeview internal text engine
emptycolbbcodeview.png


How can these empty rows represented in dots be hidden/removed or collapsed? Each record is separated with empty space, next records are under as indicated by downward arrow
 
Last edited:

omo

Active Member
Licensed User
Longtime User
BBCodeView takes a string and shows it.
Yes, you are right, but also takes empty string and shows it as empty space instead of hiding it as demonstrated earlier. I will prefer if it can hide empty space and shows string only if available due to it's elastic and dynamic nature.

On normal bbcodeview operation, text is only drawn when it becomes visible and is removed when it becomes invisible while its empty space/gap left behind by removing text is quickly filled up, so, I expected it to fill or close empty space/gap drawn on it from database since data/texts are not available for those columns yet.

You need to check why there are empty lines in the string that you create
I purposely left empty columns in the database so it can be filled later in the course of programming when the data for those columns are available to update the empty columns, but the variables for these empty columns need to be represented in bbcodeview till data is available to update them at run time.

I have used bbcodeview in some projects which worked well by closing empty spaces for unavailable text in the midst of multiple texts till they are available and adjust automatically to accommodate the text. But I just discovered the situation I described above in another project I want to handle especially if empty string is directly from database as pictured in the previous submission
 
Last edited:
Upvote 0

omo

Active Member
Licensed User
Longtime User
There is no reason that BBCodeView will hide empty lines. Don't add the empty lines if you don't want them to show.
Ok, Erel, no problem. I will stick to my Plan B to address the issue at hand, but will not be perfect as I expected from Bbcodeview because of flexibility in loading other multimedia contents and custom views. I will also try to redefine my programming logic around Bbcodeview, but if it can't fit this my programming situation, I will use my Plan B. Thank you so much, Erel, I appreciate
 
Upvote 0

omo

Active Member
Licensed User
Longtime User
There is no reason that BBCodeView will hide empty lines. Don't add the empty lines if you don't want them to show.
Whaoo! Thank you Erel. I have eliminated those empty lines programmatically. What I did was to setup extra column to serve as look-up table and thereby programmatically eliminate the empty lines. No need for me to use my plan B since Bbcodeview is my number one choice for present task. God bless you more and B4A community
Regards
 
Upvote 0
Top