我添加的是Microsoft office spreadsheet 11.0,<OBJECT classid="clsid:0002E559-0000-0000-C000-000000000046" VIEWASTEXT>......但怎么从后台代码给它赋值呢?如传一个DataSet?

解决方案 »

  1.   

    基本原理应该是:映射服务器的DataSet到客户端,在使用客户端脚本将映射的内容设置到OWC里面即可。如何映射,你可以参考一下ajax.net,这里面有服务器端到客户端的数据结构映射,它号称已经可以映射DataSet这样复杂的数据类型了。
      

  2.   

    如果用它显示在客户端的话,你查查OWC用于联机数据分析方面的东东,客户端可以用JavaScript和VBscript操作,客户端直接连数据库,安全期间,一般只运行在局域网内部
      

  3.   

    cuike519(Help you,Help me) :通过PlaceHolder控件,从后台代码绑定xml数据集,存放到客户端.不知怎样绑定到owc spreadsheet.
    下面的代码是绑定到owc chart控件的:
    'Extract the contents of the XML Data island and insert it into two arrays: one array for the chart categories and one array for the
    Dim nCount, nodes, i
    Set nodes = dsXML.XMLDocument.childNodes.item(0).childNodes
    nCount = nodes.length
    Redim aNames(nCount)
    Redim aTotals(nCount)
    For i=1 to nCount
    aNames(i) = nodes.item(i-1).ChildNodes.item(0).text
    aTotals(i) = nodes.item(i-1).ChildNodes.item(1).text
    Next'Create a chart from the array data.
    'Bind the chart to the recordset.
    Dim c
    Set c = CSpace.Constants
    Dim oChart, oSer
    CSpace.Clear
    Set oChart = CSpace.Charts.Add
    Set oSer = oChart.SeriesCollection.Add
    oSer.SetData c.chDimCategories, c.chDataLiteral, aNames
    oSer.SetData c.chDimValues, c.chDataLiteral, aTotals我查看了一chm帮助,大多数都是关于winform下使用owc spreadsheet控件的,没有webform下使用的例子.
      

  4.   

    mossiy(秋山至景)怎么解决的阿,帮个忙,我正在做
      

  5.   

    lihbymr(netboy), 楼上有说明啊.