Thank you both Castorix and Viorel.
Actual problem was converting the NULL to String as highlighted by Viorel, and omitting the ToString did the trick.
Disk Infomration SD Card Issue with VB.Net using Win32_DiskDrive
~OSD~
2,201
Reputation points
Hi,
I have following code to list the physical disk(s) information:
When there is SD card available, I get unhandled exception and VB app crashes. The information about the SD card can be gained with PowerShell as:
Can we modify the code somehow to exclude the disk if it's SD card or manage it in different to include SD card information as well?
Developer technologies | VB
2,892 questions
Accepted answer
-
~OSD~ 2,201 Reputation points
2021-03-11T13:54:04.17+00:00
2 additional answers
Sort by: Most helpful
-
Castorix31 90,686 Reputation points
2021-03-11T10:29:05.237+00:00 SD Card Size is NULL, from your screencopy...
-
~OSD~ 2,201 Reputation points
2021-03-11T09:45:42.86+00:00 Cannot upload code, getting following error message.