Hi,

The XML of the mainframe container looks like this:

<mainframe title="My product name">
  <events>
    <keyEvents>
      <keyEvent action="save" keyCombination="F10"/>
      <keyEvent action="query" keyCombination="F8"/>
    </keyEvents>
  </events>
  <borderLayout>
    <cell docking="Center" name="centerCell"/>
  </borderLayout>
</mainframe>

Now i want to change the title in the postOpen event so it shows (for example) the name of the current user. I would expect this procedure:

api_frame.setTitle ( 'mainframe ', 'my new title');

But that does not work: the error message shows "frame mainframe does not exist".

So, i try to add the name-tag to the mainframe definition:

<mainframe name="myMainFrame" title="blabla">

But then i get the error that the name-tag is not allowed for mainframe.

Is there a solution for this?

Kind regards, Jan Willem

asked 23 Oct '15, 05:13

Jan%20Willem%20Vermeer's gravatar image

Jan Willem V...
1231330
accept rate: 0%


Hi Jan Willem,

Please right click the object you want to rename in the IDE. In the popupmenu click Rename. Enter the new name for the mainFrame.

Rename works the same way pretty much with every object.

Kind Regards, Yalim

link

answered 23 Oct '15, 05:32

Yalim%20Gerger's gravatar image

Yalim Gerger ♦♦
1.8k5
accept rate: 15%

Hi Jan Willem,

The default name for mainFrame of the application is "mainFrame", therefore if you didn't change its name, you can use the code below:

api_frame.setTitle ( 'mainFrame', 'my new title');

Hope this helps,
Ibrahim

link

answered 23 Oct '15, 05:33

Ibrahim%20Sandalli's gravatar image

Ibrahim Sand... ♦♦
1.5k5
accept rate: 25%

Hi Ibrahim,

i did not change the name: alt text

And when i do this:

api_frame.setTitle ( 'mainFrame ', 'my new title');

I get this error message:

alt text

What do i do wrong?

Kind regards, Jan Willem

link

answered 23 Oct '15, 05:39

Jan%20Willem%20Vermeer's gravatar image

Jan Willem V...
1231330
accept rate: 0%

Oh dear,

&^$&^@&(!)(!@&($#^&!)!+)(#&@&()!*)_!

I see the error now...

There is a space behind mainFrame. It should be 'mainFrame' and not 'mainFrame '.

Pffff. Sorry to bother you. It works perfectly now.

Kind regards, Jan Willem

link

answered 23 Oct '15, 05:41

Jan%20Willem%20Vermeer's gravatar image

Jan Willem V...
1231330
accept rate: 0%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×3
×3

Asked: 23 Oct '15, 05:13

Seen: 782 times

Last updated: 23 Oct '15, 05:41


© Copyright Gerger 2017