maybe too big to show

解决方案 »

  1.   

    that's because when you render table and chart ,the stream is combined,so the image cannot show correctly.
    There are some way to solve these question,
    e.g:render the images to local and embeded them into your html.
    i give your my source code:byte[] result = null;
    string historyID = null;
    string format = "HTML4.0";
    //the images local path
    string imagePath=@"../ReportFile/images/"+Guid.NewGuid()+"/";
    if (!Directory.Exists(Server.MapPath(imagePath)))
    {
    Directory.CreateDirectory(Server.MapPath(imagePath));

    }
    //tell reporting service that the render images be link
    string devInfo = "<DeviceInfo><Toolbar>False</Toolbar><HTMLFragment>True</HTMLFragment><StreamRoot>"+imagePath+"</StreamRoot></DeviceInfo>";//get report's html (containing images' local link)
    result = rs.Render(sReportPath, format, historyID, devInfo, proxyParameters, credentials, 
    showHideToggle, out encoding, out mimeType, out reportHistoryParameters, out warnings,
    out streamIDs);
    sh.SessionId=rs.SessionHeaderValue.SessionId;
    //rs.SessionHeaderValue=null;
    //get images local
    foreach (string streamID in streamIDs)
    {

    byte[] image = rs.RenderStream(sReportPath,format,streamID,
    null,devInfo,proxyParameters,out encoding,out mimeType); FileStream stream = File.Open(Server.MapPath(imagePath) + streamID,FileMode.OpenOrCreate,FileAccess.ReadWrite,FileShare.Read);
    stream.Write(image, 0, image.Length);
    stream.Close();
    }//end
    then you can render the result
      

  2.   

    我的操作系统是win 2003,按照gyyshuai(师无横) 兄的做法试了,也还是显示不了分析图形。
    但从rs的帮助来看,是应该使用RenderStream方法,是否还有其他地方需要配置?
      

  3.   

    我看了RS生成页面的源码,它使用<IMG style="background-color:White;background-repeat:Repeat;padding-left:0pt;padding-top:0pt;padding-right:0pt;padding-bottom:0pt;border-style:None;" SRC="/WebApplication1/C_3331_S"/>来显示图片,而在我的/WebApplication1目录下已生成了C_3331_S文件,只是IE不能识别这个文件的类型,所以显示不了图形。
      

  4.   

    you can open this file in ie,see what this image like.
    ie can open these files,or your image have no lines
      

  5.   

    在IE中,我直接输入C_3331_S文件的地址,也显示不了图片。
      

  6.   

    在RS中,HTML Device Information Settings有个Icon配置,这个Icon是干什么用的?是否是设置图片的后缀名。
      

  7.   

    我在reporting service设计了一张报表,其中有表格和分析图形。
    通过ReportingSerive.Render方法嵌入到自己的页面,表格能够正常显示,但分析图形则显示不了。
    /******************************************************************前些时间我有遇过同样的情况,是因为Reporting Services并没有完全安装好,它还有一个服务,不知你是否安装完?这里是指所布置的服务器!! 有问题再问
      

  8.   

    部署用 你的机器名称 http://xxxxmachinename....运行WEB程序的时候也用 xxxxmachinename  ,不用localhost试下