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 for Programming
 Forum for Origin C
 Navigating the OriginObject

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
drew Posted - 06/06/2008 : 2:29:38 PM
Origin Version (Select Help-->About Origin): 7.5 SR6
Operating System: Windows XP

I'm having trouble finding my way around the OriginObject.

For example:
I create a worksheet where I want to store results from statistic calculations from many different worksheets. I want to flip back and fourth between each worksheet that requires calculations and my results worksheet.

When the results worksheet is not active I can find the WorksheetPage with:
wpResults = Project.WorksheetPages("Results");

However to record my data in the cells I really want the worksheet object. I haven't yet found an easy way to get to the worksheet! Help!

Appreciate any advice. If there is some reading that I have missed to help me understand this please let me know.

Thanks!
2   L A T E S T    R E P L I E S    (Newest First)
drew Posted - 06/12/2008 : 09:55:31 AM
That’s great, just summon it back to life.

Thanks!
greg Posted - 06/10/2008 : 5:12:36 PM
Since one of the Worksheet constructors takes a name you can use:

Worksheet wks(wpResults.GetName());
if(wks.IsValid()) wks.AddCol("NewColumn");
or just
Worksheet wks("Results");
if(wks.IsValid()) wks.AddCol("NewColumn");

Keep in mind that Origin 8 supports Workbooks with multiple Worksheets, but the class still works when referencing the proper name:
Worksheet wks("[Book4]Results"); // Sheet named Results in Book4
if(wks.IsValid()) wks.AddCol("Next2");



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