none
How to develop in CRM

    Question

  • Hello,

    I have one issue in crm and im not sure im doin it in correct way.

    My issue:

    customer have a products in crm, some of products are grains (i have addet boolean field for products entity). I need to add one more tab in accounts, which will show records about what place of grains have sowed in what year. So datagrid view like in the CRM system with add, remove and edit buttons. When customer press remove button record have to be removed, when he press edit or add button system need to open form in new window where customer can fill/change 3 fields - Year, grain and place. For changing grain customer have to press find button on grains fields and system should open dialog window(is it possible?) where is a list of customers products what have IsGrain = true. When customer chose product dialog window need to close and this product name need to show in grains field on add/edit page. When customer save data and close add/edit form in grid view need to show actual data. All user interface should to looks like in CRM default interface.


    Its my first develop expirience for MS Dynamics CRM 4.0 and im not sure I am doing it correctly. I want to hear how You will develop this issue if you have got it.

    how i have tryed to do this:

    1) I have added field IsGrain for products enity.
    2) I have made entity Grain and removed all fields on Grains entity form.
    3) I have made table in Customers CRM database with fields Id, ProductsId, ProductsName(its is for history), Year and Place.
    4) I have made foreign keys beetween PoductsBase table and my table bu ProductsID and foreign key beetween my table and Grains entity table by Id, so they need to have one unique primary key.
    5) I added new tab for account form and added to it my developed IFrame. this iframe have datagid and 3 buttons (add, remove, edit)
    6) I have removed all fields form Grains entity forms and added my iframe on it. This frame have 3 fields (year, grain and place)
    7) I have called Grains entity form Grains list iframe on add/edit button cilck. If customer clicked "Edit" then i have send grains ID (What is same with GrainsBase tables Id) as query string parameter and load data on Grains Entity form.
    8) I have added script to OnSave methode on Grains entity form. This methode call my iframe submit(). where i check data and save it on database if data is correct. If data is incorrect i need show error message (i dont know how to show error dialog form from c# code)

    Now there are three problems to be solved:

    1) how to show dialog form on Grains Entity form - "For changing grain customer need to press find button on grains fields and system need to open dialog window(is it possible?) where is a list of customers products what have IsGrain = true. When customer chose product dialog window need to close and this product name need to show in grains field on add/edit page"

    2) Checking data at save "8) i have added script to OnSave methode on Grains entity form. This methode call my iframe submit(). where i check data and save it on database if data is correct. If data is incorrect i need show error message (i dont know how to show error dialog form from c# code)" and one more problem is to stop closing process if customers pressed "Save and close" button.

    3) problems at Grans list iframe - http://social.msdn.microsoft.com/Forums/en-US/crmdevelopment/thread/1a20406c-05fa-477c-8b78-b0519cd2424c

    Sorry for my english.

    Best regards
    Ivans Bistrovs

    Tuesday, June 02, 2009 9:46 AM

Answers

  • it sounds like you are decribing a need for a custom aspx page that would be displayed in a frame via the isv.config extensions.
    Matt, MVP - Dynamics CRM
    Friday, June 05, 2009 6:31 PM

All replies