Home > BaaN, How to, Infor > How To #2 – display a colour indicator on Baan forms #baanhowto

How To #2 – display a colour indicator on Baan forms #baanhowto


How to display a colour indicator on the Baan forms?

Many a times, customer asks for visual indicators displaying red/green colours on the baan sessions. These colour indicators may become so very useful sometimes for the user working on the shopfloor, because they don’t have to worry about the messages or reports popping up, on error. A “green” colour may indicate that the task is successful and “red” may indicate its failed. Many a time a person working on the shopfloor may not be literate enough to read the messages & reports popped up, and these colour indicators save them a lot of time.

function create.frame(){
            frame.id = create.object(DsCgwindow, current.mwindow(),
                                     DsNx, 410, DsNy, 55,
                                     DsNwidth, 20, DsNheight, 18,
                                     DsNbackground, color )
            update.object(frame.id)
}

The code snippet, above is self explanatory, it creates a frame of  specified dimension and axis on above the parent main window with the color specified in the parameter. You can change the color based on certain conditions as per your requirement.

Lets dig more into the parameters used in the create.object()

The first parameter used in the type of the object created, here I have used “DsCgwindow” , This represents a window in which applications can draw graphical parts such as lines, rectangles, polygons, and so on.

The second parameter is the parent object,  current.mwindow(), This will provide the id of the current main window to which we need to attach the subobject.

Other optional parameters used are the  X & Y co-ordinates , width , height & Colour.

Quick Submit

Advertisements
Categories: BaaN, How to, Infor Tags: , ,
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: