Saving data to different tables from a single form in Dynamics AX - x++

How can we allow a Dynamics AX form to allow saving data on the grid to two independent tables:
When I click on +New it always adds the row to the first grid. We are looking for a way to add row independently for each grid on this form.

Your +New button is most likely a command button and has a single associated DataSource or inherited DataSource. So when you click +New, it can only do the single one.
See: https://learn.microsoft.com/en-us/dynamicsax-2012/developer/action-pane-button-overview
So you need to write some code or add a second Command Button with a different DataSource if you want the button to do two new records at the same time.

Related

How to dynamically change a function based on tab and cell in Google Sheets for drops downs

So I can create the dynamic drops downs using IF and Query in Google Sheets and this works great on one sheet. However, I need this to work over multiple sheets. Basically I need to be able to have the drop down menu in multiple cells on multiple tabs. This is the function I use to create the drop down menus:
=IF(Template!H1="6",FILTER(Sheet4!A:A,Sheet4!B:B=Template!G7),Query(Sheet4!A2:C500,"select B where A contains '"&Template!H1&"'"))
Template is one tab where people will find the drop down menus (from data validation pointing to the Sheet4 tab that holds this formula)
The problem is that the variables with Template in them are fixed to that one tab. I need to be able to have this drop down on multiple tabs.
Is there a way to call the tab you are on dynamically? If I have a Template2 tab I want it to be able to pull the lists from Sheet4 using the same type of filtering I am using for Template.

Delphi navigate through the TDBGrid using the TAB

In my DBGRID, i have a field that populated with default name of current configuration when i create new record.
When i set the dgtabs option to true, I can navigate through the grid using the TAB and SHIFT+TAB keys. I need to navigate without create new record or create new record with field populated by the current configuration name.
How can do that?
or create new record with field populated by the current configuration name.
You can do that simply by creating an OnNewRecord event handler for the dataset connected to the DBGrid and saving the configuration name to the relevant field in that.
Regarding how to avoid navigating the grid using Tab & Shift Tab opening the New Record row, a simple way, which may be acceptable (or not) to your situation is to set the DBGrid's Options.dgEditing to False. Then, the grid will not open the New Record row when Tab or Shift Tab is pressed or even if you press the Insert key in the DBGrid.
If that's not appropriate, you might take a look at my answer to this q
Focus cells in reverse order
which may give you a clue if you need it.

How to navigate page with Vaadin menubar?

These are my first steps with java, I took grails and vaadin plugin. I want to make simple app with menu bar navigation, so I have got some Vaadin example:
http://demo.vaadin.com/sampler-for-vaadin6#BasicMenuBar
created some commands:
edit.addItem("Cut1", menuCommand1);
edit.addItem("Cut1", menuCommand1);
Each command just draw table from another example:
http://demo.vaadin.com/sampler-for-vaadin6#TableHeaderIcons
Unfortunately each time I hit menu item it draws one table under another table, but what I was expecting is to draw each table in place of previous one.
How to achieve this?
vaadin's UI is stored as state (in a session) on the server. if you add several items they stay unless removed. so e.g. if you want to replace the table there you two options. either removeAllComponents and then add the new one or if you have hold of the original table then you can replaceComponent in the wrapping layout (most likely a VerticalLayout?).
if the table is just supposed to change content, then you are better off to just change/modifiy the dataSource of the table.

UI MVC Grid with custom command

I have a grid which displays a list of branches. I also have a ContactDetails button on each row which is a custom command popping a Kendo window displaying the details. It all works fine. However, I want these details to be editable. How should I approach this? I cannot seem to be able to access the model through the window.
I am using the code from their custom command demo: http://demos.telerik.com/aspnet-mvc/grid/custom-command
Ultimately, what I want is the grid to pass in the model representing the relevant row into the window so that the model can be modified and then persisted on the database.

How to reorder fields in an ORBEON Form

I understand that the layout in Orbeon Forms is grid-based, but even inside a grid of let's say 10 rows and 5 columns, If I happen to want to shift the 8th row to the 3rd row using the Visual Form Builder, how would I do that?
In general, is it possible to reorder the fields or sections within the Orbeon Designer using the MOUSE?
Currently you cannot reorder grid rows or columns, with or without a mouse (if by that you mean using drag-and-drop. But it's a great suggestion for the Orbeon Forms authors.
At this point, what you can do is this:
insert a new empty row
using the toolbox, "cut" the first control you want to move
using the toolbox, "paste" into the first cell of the new row
repeat the last 2 steps
It's painful but it will work.
Or, you can move the row directly within the source of the form, by moving the in the grid to the new place.
Note that while drag-and-drop would be great, it's not actually strictly needed: buttons and keyboard shortcuts can get you there too.

Resources