private void SelectImageServiceComboItem(string svc, int? index = null)
{
int idx;
if (string.IsNullOrEmpty(svc))
{
idx = index ?? 0;
}
else
{
idx = ImageServiceCombo.Items.IndexOf(svc);
if (idx == -1) idx = index ?? 0;
}
try
{
ImageServiceCombo.SelectedIndex = idx;
}
catch (ArgumentOutOfRangeException)
{
ImageServiceCombo.SelectedIndex = 0;
}
this.UpdateAltTextPanelVisible();
}