C# Equivalent to IIF

by ebarcza 7/8/2011 5:10:00 AM

 Here's the C# equilvalent statement to VB IIF

ReturnValue = a == 1 ? true : false;

OR

<bool condition> ? <true value> : <false value>

Tags:

how to hide tabs in AJAX Toolkit tab panel

by ebarcza 7/7/2011 5:26:00 AM
In order to hide a panel in the Ajax Toolkit Tab Panel, set the enabled property of the tab to false. Setting the visible property to false will still show the header so this is the prefered method tbContract.Tabs[0].Enabled = false;

Tags:

C# Check for Null Querystring

by ebarcza 7/7/2011 3:54:00 AM
 if (Request.QueryString["ContractID"] != null && Request.QueryString["ContractID"].ToString() !="")
            {
                int contractID = int.Parse(Request.QueryString["ContractID"].ToString());
                Contract contract = new Contract(contractID);
                hdnContractID.Value = contractID.ToString();
                LoadForm(contract);
            }

Tags: , ,

.NET

Powered by BlogEngine.NET 1.5.0.7
Theme by Mads Kristensen

About the author

Name of author Author name
Something about me and what I do.

E-mail me Send mail

Calendar

<<  September 2017  >>
MoTuWeThFrSaSu
28293031123
45678910
11121314151617
18192021222324
2526272829301
2345678

View posts in large calendar

Recent comments

Tags

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2017

Sign in