Windows form - Custom User control in Panel - windows

I have a panel control that loads a user control inside it. Panel has auto scroll property set to true. A user can select an option from the menu and based on which Panel is cleared and new user control is loaded. This user control contains an Infragistics grid. The length of the infragistic grid varies based on the number of rows so at times it goes out of the height of the panel.
The problem I have been facing is that once user scrolls down using panel scrolls and then chooses another option from menu that loads new User control with grid in it, the size of the grid cuts down. The scroll position of the panel is set to the start however, the upper part of the UC (having grid inside it) is lost. I cannot scroll up to see it as well.
I have been trying to figure it out based on how a control is loaded and drawn in the panel along with the scrolling of the panel to come to some understanding, but have been unsuccessful so far. Pls help.

Related

Restore Vertical Scroll missing on form after switch to Universal Theme

I'm using Oracle 18.c and Apex 19.1. I recently switched an existing application to Universal Theme. I noticed that the vertical scrolls were missing from interactive reports and from forms. I was able to restore the vertical and horizontal scrolls to the Interactive Report by going to Attributes / Heading. I set the Fixed To = Region and set the Maximum Report Height to 680. That seems to have fixed the problem with Interactive Reports.
However I still have a problem with Forms. In Apex I click on the form name, and note that the Appearance / Template is set to Standard and the Appearance / Template Options is set to Use Template Defaults, Scroll - Default. I can't figure out how to enable the vertical scroll so that users can edit fields on the lower part of the form.
I should add that there is indeed a scroll bar on the form. The scroll bar itself slides up and down, but the body of the screen remains still.
I eventually solved the problem. I built this page from the Interactive Report / Form wizard. On the region, the Layout / Position defaulted to Breadcrumb Bar. When I changed the Layout / Position to Body, the scroll bar behaved as expected.

How to load a SD Grid and scroll automatically to last record on Genexus 15?

I have a SD grid to show messages received from other users (a simple chat app) and every time I open this panel, the first records appears and I have to manually scroll to reach last message.
Is there a way to automatically go to last record on this grid ?
I know there is a Select() method on grids, but this can´t be used on Refresh Event, only on user events.
I´m using GX15 U6
Thanks,
Rogelio Arosemena
Yes, it is possible with Inverse Loading property
This property is available for grids in the Smart Devices generator.
By setting it to True (its default value is False), the developer will
be able to load the grid in reverse direction (i.e. the Common Grid
will be loaded from bottom to top, and the Horizontal Grid will be
loaded from right to left).
Example of use The canonical use case of inverse loading on a grid is
that of a chat messaging system. What are its characteristics? It is
loaded from bottom to top, pagination is performed with a swipe-down
gesture, and when the user refreshes it the first page will be
displayed in the lower section.

Kendo Scheduler not refreshing when dynamically resized

Our app is setup with your basic header, footer, left nav, and content pane. We also have a dynamic right pane which we call "Quick View". If you click a link that targets Quick View, the right pane will slide out from the right. This causes the content pane to shrink horizontally so the right, Quick View pane displays.
When we have the Kendo Scheduler displayed in the content area and click a link that causes the Quick View pane to slide into view from right, the Scheduler does resize with the content area, but the events are not refreshed. Example would be if in week view initial display is fine. Slide in the Quick View causeing Scheduler to shrink in width. Day columns shrink as expected but none of the events change at all. This makes what was scheduled on Thursday to now appear to be scheduled on Saturday.
If I manually resize the browser at all, it triggers the refresh and all is well. Problem with that is 2 fold:
1. I don't want to require my users to resize the browser, of course.
2. Then closing the Quick View has the right pane slide back out the right cause the Scheduler to grow in size and again, the events do not move making them appear to be on different days.
I guess I could put in a hack to programmatically refresh Scheduler after my Quick View slides in or out, but that is a hack.
Suggestions please.

Why can't I set a layout for a page in a QStackedWidget in designer?

Steps to reproduce in designer for Qt 4.8.0
I create a new dialog form in Qt Designer
I add a QStackedWidget to the dialog
I set the layout of the dialog to make the stacked layout size with the dialog
I add a few controls to page one in the stacked widget
I select the first page in the stacked widget in the right hand tree view of controls
The icon next to that page (which is a QWidget) shows the page is missing a layout
When I click one of the layout buttons above, it doesn't change the layout of the page QWidget, it changes the layout of the dialog even though I had explicitly selected the page.
Is this a bug in designer? Am I missing something? I really don't want to add the layouts programatically as that prevents me from being able to layout the pages in designer in the same .ui file
Clicking a widget page in the object tree brings that page to the top of the stack, but it does not select it.
In fact, it is not possible to select a widget page itself - only its child widgets can be selected (as well as, of course, the parent stacked-widget).
The easiest way to set a layout for a widget page is to:
bring it to the top by clicking the little arrows on the top-right
corner of its parent stacked-widget
set the appropriate layout using the buttons on the toolbar
Note that it is not possible to set a layout on a widget that does not have any child widgets.
(If there is a bug here, it is that the toolbar buttons should really be greyed-out when clicking on a widget page in the object tree that has no child widgets. When the stacked-widget arrows are used, the toolbar buttons are greyed-out correctly).
It's not a bug in designer, but it's not very intuitive either. You need to click within the stacked widget page itself (where your controls are) and then click one of the layout buttons in the toolbar. Clicking the page in the tree view won't select the page for you.

How to keep list view control on top of other window?

I am working on a sample which contains list view to display list of names in the data base. Once the application is launched list view will be invisible. After clicking on some button I am making it to visible. If I make it to visible the control bellow the list view are also visible. And I have button bellow that control, once I hove on the list view the button also displays over the list view.
Please let me now how to solve this problem.
It sounds like you have child windows on top of each other in a dialog. Use ShowWindow(SW_HIDE) to hide the windows that are 'underneath'. So when you make the listview visible, hide the button that is underneath.
On the windows desktop, application windows will properly hide other windows that are underneath one another, but in a dialog, different styles are used, and you have to be careful not to let controls overlap or they can draw on top of each other. Instead you need to hide the ones that you don't want to be visible.

Resources