# Give the user a form gird view with an editable query underneath.

**URL:** <https://www.dynamicsuser.net/t/give-the-user-a-form-gird-view-with-an-editable-query-underneath/57939>\
**Category:** Developer Forum\
**Created:** [June 20, 2015, 8:52am UTC](https://www.dynamicsuser.net/t/give-the-user-a-form-gird-view-with-an-editable-query-underneath/57939 "2015-06-20T08:52:43Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![blobdx7](https://avatars.discourse-cdn.com/v4/letter/b/87869e/32.png) [@blobdx7](https://www.dynamicsuser.net/u/blobdx7)\
**Post date:** [June 20, 2015, 8:52am UTC](https://www.dynamicsuser.net/t/give-the-user-a-form-gird-view-with-an-editable-query-underneath/57939/1 "2015-06-20T08:52:43Z")

</div>

Hi everyone,

I often receive the request to give the user an organised set of data to be exported to an Excel spreadsheet.

BY NOW:

The quickest way to do this is making a query (with ranges, grouping and whatever…) and use it as datasource in a view. Then I export the data from the view to Excel and i give the spreadsheet to the user. But all this word is always on my desk and I have to work on the AOT each time…

MY WISH:

I would like to find a way to give the user the facility to open this interrogation straight from a menu, change the query by his needs (even adding tables to the query that populates the result if possible) and then launch it to get a form grid filled with data ready to be exported to Excel.

POSSIBLE SOLUTION:

I would use a RunBaseBatch class with a query object:

-User sets up the query and clicks OK on the class prompt dialog

-The run method of the class populates a table “MyTable” with data (one field of the table identifies the user who has launched the class, so concurrent runs are managed)

-The class eventually opens a form which has “MyTable” table as datasource.

Now my questions are:

Is there some standard class or form which does this job in a similar way?

The SQL group by clause is managed correctly or there is some exception I should be aware of before starting?

Thank you in advance for the patience to read all this.

I hope you can give me some hints about this.

Regards

---

<div class="post-metadata">

**Author:** ![MartinDrab](https://avatars.discourse-cdn.com/v4/letter/m/e0b2c6/32.png) [@MartinDrab](https://www.dynamicsuser.net/u/MartinDrab)\
**Post date:** [June 20, 2015, 10:29am UTC](https://www.dynamicsuser.net/t/give-the-user-a-form-gird-view-with-an-editable-query-underneath/57939/2 "2015-06-20T10:29:14Z")

</div>

Note that this question is already being discussed in [a duplicate thread on another forum](https://community.dynamics.com/ax/f/33/t/164007).
