webtabs

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

webtabs

ching
Hi,

I've been trying out WebTabs and it's truly great. I have this method:

viewMain
        | e |
        e := WebElement new. 
        e addTextH1: 'Web Tabs'.
  e add: (WebTabs new
            selected: 2;
            addLinkTo: self observee
              text: 'Tab 1';
            addLinkTo: self observee
                text: 'Tab 2';
          yourself).

It displays very nicely. I would like to display the text, "Hi, I am tab 1" and "Hi, I am tab 2" when the tabs are clicked. How do I accomplish this? I tried a few things which didn't work.

Thanks in advance.

Ching de la Serna

_______________________________________________
Aida mailing list
[hidden email]
http://lists.aidaweb.si/mailman/listinfo/aida
Reply | Threaded
Open this post in threaded view
|

Re: webtabs

Herbert König
Hi Ching,

CdlS> It displays very nicely. I would like to display the text, "Hi, I am tab 1"
CdlS> and "Hi, I am tab 2" when the tabs are clicked. How do I accomplish this? I
CdlS> tried a few things which didn't work.

I use them this way:

displayTabComponent
        "I display the tabs"

        | e |
        e := WebElement new.
        e := ViewTabs new.
        e addView: #main description: 'Abrechnung'.
        e addView: #kontrollwerte description: 'Kontrollwerte'.
        e addView: #kurvenband description: 'Kurvenband'.
        "and so on"
        ^e

For every addView: description: you need a view method which is named
after the naming convention viewMain which gets called by
addView: #viewMain

so you capitalize (is this English??) the first letter of your symbol
and prepend a view.

For example my viewKontrollwerte looks like:

viewKontrollwerte
        | e |
        e := WebElement new.
        e
                add: self displayTabComponent; "Here I reuse my Tabs"
                addBreak;
                addTextH1: 'Kontrollwerte (DA51) ändern';
                addBreak;
                addText: 'This is your view one';
                addBreak;
                addBreak;
        self pageFrameWideNoNavigationWith: e title: 'REB Elling'

So in general:
every view needs its own Webtabs, so i put it in a method
(#displayTabComponent).


This can be found out in http://www.aidaweb.si/documentation.html
There you go to 'programmers guide' then 'tables'. Actually the whole
docs are worth wile :-))


Cheers,

Herbert                            mailto:[hidden email]

_______________________________________________
Aida mailing list
[hidden email]
http://lists.aidaweb.si/mailman/listinfo/aida