Advertisement
Guest User

Untitled

a guest
Apr 19th, 2014
39
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.50 KB | None | 0 0
  1. public int? SubBrandIndex
  2. {
  3. get
  4. {
  5. return _model.SubBrand == null ?
  6. (int?)null : Convert.ToInt32(_model.SubBrand);
  7. }
  8. }
  9.  
  10. public int? SubBrandIndex
  11. {
  12. get
  13. {
  14. int? subBrandIndex = null;
  15. if (_model.SubBrand != null)
  16. subBrandIndex = int.Parse(_model.SubBrand);
  17. return subBrandIndex;
  18. }
  19. }
  20.  
  21. public int? SubBrandIndex
  22. {
  23. get
  24. {
  25. int value;
  26. return int.TryParse(subBrand, out value) ? (int?)value : null;
  27. }
  28. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement