SORU
22 NİSAN 2010, PERŞEMBE


Catch blok döndürür?

. Catch bloğu içinde bir return ifadesi olması yanlış mı? Alternatifler nelerdir?
ben.e:

public bool SomeFunction()
{
    try
    {
        //somecode
        return true;
    }
    catch(Exception ex)
    {
        MessageBox.Show(ex.message);
        return false;
    }

}

CEVAP
22 NİSAN 2010, PERŞEMBE


Normalde catch blok döndürür. Normalde iyi bir fonksiyonel kod.

Bunu Paylaş:
  • Google+
  • E-Posta
Etiketler:

YORUMLAR

SPONSOR VİDEO

Rastgele Yazarlar

  • aki6336

    aki6336

    14 AĞUSTOS 2008
  • Living Waters

    Living Water

    9 AĞUSTOS 2006
  • The Verge

    The Verge

    8 AĞUSTOS 2006