this.addobject(lcObj, lcClass) loObj=getpem(this, lcObj) with loObj .property...=value .propert...=value * set whatever else you may want .visible=.t. endwithSo the object starts as visible, and then later its visibility is set as needed. With your method they all come visible, which may not be what you want. With just two buttons, or if all the buttons are visible all the time, it's not a problem. I've seen frameworks put code in .button.refresh() to decide whether a button will be enabled or not, visible or not. IOW, nothing wrong with your code, it's a matter of where the code goes, a matter of taste.