Hi, Afzalz!
In visual basic this job can be done by the next code:
Dim dsoCube as As DSO.MDStore
Set dsoCube = dsoDB.MDStores("MyCube"
Dim dsoCalculatedMember As DSO.Command
Set dsoCalculatedMember = dsoCube.Commands.AddNew("MyCalc"
dsoCalculatedMember.CommandType = cmdCreateMember
'set the MDX statement that defines the calculated member
dsoCalculatedMember.Statement = "CREATE MEMBER MyCube.Measures.[MyCalc] AS '#WRITE HERE YOUR CALCULATED MEMBER FORMULA#'"
dsoCube.Update
please, notify me if it helped you to solve your problem
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.