Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

command to get a label name in MDL scripting

Status
Not open for further replies.

sanand71

Programmer
Dec 22, 2003
5
CA
Hi All

I am trying to set the label of a particular category using the specialcatupdate "Cname" Label "LName". However instead of using a label name as a string, I want to do get the name for another category in the cube and concatenate this with a fixed text and set this value as the Label Name. Is it possible to do this. Appreciate any help. thks

 
Sanand
The .Name will get or set the label for either the category (dimension) or the level

For the "Dates" Category:
Set objDimension = objModel.Dimensions.Item("Dates")
strlabel = objDimension.Name

For the "Month" Level of the "Dates" category:
Set objDimension = objModel.Dimensions.Item("Dates")
Set objLevel = objDimension.drilldowns(1).Levels("Month")
strlabel = objLevel.Name

HTH,
lex

"Time flies like an arrow, but fruit flies like a banana."
 
Hi lex

believe this will work only in a macro. I am trying to do this in mdl scripting. any ideas. thks
 
Sanand,
Apologies - should have considered your post title fully! Still, if it is a supported function in cognos script, then shows OLE automation is possible.
[happy]
lex


"Time flies like an arrow, but fruit flies like a banana."
 
hi

thks for the reply

I am on a unix box so believe ole would not work as well. what i am looking for is a way to script the change of labels so that i can automate the process on unix. any ideas. thks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top