# Flex image binding

**URL:** <https://forum.kirupa.com/t/flex-image-binding/315512>\
**Category:** flash\
**Created:** [October 28, 2010, 2:18am UTC](https://forum.kirupa.com/t/flex-image-binding/315512 "2010-10-28T02:18:54Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![akumar1282](https://avatars.discourse-cdn.com/v4/letter/a/8baadc/32.png) [@akumar1282](https://forum.kirupa.com/u/akumar1282)\
**Post date:** [October 28, 2010, 2:18am UTC](https://forum.kirupa.com/t/flex-image-binding/315512/1 "2010-10-28T02:18:54Z")

</div>

\<?xml version=“1.0” encoding=“utf-8”?\>  
\<mx:Application xmlns:mx=“[http://www.adobe.com/2006/mxml](http://www.adobe.com/2006/mxml)” layout=“vertical” horizontalAlign=“center”\>

```
&lt;mx:Script&gt;
    &lt;![CDATA[
       
        [Bindable]
        [Embed(source="/assets/images/helpfulDocs.png")]
        private var helpDocs:Class;
       
        private function onClickfunc(s:String):void{
            trace("string is " + s);
            myImage.source = s as Class;
        }
       
    ]]&gt;
&lt;/mx:Script&gt;
&lt;mx:VBox&gt;
    &lt;mx:Image id="myImage" /&gt;
    &lt;mx:Button id="simpleButton" label="provideArray" click="{onClickfunc('helpDocs')}" /&gt;   
&lt;/mx:VBox&gt;

```

\</mx:Application\>

============

Q : Is there any way to somehow use the string value of onClickFunc function to use the class object with whom i embed the image . Like with passing “helpDocs” string , can I use that string value some how to access helpDocs:Class ??

Its not possible i guess but just out of curiosity
