Button to load contentPath and External Text Problem

i have the following layers:

Gallery - containt mx.controls.load named art1Loader
Gallery Info - Dynamic Text Box named infoBox
Gallery Buttons - btn1

i have the following script within btn1

on(release){
art1Loader.contentPath = “images/artists/artist1/exam1.jpg”;
}
loadText = new loadVars();
loadText.load(“txt/art/artist1/TEXT1.txt”);
loadText.onLoad = function(success) {
if (success) {
// trace(success);
infoBox.html = true;
infoBox.htmlText = this.info;
}
};
}

i get the follwing errors:

Warning Symbol=Test Clip , layer=GaleryButtons, frame=2:Line 4: The identifier ‘loadVars’ will not resolve to built-in object ‘LoadVars’ at runtime.
loadText = new loadVars();

Error Symbol=Test Clip , layer=GaleryButtons, frame=2:Line 5: Statement must appear within on handler
loadText.load(“txt/art/artist1/TEXT1.txt”);

Error Symbol=Test Clip , layer=GaleryButtons, frame=2:Line 6: Statement must appear within on handler
loadText.onLoad = function(success) {

Error Symbol=Test Clip , layer=GaleryButtons, frame=2:Line 13: Unexpected ‘}’ encountered
}

Total ActionScript Errors: 4 Reported Errors: 4

Ok so im new to this somebody please help?

try

[AS]on (release) {
art1Loader.contentPath = “images/artists/artist1/exam1.jpg”;
loadText = new LoadVars();
loadText.load(“txt/art/artist1/TEXT1.txt”);
loadText.onLoad = function(success) {
if (success) {
// trace(success);
infoBox.html = true;
infoBox.htmlText = this.info;
}
};
}[/AS]

superstar it works perfectly cheers

np :beer: