Tuesday, January 25, 2011

Table [] called without buffer

I was  working on AX 2009 CRM Module creating a new Lead. Everything worked fine but the Qualifying Process Drop Down List (and button).

Basically I was trying to develop a customization around the form, and I needed to understand the Stages process , but I was being unable to get that far as I couldn't select anything from the Qualifying Process (it was empty), and because of that reason both the Qualifying Process and Stages button were grayed out.

Anyway, I right clicked the Qualifying Process Drop Down List (on the Grid) and then went to "Go To Main Table" and I got an error saying "No object specified on menu item Hierarchy". Mhhhhhhhhhhh....

Then reading some blogs about the error I learned that I needed to create a new menu item named Hierarchy (The same as the Table/Form) pointing to the Hierarchy form. When I went back to the Qualifying Process Drop Down Menu again and clicked "Go To Main Table" I got the error "Called without valid buffer"

What does this error mean?

Well, based on Microsoft the error is caused due to the form requires that it be called from something else, and the other object will pass in a record. 

Response from Microsoft:
If you examin the init() method of the Hierarchy form, you will see the following code:

 if (isTemplate)
        projActivityLink = false;
        if (element.args().dataset() != tablenum(Hierarchy))
            // Called without active buffer
            throw error("@SYS18626");

Notice the if statement after the else.  This is testing to see if the record being passed in comes from the Hierarchy table.  If this fails, it throws the error. 
Since I created a menu item and did not pass in a table buffer from the Hierarchy table, this causes the error message to occur.

The problem is that I haven't resolved the problem yet as I decided to just keep working on other customization for now on. I will post the answer when I get it. Of course if you happen to know the answer, it would be great if you could share it with me.

No comments:

Post a Comment

Thank you for your thoughts. Your comment will appear in my blog shortly after review.

Have a great day!