Exemplo n.º 1
0
        public HowTo_delObject()
        {
//<document>
            long _iduser = 1L;

            OGen.NTier.UTs.lib.datalayer.DO_User _user = new OGen.NTier.UTs.lib.datalayer.DO_User();
            if (_user.getObject(_iduser))
            {
                Console.Write(
                    "deleting user {0} ... ",
                    _user.Fields.Login
                    );

                //--- if parameter not specified uses object property _user.IDUser
                //_user.delObject(_iduser);

                //-- so in the case no need to provide IDUser
                _user.delObject();

                Console.WriteLine("DONE!");
            }
            else
            {
                Console.WriteLine("user not found");
            }
            _user.Dispose(); _user = null;
//</document>
        }
		public HowTo_delObject() {
//<document>
long _iduser = 1L;

OGen.NTier.UTs.lib.datalayer.DO_User _user = new OGen.NTier.UTs.lib.datalayer.DO_User();
if (_user.getObject(_iduser)) {
	Console.Write(
	  "deleting user {0} ... ",
	  _user.Fields.Login
	);

	//--- if parameter not specified uses object property _user.IDUser
	//_user.delObject(_iduser);

	//-- so in the case no need to provide IDUser
	_user.delObject();

	Console.WriteLine("DONE!");
} else {
	Console.WriteLine("user not found");
}
_user.Dispose(); _user = null;
//</document>
		}