The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
 All Forums
 Origin Forum
 Origin Forum
 how to get the name of active column?

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

Screensize:
UserName:
Password:
Anti-Spam Code:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkUpload FileInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
autopilot Posted - 02/12/2009 : 06:16:57 AM
Origin Ver. and Service Release (Select Help-->About Origin): Origin 7.5
Operating System:winxp

Hello,

I have a simple question. I use function curve.data$ and it needs "Name of the Y column in the worksheet". Instead of specifying Data1_B I would like to use some labtalk command for active column. What is it?


my code is the following:
//////////////////////////////////
for(jj=0; jj<=wks.nCols-1 ; jj=jj+3)
{
wks.col=jj+3; // set column number for smoothing function
wks.insert(AASm); // insert empty column with name "AASm"
%A = wks.col$(jj+2).name$; //get the name of data column
%B = wks.col$(jj+3).name$; //get the name of empty column
curve.data$=wcol(jj+2); //input Y
curve.result$=wcol(jj+3); //output Y

curve.i1=1; //index of 1st data
curve.smoothpts=55; //points for smoothing
curve.adjave(); //Adjacent Averaging

};
//////////////////////////////////

curve.data$=wcol(jj+2) does not work!
curve.data$=col(%A) also does not work!

It only works when: curve.data$=Data1_%A


Appreciate your help,
Thanks.
1   L A T E S T    R E P L I E S    (Newest First)
autopilot Posted - 02/12/2009 : 08:23:44 AM
Hello,

I have figured out his way now, it works, I would appreciate your comments on the implementation whether it is well supprted by all origin versions (6, 7.5, 8) :)

for(jj=2; jj<=wks.nCols ; jj=jj+3)
{
wks.col=jj+1;
wks.insert(AASm);
curve.data$=%(%h,jj); //input Y
curve.result$=%(%h,jj+1); //output Y
curve.i1=1; //index of 1st data
curve.smoothpts=15; //points for smoothing
curve.adjave(); //Adjacent Averaging


};


The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000