I want to change the number of characters displayed

I made list from database.
Each character is different.
So I want to change the nuber of characters displayed.

Please tell me the way or the support page or something.
Thank you

Please tell the way.

Hi,
I’m not sure that I fully understand what is the use case.
Can you please clarify what you would like to achieve? Moreover, adding screenshots can be useful too.

Thanks,
Tal.

Hell Tal
Thanks.
I want to change the displayed text length.

And when click the button, appear all words.
Like this one.

Hi,

Please refer to the below example.

The solution is to basically expand/collapse different text boxes.

Hi Ido Inbar thanks your answer.
I don’t want to collapse.
Just I want to decide the number of characters to be displayed.
when click “read more” the other page open and read all.
Like a blog elements.

Hi nanami,
Do you want to have max.length with your text??

Hi Heson Li
that’s right!
Do you konow blog elements?
The elements can set up text length.
and, when click “read more” Remaining characters appear at new page like blog page.
I want to do like this.

Hi again,
I post a solution for this question, since it maybe a common question. : )

View the post,

Henson Li thanks your kind!
I try it like this, but it’s not work, please tell me again. where I’m wrong,

$w.onReady( function () {
$w(“#repeater1”).data = $w(“#dataset2”).getCurrentItem();
$w(“#repeater1”).onItemReady(($w, itemData, Index) => {
//itemData.title refer to database’s field…
let repeaterTitle = “link-carinfoform-title”;
//substr(0first character, 40maximum character number you want)
var repeaterTitleMaxLength = repeaterTitle.substr(0, 40);
$w(“#text32”).text = repeaterTitleMaxLength;
});
});

Hi,
You need to replace property with your page element and it works with repeater.
Do you use repeater?

If you use “link-carinfoform-title”, all of your repeaterItem’s title may change to link-carinfoform-title.

Moreover, element you want to have maxLength cannot collect with any database.

Hi HensoLi,
I’m sorry so many question.

I use repeater.

I can’t understand the mean

//itemData.title refer to database’s field…
let repeaterTitle = itemData.title;

database’s field is this image one?

Or somewhere other repeaterTitle?