T O P I C R E V I E W |
shawn_007 |
Posted - 04/18/2005 : 10:33:29 AM Origin Version (Select Help-->About Origin): Operating System:
How to append a worksheet with the contents of other worksheets. For example: The resource worksheets are wks_resource[i].The destination worksheet is wks_destination.Each time append the the contents of wks_resource[i](RowFrom=100,RowTo=200,ColFrom=0,ColTo=1) to the wks_destination (ColFrom=0,ColTo=1).
Following are my unsuccessful codes. void func_append() { Worksheet wks_results; wks_results.Create("origin.otw", CREATE_VISIBLE_SAME); for(i=0;i<5;i++) { Worksheet wks_resource(s_rawdata[i]); wks_resource.DeleteRange(0,0,100,1); wks_resource.DeleteRange(200,0,300,1); Dataset ds0(wks_resource, 0); Dataset ds1(wks_resource, 1); vector v0(ds0); vector v1(ds1); Dataset dsDest0(wks_results, 0); Dataset dsDest1(wks_results, 1); dsDest0.Append(v0); dsDest1.Append(v1); } } |
1 L A T E S T R E P L I E S (Newest First) |
greg |
Posted - 04/18/2005 : 4:25:15 PM Not sure what the best solution in OriginC would be. Here is a LabTalk solution for small worksheets :
data2!wks.copy(Z); get %(data1,1) -e end; data1!wks.paste(Z,1,end);
(Note that this is the wrong forum for this topic. Your post really belongs here :http://www.originlab.com/forum/forum.asp?FORUM_ID=12 )
|
|
|