Published
- 1 min read
convert iformfile to byte array c#
The solution for this is noted below
convert iformfile to byte array c#
Solution
foreach (var file in files)
{
if (file.Length > 0)
{
using (var ms = new MemoryStream())
{
file.CopyTo(ms);
var fileBytes = ms.ToArray();
}
}
}
Try other methods by searching on the site. That is if this doesn’t work