Associate multiple images to a control
Hi,
With the following code, I am able to associate an image to a AW group contro. BUt can I add multiple images to the control with their respective events?
var obj = new AW.UI.Group;
obj.setId("group");
var img = obj.getContent("box/image");
img.setTag("IMG");
img.setClass("image", "dynamic");
img.setAttribute("src", function(){
return this.getControlProperty("image");
});
obj.setControlImage("/image/edit.gif");
obj.setStyle ("left", "15px");
obj.setStyle ("width", "500px");
obj.setStyle ("height", "230px");
obj.setControlText("Subscribe");
document.write(obj);
There is another approach, by setting the controlText (obj.setControlText("Subscribe");) with embedded with HTML <img src=/image/edit.gif> tags, but that does not cater my requirements, as I want those images to be separate controls, rather than just images.
So can I add multiple images to a control by the first method? If so, Can you please explain?
With the following code, I am able to associate an image to a AW group contro. BUt can I add multiple images to the control with their respective events?
var obj = new AW.UI.Group;
obj.setId("group");
var img = obj.getContent("box/image");
img.setTag("IMG");
img.setClass("image", "dynamic");
img.setAttribute("src", function(){
return this.getControlProperty("image");
});
obj.setControlImage("/image/edit.gif");
obj.setStyle ("left", "15px");
obj.setStyle ("width", "500px");
obj.setStyle ("height", "230px");
obj.setControlText("Subscribe");
document.write(obj);
There is another approach, by setting the controlText (obj.setControlText("Subscribe");) with embedded with HTML <img src=/image/edit.gif> tags, but that does not cater my requirements, as I want those images to be separate controls, rather than just images.
So can I add multiple images to a control by the first method? If so, Can you please explain?
VJ
May 7,