i looking @ old code in dotnetnuke 4.x/vb.net , couldn't make meaningful out of following code. know setnull method not part of vb.net.
what code trying when null.setnull(examtrackerid) called?
private examtrackerid integer ' determine itemid if not (request.params("examtrackerid") nothing) examtrackerid = int32.parse(request.params("examtrackerid")) else examtrackerid = convert.toint32(null.setnull(examtrackerid)) end if
the null class not part of .net framework part of dotnetnuke library. i'm not familiar library looking @ (c#) source, seems null.setnull method checks whether or not input parameter (examtrackerid) null within database and, if so, returns value of input type. code converts return value int32 type.
it's simple utility class perform check on own because .net null not same dbnull type, seems it's there make less accidentally perform incorrect null check.
(i don't know if link source code outdated or if code incomplete there doesn't seem setnull overload takes 1 object type).
Comments
Post a Comment