ابدأ بالتواصل مع الأشخاص وتبادل معارفك المهنية

أنشئ حسابًا أو سجّل الدخول للانضمام إلى مجتمعك المهني.

متابعة

Compare between DateTime datatype through Dot Net Framework versions in terms of whether it can be null or not?

Calculators mostly have a microcontroller for processing , a microcontroller usually is consisted of it's own processing unit , ROM , FLASH memory and I/O ports to deal with other components like keypad or LCD , microprocessors usually have families for different sorts of applications , some examples of the very famous microcontroller vendors are ATMEL and Microchip , every vendor has it's own instruction set for every micocontroller.Computers mostly have a microprocessor as a processing unit , a microprocessor needs an external RAM , BIOS and different I/Os to boot , It is more complicated than a microcontroller in terms of architecture , it has more complex instruction set and a lot of algorithms are implemented inside it to improve it's performance , some of these algorithmic architectures are Pipe-lining and Register Caching. Some examples of the very famous microprocessor vendors are AMD , ATMEL , IBM , ARM (the smartphone processor) and the most famous Intel.

user-image
تم إضافة السؤال من قبل Hazem Gharib , Senior Software Engineer , SEEK Asia
تاريخ النشر: 2016/08/11
Hammad Rafique
من قبل Hammad Rafique , Software Engneer , Peak Analysis & Automation Ltd.

Structure can not be assigned null value.

in vb.net you do something like

Dim d As DateTime = Nothing

But all this does is to set d to the default DateTime value.

In C# the equivalent code would be this:

DateTime d = default(DateTime);

...which is equivalent to DateTime.MinValue.

so in background it is never assigned as null

Awwab Ahmed
من قبل Awwab Ahmed , Web-Developer, Graphic-Designer. , Conobio

DateTime is a Value Type like int, double etc. so there is no way to assigned a null value.

You can solve this problem in two ways, either make it a nullable type, or use the System.DateTime.MinValue.

المزيد من الأسئلة المماثلة