Latest posts to the library

I needed a quick and easy way to check for the basics of an email address. Does it contain “@” and “.” symbols. This is by no meals a foolproof method, so don’t use it for anything big, but if you want to just do a quick test then here you go: var email:String = [...]

Categories: ASP, flash | Add a Comment

This is an example of how to create a random number in Classic ASP in order to append to a swf file so that the browser does not cache the swf file. <% Dim SwfRndNum Randomize SwfRndNum = Rnd %> You can then add it to your swf embed code as follow, bear in mind [...]

Split string into sentences by max line length. This uses a character array but doesn’t use word-wrapping. var personalMessage:String = "You got this far so we reckon that you could be curious enough to learn a little more, we’ll contact you shortly to answer any questions you may have."; _root.myArray = new Array(); _root.myArray = [...]

This is how to add text leading using Actionscript 2 for Flash. var txtFormat:TextFormat = new TextFormat(); txtFormat.leading = 5; // change this to whatever you need it to be ttt.setTextFormat(txtFormat); ttt2.setTextFormat(txtFormat);</span> There is also a GUI way of doing this: Select your textfield and and under the paragraph section, set the top/right hand icon [...]

I needed to work out a date range according to the date 3weeks away from the current date. After a bit of thinking, I found that it’s actually quite easy to achieve. var theDate:Date = new Date(); dateDay = theDate.getDate(); dateMonth = theDate.getMonth(); dateYear = theDate.getFullYear(); var theDate2:Date = new Date(dateYear,dateMonth,dateDay); theDate2.setDate(theDate2.getDate() + 21); dateDay2 [...]

I have been working on a project where I need to select a date range starting today and ending a month from now, so the user cannot select anything in the past or over a month from now. This is how I did it: There is an instance of DateChooser on the stage with Instance [...]

An animation done showing the battle between animator and the animation in a Flash environment. Thanks to Alan Becker for this one.

Categories: General, adobe, flash | Add a Comment

If you use a dynamic textbox in Flash and you want to embed the British Pound symbol (£) then you will want to also embed the “Latin I” glyphs with your textfield.

If you have a movieclip that by default has the hand cursor showing on RollOver and you don’t really want this, you can disable it by doing the following: myMC.onRollOver = function() {         this.useHandCursor=false; } So the main code here is: this.useHandCursor=false; False disables it and true shows it.



back to top