[REBORN !] TableView Extension Versions 3&4 (pre nb191) and 5 by @Ken

Try this, using Tableviewer extension.
TVTemplate.aia (18.2 KB)

These should be all the blocks you need....

image

The behavior is exactly what I was looking for. now I have to figure out how to lock the header at the top and how to select the rows (I saw that you can also select single cells). I'll work on it now. Thank you very much

In any case, the proposal for Ken to make version 5 is still valid.

  1. Flag to block headers on top directly in settings
  2. adapt the width of the columns to the longest string between values and headers (perhaps already included in the first one)
  3. possibility of highlighting the single cell

all can be done by tableviewer.

This is already in the blocks I provided

1 Like

Awesome Thank you

You might be better off using YAML for your table displays.

Se

I've read it but my problem is not the data, I use MSSQL queries through PHP and it's super fast even with a huge amount of data like that of an ERP. The problem is simply the display of this data, indeed simply the formatting of the table. thanks anyway for the advice, now I know one more thing.

Could you please share how to connect App Inventor with a MSSQL database? Which blocks do you use? How does your php script look like? You could use the following thread for that

Thank you in advance

Taifun

I have a problem with the TableView v4 extension.

Is there a solution for this?

Frank

Runtime error:
java.lang.NoSuchMethodError: No static method setFontTypeface(Landroid/widget/TextView;IZZ)V in class Lcom/google/appinventor/components/runtime/util/TextViewUtil; or its super classes (declaration of 'com.google.appinventor.components.runtime.util.TextViewUtil' appears in base.apk)
Note: You will not see another error reported for 5 seconds.

Are you attempting to change the font ?

There is no option for this, other than the built-in fonts

Is this related to your other problem with companion and emulator ?

This is a 2nd issue independent of Companion and Emulator.

I used this sample file, created an apk and got the runtime error.

TableView_v4.aia (24.4 KB)

Try this

TableView_v4_revised.aia (24.4 KB)

I changed all your /n to \n to provide correct csv format.

Works fine for me, companion and compiled

Thank you, my mistake.

Frank

@TIMAI2

The apk file works if I create your aia file using http://ai2.appinventor.mit.edu.

If I use https://ai2-test.appinventor.mit.edu/ to create the file, the error message comes up:

Runtime error:
No static method setFontTypeface(Landroid/widget/TextView;IZZ)V in class Lcom/google/appinventor/components/runtime/util/TextViewUtil; or its super classes (declaration of 'com.google.appinventor.components.runtime.util.TextViewUtil' appears in /data/app/ ...

A test with Companion or USB is not possible for reasons you know (see above)

Frank

This may be due to the new font functionality in the upcoming nb191 ? Will be a shame if it is.

It may be possible to add the same functionality to the extension if @Ken approves, or to remove the font option from the extension.

1 Like

Easier to just take it out ?

@TIMAI2
Since I use the TableView extension in several programs, this is very time-consuming.
In addition, I have not yet found an extension that corresponds to TableView in terms of scope.

@KEN
Would it be possible for you to adapt the extension?
That would be very very nice of you.

With the new nb191, the error message now occurs constantly.
Future newer versions of my programs will no longer run.

Greeting Frank

I can't make any promises, but I am looking into it.

Hi @Frank-HRO Maybe you want to use another extension to show a table,if you know some basic CSS.

Since the new nb191 version, the created apk version no longer works either.
Error message see above.
Using the extension TableViewer does not bring this error.
Since I have many scripts with the TableView extension, the conversion is very time-consuming.

I hope @Ken finds the time to fix the bug.

Frank