Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/csharp/330.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# 无法在C中提供文件#_C#_Wcf_File_Bytearray - Fatal编程技术网

C# 无法在C中提供文件#

C# 无法在C中提供文件#,c#,wcf,file,bytearray,C#,Wcf,File,Bytearray,我有一个字节[],它包含表示图像的所有数据。如何在浏览器中将其作为实际图像提供?以下代码仅返回字节列表:- List<HubAsset> hubAsset = _core.GetHubAssets(query); byte[] file = Convert.FromBase64String(hubAsset[0].Data); return file; List hubAs

我有一个字节[],它包含表示图像的所有数据。如何在浏览器中将其作为实际图像提供?以下代码仅返回字节列表:-

List<HubAsset> hubAsset = _core.GetHubAssets(query);
            byte[] file = Convert.FromBase64String(hubAsset[0].Data);                               
            return file;
List hubAsset=\u core.GetHubAssets(查询);
byte[]file=Convert.FromBase64String(hubAsset[0].Data);
返回文件;

这已经打开了:


您正试图将此作为WCF服务的响应发送?可能是重复的