# Custom skin not working as desired

**URL:** https://forum.kirupa.com/t/custom-skin-not-working-as-desired/274704
**Category:** flash
**Created:** [November 3, 2008, 11:15am UTC](https://forum.kirupa.com/t/custom-skin-not-working-as-desired/274704 "2008-11-03T11:15:58Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![lalitk21](https://avatars.discourse-cdn.com/v4/letter/l/977dab/32.png) [@lalitk21](https://forum.kirupa.com/u/lalitk21)
#### Post date: [November 3, 2008, 11:15am UTC](https://forum.kirupa.com/t/custom-skin-not-working-as-desired/274704/1 "2008-11-03T11:15:58Z")

</div>

Hi  
I wanted to change the default behavior of the Flash Video Player skin such that “caption” Button works as a link and opens a new browser window.

I took SkinOverAll.fla saved as SkinOverAllCustom.fla and added following code:

this.captionToggle\_mc.addEventListener(MouseEvent. CLICK, onCaptionClick);  
function onCaptionClick (e:MouseEvent):void  
{  
trace(“caption button clicked!”);  
var url:String = “[http://www.google.com](http://www.google.com)”;  
var request:URLRequest = new URLRequest(url);  
try {  
navigateToURL(request, ‘\_blank’); // second argument is target  
} catch (e:Error) {  
trace(“Error occurred!”);  
}  
}

When I test this clip as SkinOverAllCustom.swf , the caption button click opens a new browser with [google.com](http://google.com).

But now when I add this skin in my FLVPlayback component it doesnt work, code is added as:

player.skin = “SkinOverAllCustom.swf”;  
player.skinBackgroundColor = 0x5E5E5E;  
player.skinBackgroundAlpha = 0.85;  
captioning.flvPlayback = player;

player being the instance of FLVPlayback and captioning being instance of FLVPlaybackCaptioning

Can anybody suggest what changes should I make so that caption button works as a button and I can control its onclick event?

Thanks
