Instead of doing it like that you can set the target at server side by looping through the menu items
foreach (MenuItem mi in Menu2.Items)
{
if (mi.Value == "test")
mi.Target = MakeTarget("ServerStatus");
}
This can be executed in Page Load or any other event handler
-Ajitha