T O P I C R E V I E W |
srira |
Posted - 08/12/2006 : 12:16:14 PM Origin Version (Select Help-->About Origin):6.1 Operating System:XP Hi Is there a way to copy the column labels too when we move data from one worksheet to another? |
1 L A T E S T R E P L I E S (Newest First) |
Mike Buess |
Posted - 08/12/2006 : 2:02:18 PM You can create buttons that run these CopyDataAndLabels and PasteDataAndLabels script sections. See your Origin and LabTalk help files for instructions on creating custom toolbars.
[CopyDataAndLabels] if( 10&wks.sel!=10 ) { type -b Select whole columns.; return; }; %Z=""; loop(i,wks.c1,wks.c2) { %A=wks.col$(i).label$; // copy label if(i==wks.c1) %Z=%A; else %Z=%Z|%A; }; menu -e 57634; // run Edit > Copy
[PasteDataAndLabels] if( 10&wks.sel!=10 ) { type -b Select whole columns.; return; }; menu -e 57637; // run Edit > Paste if( %Z=="" ) return; loop(i,wks.c1,wks.c2) { wks.col$(i).label$=%[%Z,#i-wks.c1+1,|]; // paste label };
Mike Buess Origin WebRing Member
Edited by - Mike Buess on 08/12/2006 2:07:07 PM |
|
|