Thursday, May 26, 2011

Eclipse Error: The builder launch configuration could not be found.

Errors during build.
Errors running builder "Integrated External Tool Builder" on project project.
The builder launch configuration could not be found.
Errors running builder "Integrated External Tool Builder" on project project.
The builder launch configuration could not be found.
Errors running builder "Integrated External Tool Builder" on project project.
The builder launch configuration could not be found.
Errors running builder "Integrated External Tool Builder" on project project.
The builder launch configuration could not be found.
Errors running builder "Integrated External Tool Builder" on project project.
The builder launch configuration could not be found.
************************


1.Select the right project
2.Choose "project"on the tool bar -> Properties
3.Click "Builders" in the menus of the popped up window
4.Remove the missing builders

Reference                                      
  1. http://dy.f.blog.163.com/blog/static/60711476200941824126555/

Wednesday, May 11, 2011

Passing parameters to a function called with setTimeout

When creating my news ticker plugin, I came across a slight complication when using setTimeout() to calling a function which needed parameters passed to it. Not having had much call to use setTimeout in the past, I simply put:

setTimeout(myFunction(parameter),myTimeout);


but that doesn’t work. An apparent solution (until tried in Internet Explorer) is:

setTimeout(myFunction,myTimeout,parameter);

It wasn’t as easy as I expected to find out how to get around this, but it turns out that all is needed is a “closure”:

setTimeout(function(){myFunction(parameter)},myTimeout);

Reference:                                                                                                      
  1. http://www.makemineatriple.com/2007/10/passing-parameters-to-a-function-called-with-settimeout