Sunday, January 15, 2012

How to increase scroll bar size in windows application?

Question:


How can i increase scroll bar size in a windows application based on .Net Business Connector ?


Answer:


You can use windows display properties under personalization for it.
Further reading

Wednesday, January 11, 2012

How TO Write an Edit Method

Question:
How to write an edit method?


Answer:
Suppose you have an integer field with allowed values of 0 and 1. We can use an edit method to show a check box instead. We just have to use this edit method as a display method on the form control.


public edit NoYesId IsAllowed(boolean _set, NoYesId _value)
{
    NoYesId ret;
    int actualValue;
    if (_set)
    {
        if(_value == NoYes::Yes)
        {
            actualValue = 1;
        }
        ttsbegin;
        this.IsAllowedInt = actualValue;
        this.update();
        ttscommit;
    }
    else
    {
        if(this.IsAllowedInt)
        {
            ret = NoYes::Yes;
        }
    }
    return ret;
}

Monday, January 9, 2012

Dynamics AX Business Connector : Client made two requests at the same time.

Question :

I received a following error in my application built on the middle ware of business connector, "Client made two requests at the same time.".

Answer:


This is happening because you might have a multi-threaded application using same AX session in two requests. What you can do to fix it is to use different session objects for different parallel threads.