Labels

From OriginLab Wiki

(Difference between revisions)(Link to this page as [[OriginCOM:Worksheet-Labels]])
Jump to: navigation, search
Revision as of 20:54, 16 July 2008 (edit)
Cieland (Talk | contribs)
(Parameters)
← Previous diff
Revision as of 10:02, 20 August 2008 (edit) (undo)
Uploader (Talk | contribs)

Next diff →
Line 18: Line 18:
==Parameters== ==Parameters==
-;pattern+ 
-:A string of patterns, which can be specified by assembling [[LabTalk:Column_Label_Row_Characters#Even_Sampling_Interval|Column Label Row Characters]]+
==Return== ==Return==
Line 28: Line 27:
==Examples== ==Examples==
-===VBA===+ 
-Connect to the running Origin(please make sure that there are two sheets in Book1). We will set some labels in the two sheets to visible, and set content to these labels. You will see result in Origin.+
-<vb>+
-Public Sub setLabelVisible()+
- Dim app As Origin.ApplicationSI+
- Dim Wks1 As Origin.Worksheet+
- Dim Wks2 As Origin.Worksheet+
- Dim Data(1 To 100) As Double+
- Dim bRet As Boolean+
- Dim ii As Integer+
- For ii = 1 To 100+
- Data(ii) = ii * 0.375 + 274+
- Next+
- +
- Set app = New Origin.ApplicationSI+
- Set Wks1 = app.FindWorksheet("[Book1]Sheet1")+
- Set Wks2 = app.FindWorksheet("[Book1]Sheet2")+
- +
- 'Set labels to visible+
- Wks1.Labels ("LSE") 'Set "LongName", "Spark line" and "Even Sampling" labels of Sheet1 are visible+
- Wks2.Labels ("UC") 'Set "Units", "Comments" labels of Sheet2 are visible+
- +
- 'Set Column's LongName+
- Wks1.Columns(0).LongName = "Temperature" 'Set LongName of the first column on Sheet1+
- Wks2.Columns(0).Units = "kPa" 'Set Units of the first column on Sheet2+
- Wks2.Columns(0).Comments = "example" 'Set Comments of the first column on Sheet2+
- +
- 'Set even sampling+
- bRet = Wks1.Columns(0).SetEvenSampling(0, 20)+
- +
- 'Send data to the column+
- Wks1.Columns(0).SetData (Data)+
- Wks2.Columns(0).SetData (Data)+
- +
-End Sub+
-</vb>+
-===C#===+
==Version Information== ==Version Information==
Line 70: Line 33:
==See Also== ==See Also==
-[[OriginCOM:Worksheet-LabelVisible|LabelVisible]] | [[OriginCOM:OriginObject-Name|Column.Name]] | [[OriginCOM:OriginObject-LongName|Column.LongName]] | [[OriginCOM:Column-Type|Column.Type]] | [[OriginCOM:Column-Units|Column.Units]] | [[OriginCOM:Column-Comments|Column.Comments]]  
- 
- 
-[[Category:P0|Sarah]] 

Revision as of 10:02, 20 August 2008


Contents

Description

Syntax

VB: Sub Labels(pattern As ByVal String ) As void
C++: void Labels(LPCSTR pattern )
C#: void Labels(string pattern )

Parameters

Return

Remark

Examples

Version Information

8.0SR2

See Also