|
|
Is Peru Important?
With world markets beginning t...
|
|
Is Peru Important?
With world markets beginning to melt down yesterday, and now according to some, stabilizing, it may be a good time to look at economics. While it may be premature to conclude this correction is over, and volatility may just grind away, drawing down values over the next four to six months before any bounce of any significance can occur, recent and ongoing events highlight how important the economy is to foreign policy. A downdraft in Shanghai triggered bad times across world markets, and trade and investment patterns may be impacted.
A region that traditionally receives little coverage in Canada is Latin America. More specifically, South America, and while countries like Brazil, Chile and Argentina are mentioned by media, it is rare to come across commentaries about Peru, Bolivia, Ecuador, or Paraguay. Invariably analysts and reporters address one or several of four major themes when Latin America does gain some attention. There is always Mexico, and stories about how it fits into North American trade (NAFTA) are not uncommon. Sometimes Cuba is discussed, and here it is customary to explain how and why bilateral relations have always been stable if not good, with reference made to the fact that Canada did not join the embargo of Fidel Castro’s regime, enabling ties. There was at one time the issue of immigration and refugees, and a cottage industry dominated principally by government analysts and academics periodically examined individuals and groups fleeing repressive regimes, with invariably the conclusion being made that those who arrived integrated successfully, managing to leave behind any associations with far left or far right ideologies. And then there was trade news from and about South America, in the 1990s usually dealing with Brazil, and how that economy might cause competition headaches for Canadian companies, notably for those in the aerospace sector.
Economics and South America are once again making an impact in Canada. These days places like Peru are stealing some headlines, and claims are that Canadians are open to investment ideas. Marketers of Latin America observe "Peru’s stable economic growth and positive financial outlook have attracted various international banking institutions... [including] Scotiabank (Canada)" [cited in "Peru’s Growing Economy Attracts Spanish Banking Group Santander," LIP News, 23 February 2007. Posted at http://www.livinginperu.com/news/3260]. Just how important relations may be with Peru was signaled in late January 2007, when a visit by a high-ranking official to Ottawa took place after almost a decade. Peru’s Agriculture Minister, Juan Jose Salazar, was "the highest-ranking official from Peru to come on a working visit to Canada since former president Alberto Fujimori in 1998" and his mission was to discuss bilateral free trade. Salazar maintained "Peru wants to be closer to Canada, both politically and economically. He expressed his government's awareness of the Canadian market’s significance for Peruvian exports, the potential benefits of a bilateral free trade agreement, and how co-operation in critical areas can be consolidated and improved." He also noted that Peru offers political, legal and economic stability, which no doubt was meant to sound reassuring and enticing to the roughly80 Canadian companies already investing an estimated $5 billion, mostly in the Peruvian mining sector [cited in Vladimir Torres’ "Canada to Discus Free Trade with Peru," The Hill Times, 31 January 2007. Story posted at http://www.embassymag.ca/html/index.php?display=story&full_path=/2007/january/31/peru/].
And while officials from Lima make their way to Ottawa, PromPeru, Peru’s promotional agency, is working to make Canadians want to trek to the South American nation. Official sources say that in 2006 tourism was up about 25%, with roughly 41,500 Canadians taking the journey. Most of them are well off, earning upwards of $95,000 in annual salary and falling in the 25-54 year-old demographic [cited in "Peru Targets Canadian Tourists," LIP News, 22 February 2007. Posted at http://www.livinginperu.com/news/3251].
But events in Shanghai on 27 February 2007 may yet turn out to have a profound impact on Canadian-Latin American ties. A question may be whether or not 2006 marks, at least for a while, the high point in Canadian relations with Peru.
Posted by Stan Markotich Send comments to stanmarkotich@yahoo.com
|
|
Always Centered AJAX Progress Indicator
|
|
In an earlier post I mentioned my struggle with the ProgressUpdate
control. In many situations it would be helpful to place the progress
indicator right in the middle of the page so users always have an idea
something is happening. The problem with this is, well, Internet Explorer < 7 .0 which treats lists (dropdowns, list boxes) as windowed controls, so they always show on top of other HTML elements.
When Shane Shepherd posted a couple of links to workarounds, it all came full circle. I ended up writing an extender control which attaches to any ASP.NET control and centers it dead-center during an AJAX callback. The included sample uses an animated glyph lifted from here but you’re free to use whatever you want.

I had a chance to test this in IE 6, Firefox and Opera. I don’t have Safari at the moment. Download the source code here and simply open CenteredProgressIndicatorTest in
Visual Studio as a web site.
|
|
Sys.Application.add_load != window.onload
|
|
I remember seeing a sample which used
Sys.Application.add_load to attach a function you’d normally want to run upon window.onload. It went like this:
function initFoo () {
// Initialization code here...
}
Sys.Application.add_load (initFoo);
Having browsed the MS AJAX Library source code, I figured the
Sys.Application provided a convenient event hook indeed since the class tapped window.load and window.unload
for you:
Sys.UI.DomEvent.addHandler (
window, "unload", this._unloadHandlerDelegate);
Sys.UI.DomEvent.addHandler (
window, "load", this._loadHandlerDelegate);
To my surprize, initFoo was getting called on every AJAX callback. I figured there was no way get window to fire its onload event several times, so the Sys.Application class must’ve been involved a lot more than I thought.
The remedy is to either hook into window.onload directly:
Sys.UI.DomEvent.addHandler(window, "load", initFoo);
or avoid multiple initializations:
function initFoo () {
var prm = Sys.WebForms.PageRequestManager.getInstance();
if (prm.get_isInAsyncPostBack())
return;
// Initialization code here...
}
To me, the former looks cleaner and less kludgy than the latter.
|
|
|
|
|
|
|
|
|
|