Bind with DataRow object

Posted by: nabinpadhi on 8 September 2017, 12:39 pm EST

  • Posted 8 September 2017, 12:39 pm EST

    <P>Hi I am not using any data source to populate the farpoint spread but while saving the data i want to bind DataRow arrayobject with the rows available in farpoint <BR><FONT color=#0000ff>Dim Rowswithvalues()  as</FONT> <BR><FONT color=#0000ff>dim internalCnt as integer = 0</FONT> <BR><FONT color=#0000ff>for i as integer =1 to MySpread.ActiveSheet.RowCount -1</FONT> <BR><FONT color=#0000ff>     redim preserve Rowswithvalues(internalCnt )</FONT> <BR><FONT color=#0000ff>     Rowswithvalues(internalCnt) = MySpread.ActiveSheet.Rows(i)</FONT> <BR><FONT color=#0000ff>     internalCnt =internalCnt  +1</FONT><BR><FONT color=#0000ff>Next</FONT> <BR><FONT color=#0000ff>Dim dr() as DataRow</FONT><BR><BR>======> here i want to import <FONT color=#800080>Rowswithvalues</FONT> into <FONT color=#800080>dr</FONT>
  • Replied 8 September 2017, 12:39 pm EST

    This is not going to work because you can't convert RowswithValues to a 1 dimensional array of a datarow.<br>
  • Replied 8 September 2017, 12:39 pm EST

    If you want to populate a datarow with values from Spread you will need to loop through the rows and columns of each and copy the value that way.<br>
Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels