How to rename a Tab on a Tabpanel


how can i rename the title of a tab?

I only see the title in the tab editor but i want to use different titles depending on the user localization.

This code does not work:

TabPanel1.caption(0) = "Customers"

MainPage.TabPanel1.Shown, line 1
Type “WebTabPanel” has no member named “caption”
TabPanel1.caption(0) = “Customers”


You can do it on the IDE:

  1. Define a localised string constant name it kConstantName (Insert Constant & Type: String, Switch localised to true)
  2. Use your constant in your Panel (Panels, Edit, Enter #kConstantName)

By using # in the IDE the value of your constant will be displayed In user locale language. It’s work for Panels, Labels…

Other alternative:

You can set manually caption:

TabPanel1.CaptionAt(0) = “Customers”

Hi Sebastien,

i already use localized string constants in my project, but for tabs this seems not to work:

– localized string constants

2020-12-02 13_36_47-Window

– tab editor

2020-12-02 13_37_13-Window

– browser output

2020-12-02 13_38_57-Window

Any idea, whats wrong?


App.#k_customer ?
or #App.k_customer I don’t remember

anyway better put all constants in a module

TabPanel1.CationAT(0) = "Customers" results in this error:

MainPage.Opening, line 1
Type “WebTabPanel” has no member named “CaptionAt”
TabPanel1.CaptionAt(0) = “Customers”

this only works in my desktop apps.

1 Like

App.k_customers (no #) works in a normal String-Output e.g within a MessageBox:

MessageBox(App.k_database + " " + App.k_connected)

but on a control e.g. a button i have to use #App.k_search for the caption.

Why sometimes (e.g. normal string output) without # and sometimes (e.g. button control) with #?

Furthermore when i set the caption of a button like this #App.k_search, the button is blank within the IDE but works fine when running my project in the browser.

Quite inconsistent.


1 Like

in the navigator of the IDE, it’s always #
in a method or any code, it’s always without the #
it’s consistent enough for me ?

Thanks all for your contributions, but this is not an answer to my initial question. You cannot use localized string constants on a TabPanel in Web2. Not in code and not in the IDE (Panel Editor).

1 Like

you should file a bug request in this case.

1 Like