do i have to create smartgwt tab pane each time? - gwt

I have a constant pane for a tab which is VLayout (lets say 'Layout-A').
Since it takes time to create this layout each time, i create only once.
A Tab (lets say "Tab-A") displays this Vlayout. But it is closable.
When tab is opened for the first time, it is ok. I can see Layout-A.
But when i close and reopen this tab, i create Tab-A using 'new' and set its pane to Layout-A. Tab is empty.
Do i have to create my Layout-A each time when i open the Tab-A?
Thanks...

I didn't find the source (just a comment), but I know that in the past I did some testing on that and I was playing with
theTabSet.updateTab(indexOfTheTabToRemove, null); You can look with the console and on the elements which are destroyed.
Look at the javadoc of removeTabmethod.
So we have to set the pane to null, remove the tab which will not destroyed the pane you want to use and you will be able to reattribute to the tab when you want it.
There is one link talking about this case..... (look at the end of the post)

Related

Attaching an ActiveX TreeView Control into a tabbed Access form

I have a tabbed form in Access and on one tab, I'd like to create an ActiveX TreeView object. When I go to build this object and drag it to the tab, it attaches itself to the general form instead of the tab. This puts the control over top of all the tabs instead of the tab I want it in.
How do I attach the ActiveX control to the tab and not the entire form?
I've done a number of different "moves" to try and get it to attach and I've looked through the options to see if there is an easy way to attach it but nothing actually defines how the control is attached unlike a normal Access form control that is contained in the tab.
I would like to keep the extra forms to a minimum and maintain a single, tabbed form with separate controls on each tab.
Answer:
Make sure to select the tab first and then create the TreeView control. TreeView controls cannot be attached to a tab page by drag/drop.
If done correctly, the control will be placed on the tab page just under the tab name within the borders of the tab page. A quick test by selecting other tabs can be done to check that it attached to the right tab and only that tab.

Is there any event on Click of OK button in Properties Window

I am using this EA_OnNotifyContextItemModified method for tracing the changes in the properties window of an element in EA.
I need to know is there any event on click of “OK/Cancel/Apply” buttons in the properties window of EA.
As shown in the image, i need to know is there any event that will be called particularly on click of "OK/Cancel/Apply" buttons of that window
It's either EA_OnPostNewElement if the element has been created newly or EA_OnNotifyContextItemModified if you have modified an existing element.
Btw. you find both in the help in this chapter and this one.

Predefined Add Dialog not working as expected in Lightswitch 2012

I've created a query to use in an AutoCompleteBox and it works as expected when the user select the AutoCompleteBox in the grid as shown in the picture below
However if the user click the plus button to add a new record using the predefined Add Dialog then the query and the AutoCompleteBox's format doesn't work as shown in the picture below
Why is this happening and how I can fix that?
Thanks
I haven't yet found a way to edit the default Add New dialog.
Instead, make a new screen, select the "New Data Screen" template, and link it to your entity data. You can customize the screen to fit your needs, even make it a Modal Window by changing the Control Type in the screen properties. Once you have the screen set up the way you want, go back to your grid screen, and double click on the Add... command in the Command Bar of your grid, to edit the AddAndEditNew_Execute code. In that method, call your custom screen.
So, as I got to thinking about this some more, I came back to the thought I had when I tried to do this a few months ago. There has to be a better way, so I Googled it again.
This time, I found something. He's using an old version of Lightswitch, but I've successfully applied his technique in my application built in Lightswitch 2012.
http://www.c-sharpcorner.com/UploadFile/051e29/modal-window-in-editable-grid-screen-in-lightswitch-2011/

Open "Modal" Widow and close in TabGroup Based Application

Should Also have specified, I am developing this using Titanium Mobile.
I have a tabbed application. I have the need to open a "modal" like window for the purpose of allowing the user to enter some settings.
For example, you click the 3rd tab in the tabGroup. Some logic runs to see if a setting is set before continuing to create the view. The setting is not in place, so a new window animates in asking you to create this setting. After you create the setting, it closes and the view continues to render, or refreshes.
I cannot for the life of me figure this out. I have created the window, animated it into the current tab, and I have even successfully closed it. Getting the view to refresh or re-load is what is difficult. Also, the navigation bar offers the user the ability to navigate back to the window to change the setting, which I also do not want.
Any way to accomplish this?
I have the same need for logging the user into the application.
Use this code:
windowbject.open({modal:true});
This will only works in iOS.
And you want to refresh view which is behind this modal window then you have to add "focus" eventlistener to the window and write code in it.This code will execute when ever window got focus.
So when you close "modal" view then window behind it will get focus.
I hope this will help you.

how to show up the perspective button without click?

I have two perspectives , but to see the second perspective , as you know have to click button 'open perspective'.
Is there way that the second perspective button shown up automatically , when application start up?
This is an old topic, but I thought I would offer a more concrete answer since the accepted one is not the most direct in getting to a solution.
In your ApplicationWorkbenchWindowAdvisor.preWindowOpen() method use the below code to add perspectives to the perspective switcher.
// Get a reference to the preferences store
IPreferenceStore prefStore = PlatformUI.getPreferenceStore();
// Set the value for the perspective bar preference. Insert your own
// perspective id values.
prefStore.setValue(IWorkbenchPreferenceConstants.PERSPECTIVE_BAR_EXTRAS, "project.perspective.id.1, project.perspective.id.2,...");
There are a number of preference values that you can set through IWorkbenchPreferenceConstants (see api).
It sounds like you want the default size of the perspective switcher (the bar containing the perspective buttons) to be larger than usual. To do that, you could perhaps use an instance of the ActionBarAdvisor class; you'll probably also need a WorkbenchWindowAdvisor class.
I don't see any methods to directly access the switcher object, so I think you'll have to look at the component tree to find it.
Seems like there ought to be an easier way, but I don't see one.
The perspectives show up on a tab. Although it's not clear just from looking at it, the end of the tab can be dragged so it's longer and can display more perspective buttons.
Right click mouse on the perspective toolbar, then select dock it on left or top left. You would see more toolbar items of other perspective, and show more on the toolbar.