Af:showOneTab : adding tabs dynamically
Morning,
I'm trying to add tabs to my af:showOneTab dynamically.
So I added a HashMap in my backing bean and I created CoreShowDetailItem items that i add into my Map.
Then on my jspx page I'm trying a af:forEach like this :
<af:showOneTab position="above">
<af:forEach var="tab" items="#{tabsBean.tabs}">
<af:showDetailItem text="#{tab.text}"/>
</af:forEach>
</af:showOneTab>
But JDeveloper says me that forEach can't be the parent tag of CoreShowDetailItem.
Is there another solution to perform what I'm trying to do?
Thanks in advance for your help!
Hi,
in fact this is the case and the visual designer would have told you so (and the source code editor should give wranings, so I don't know if it does).
Here's a code from a managed bean that does it instead
public class ShowDetailBean {
private CoreShowOneTab tabs;
public ShowDetailBean() {
public void setTabs(CoreShowOneTab tabs) {
this.tabs = tabs;
public CoreShowOneTab getTabs() {
return tabs;
public String commandButton_action() {
CoreShowDetailItem csd = new CoreShowDetailItem();
csd.setText("Hello");
tabs.getChildren().add(csd);
return null;
}In this example I built a Binding reference from teh ShowOneTab component to the managed bean. On button press a new tab is created
Frank
Similar Messages
-
Adding tabs dynamically at runtime for a tab navigator control
Hi,
Is it possible in flex builder 2 to dynamically add the tabs
at runtime to the tab navigator control, if we can add plz tell the
procedure to do that
thanks in advanceGiven that you had a tab navigator declared in mxml like
this:
<mx:TabNavigator id="myTabber" selectedIndex="0">
</mx:TabNavigator>
you should just be able to call the addChild method, passing
the child tab containers. So for example, in some ActionScript
event handler:
var newTab:Canvas = new Canvas();
myTabber.addChild(newTab);
bear in mind I haven't done this by adding tabs, but have
done tons with adding controls to an application at runtime using
this method (DataGrids, Grid, GridItems, etc...)
Jason -
TabNavigator: Adding Tab Dynamic
Hi,
I would like to create an application that is using a
TabNavigator to show different information (tabs) when user press
different buttons. I create a button and call a function to add a
tab into tabnavigator to show a custom control (base on Panel). I
try it and the program can add the tab and show the correct
information. But I don't know how to add the label on the created
tab. Also, can it be any simple method to check it the information
is shown already in tabnavigator?
The function is listed below:
private function addUserRequest():void {
var ur:DisplayObject = tabControl.addChild(new userRequest);
var tabNdx:int; // Tab Index
tabNdx = tabControl.getChildIndex(ur);
tabControl.selectedIndex = tabControl.getChildIndex(ur);
return;
//end of function
Thanks a lot!
WilsonIf
UserRequest is a custom component which extends
Panel, the label of the panel will be used as the label of
the tab when it's added to the
TabNavigator.
In order to do this you'll need to define
ur as a compatible type which has a label property, i.e. as
a
Panel or as a
UserRequest (or whatever it's called):
var ur:Panel = new UserRequest(); // UserRequest is subclass
of Panel so compatible.
ur.label = "A Label"; // I can set this because I am a panel
tabControl.addChild(ur);
I'm not sure I understand your last question. Do you want to
know if the tab with that label already exists? -
Adding and removing tabs dynamically as in explorer
adding and removing tabs dynamically as in explorer or firefox
Think about how many translations are required to move your avatar, then think how many translations are required to move everything else in the entire world. Depending on whether there is more to translate in your avatar or in the rest of the world, you have your solution.
Not knowing how your system works I can't really suggest anything further but could the collision avoidance be interacting with everything in the world as well? That would increase the workload somewhat. -
Hi ,
I am using TabStrip control of PDK .NET. I want to add tab dynamically in tabstrip control.
But I am getting error for any postback when I switch in between tabs.
Error description is :
<b>"Index was out of range. Must be non-negative and less than the size of the collection. Parameter name: index"</b>
<b>Stack Trace:
[ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index]
System.Collections.CollectionBase.System.Collections.IList.get_Item(Int32 index) +2382545
SAP.Web.UI.Controls.TabCollection.get_Item(Int32 index) +6
SAP.Web.UI.Controls.TabStrip.LoadPostData(String sPostData, NameValueCollection oPostCollection) +92
System.Web.UI.Page.ProcessPostData(NameValueCollection postData, Boolean fBeforeLoad) +674
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2965</b>
Any help appreciated?
Regards,
PrashantHi Prashant,,
your index is less than zero, the postback will not store it unless you explicitly save it using 'enable view state' for the tree control, if it is already enabled and still not working: here is the work around :-
you can store it in a hidden input field, so that it can be retrived when you do a postback, and then reassign the current index
it should be a relatively simple fix
please let me know how you get along...
with respect,
amit -
Hiding a Tab Dynamically in FPM
Hi,
Can you please let me know how to hide the tab dynamically in FPM. I tried to implement the interface IF_FPM_TABBED_CONF_EXIT in the SAP standard webdynpro, but I get a error " Web Dynpro comp./intf. "IF_FPM_TABBED_CONF_EXIT already exists". Even though I get this message I am not able to find the interface IF_FPM_TABBED_CONF_EXIT in the implemented list of interface.
Regards,
ArunHi Aliaksandr,
Thanks for the reply.
Actually I am not able to implement the interface controller IF_FPM_TABBED_CONF_EXIT in the SAP standard webdynpro, I get an error " Web Dynpro comp./intf. "IF_FPM_TABBED_CONF_EXIT already exists".
Even though I get this message I am not able to find the interface IF_FPM_TABBED_CONF_EXIT in the implemented list of interface.
Regards,
Arun -
Hi all
I have a requirement of adding the columns to a Classic Table at run time.. the number of columns are not fixed. the number of The data in there columns will be dispaled from the view initialized at run time.
I tried searching out threads on adding column dynamically but didtn get one..
pls help me out ..
naveenOf course you can add columns dynamically, but this always needs to be from the same VO, a OA table cannot be based on more than one VO.
So if it all the columns are from the same VO, why take the pain of adding and removing columns, why not just either render it or hide it.
Thanks
Tapash -
WHY IS THE JUST ADDED TAB STILL NOT ON iTUNES!!???
Okay so alot of people including myself are wondering why the just added tab in itunes keeps disappearing. I don't understand it because that is where I find most of my music that are new and coming in for that week. I don't understand why they simply just can't put it back on there and let people use it! It's bad enough that we have to pay 1.29 per song when I remember it being that I could have gotten 15 songs worth 15 dollars at .99 cents per song. Nowadays I can get like 11 or 12!!!! YOU GUYS NEED TO SERIOUSLY FIX IT!!!!!!!!!!!!!
yes it is working for the majority there are a small number of customers who are having problems
If you want to say thanks for a helpful answer,please click on the Ratings star on the left-hand side If the reply answers your question then please mark as ’Mark as Accepted Solution’ -
Adding Tab page in to Item Master Data
Dear,
In this momento I can do application external through SDK to SBO. but How can I do adding Tab Tag Page in to Item Master Data,
Can you explain me How I do?
Very thanks.
RegardsHi!
You need add one tabPage in Item Form rigth?
You can used the function:
public void AddTab(string formID, string tabName, string tabNum, string tabCaption)
try
Form oForm = oApp.Forms.GetForm(formID, 0);
Item oItPosition = oForm.Items.Item(tabNum);
Item oItTbTest = oForm.Items.Add(tabName, BoFormItemTypes.it_FOLDER);
oItTbTest.Top = oItPosition.Top;
oItTbTest.Height = oItPosition.Height;
oItTbTest.Width = oItPosition.Width;
oItTbTest.Left = (oItPosition.Left + oItPosition.Width) + 20;
oItTbTest.AffectsFormMode = true;
Folder oTbTest = (Folder)oItTbTest.Specific;
oTbTest.Caption = tabCaption;
oTbTest.ValOff = "0";
oTbTest.ValOn = "1";
oTbTest.GroupWith(tabNum);
catch (Exception e)
oApp.StatusBar.SetText(e.Message, BoMessageTime.bmt_Medium, BoStatusBarMessageType.smt_Error); -
JTabbedPane - not selecting newly added tabs
Is there a way to make it so that newly added tabs in a JTabbedPane are not automatically selected as they are added?
Thanks,
AdamI don't understand what you mean! It's just the normal behavior addTab and insertTab have! So what do you mean? insertTab remembers the currently selected tab and after adding the new tab tries selecting that one again. Maybe you select the new component after adding it.
--Rasta -
Removal and adding tabs in user interface
Hi,can anybody provide me solution for customizing the user interface page menu tabs in SUN Identity Manager.
My requirement is,i need to remove and add main menu and sub menus in the user interface page in SUN Identity Manager.
Thanks in advance.
Edited by: SUNIDMDEV on Feb 21, 2008 10:52 PMHello,
Article Master and Material Master are one and the same in context (materials are referred as Articles in SAP IS Retail). Please refer the below link for creating the custom fields/adding tab pages
adding custom tab in material master transaction
Hope this helps
Regards
Shiva -
Hi Experts,
I have added some tabs at the header for Order,Order from Template and Order Template. Problem I am facing is when I am clicking on those tabs it is working fine everywhere except when I am in catalog page.
Has anybody faced the similar issue. Please advice on this.
Thanks in anticipation.
Regards
Harshmeet SinghHi,
I have added tabs for Order,Order from template and OrderTemplate in header.jsp which are in the form of links in welcome.jsp. I am not able to go back to any of the pages from catalog page. It is giving an error at the bottom of the page saying location is null or not an object.But the same links are working if I am in any other part of the web shop.
@Arshi
Thanks for your input. Will work on it and will let you know if I still face any issues. -
My recently added tabs are restored only partially after restarting Firefox 4
I changed the following
browser.sessionstore.max_tabs_undo;50
browser.sessionstore.max_windows_undo;12
At some point after that in the following sequence:
1. most of recently added tabs and some windows didn't restore after Firefox restart
2. some recently deleted tabs disappeared from "recently closed tabs" in history
3. ''recently closed windows'' in history disappeared
Have anybody changed this and got similar problems? Imho, it's history storage related.Are you running Firefox in "Permanent Private Browsing" mode?
You enter Private Browsing mode if you select: Tools > Options > Privacy > History: Firefox will: "Never Remember History"<br />
To see all History and Cookie settings, choose: Tools > Options > Privacy, choose the setting <b>Firefox will: Use custom settings for history</b>
* Uncheck: [ ] "Permanent Private Browsing mode"
It is also possible that there is a problem with the files [http://kb.mozillazine.org/sessionstore.js sessionstore.js] and sessionstore.bak in the [http://kb.mozillazine.org/Profile_folder_-_Firefox Profile Folder]
Delete [http://kb.mozillazine.org/sessionstore.js sessionstore.js] and sessionstore.bak in the [http://kb.mozillazine.org/Profile_folder_-_Firefox Profile Folder]
* Help > Troubleshooting Information > Profile Directory: Open Containing Folder
If you see files sessionstore-##.js with a number in the left part of the name like sessionstore-1.js then delete those as well.
Deleting sessionstore.js will cause App Tabs and Tab Groups to get lost, so you will have to create them again (make a note).
See:
* http://kb.mozillazine.org/Session_Restore -
Portal Tabs - Dynamic Hide/Display
Hello:
We have a Portal Page Group with multiple TABS. We like to be able to display/hide (or enable/disable) tabs based on the Portal Roles assigned to the current user.
Is it possible to Hide/Display tabs dynamically based on certain conditions? What is the best way to enforce this without creating multiple page groups?
ThanksThe only way I know to conditionally hide/show tabs is to grant access on each tab to one or more groups. The tab will then only be displayed on the page to logged-in user that is a member of a designated group for that tab. (Portal admins will be able to see all the tabs.) If there's another way to hide/show tabs based on other criteria - I'd like to know too! :-)
-
Hi All,
I have a requirement to change my tabs dynamically inside my view for different scenarios.For this, i have binded selectedTab property of tabstrip to some context attribute and then i am setting this attribute with Id's of my tabs depending upon the scenario.But this is not working and always first tab is shown by default.I tried to debug the value af the attribute and it is getting set by different Id's.Can anyone help me in this regard.This is very urgent.
P.S rewar points will be awarded if issue is resolved
Thanks
Amit Bagatihi amit this is what you must be following......
for testing purpose, initially in the wddoinit method provide the second or any other tab id ( in capital letters ) to the context and check what happens.
if it works fine then your logic is differing in some place that by default the tab1 id is sent to the context.
---regards,
alex b justin
Maybe you are looking for
-
I am trying to open files with Photoshop and I get an error message Could not complete your request because of a program error. I have tried to open inmany directions still I get this notice Could not complete your request because of a program error.
-
Just getting started - coupla newbie questions
Please bear with me, I'm new to IM and iChat. I may be jumping the gun a bit here, but I just wanted to ask a few very basic questions: 1) iChat is 'compatible' with AOL/AIM. I have a .mac account. If I use this as my IM account does it mean that I c
-
Abap Proxy Server acknowledgment
Hi All, i have a scenerion Externat -> PI -> R/3 (Asynch) The receiver of message is abap proxy. My question is: how to send acknowledgment from R/3 after commit work to at least PI ?? Regards Maciej
-
TransactionStateChanged gives wrong value when validation error.
In my navbar, wich extends the standard one I extended the transactionStateChanged method. It seems to work and when the transaction goes dirty I receive a true state; when transaction returns clean I receive false. However if a validation fails duri
-
IPod Playcounts in Manual Mode
I used to use auto-update for my iPod, meaning when I plugged it into my computer to run iTunes it would automatically transfer music. It would transfer the playcount from my iPod automatically, as well. Now, however, my music collection has grown be