Retrieve Pivot Member Values

R

RAGHAVAN JAYARAMAN

Alvin,
Is there a way to retrieve a Pivot Member Value ( Row Member , Column
Member) . For example i have a Pivot Field Called "Product" and it's dropped
on the Row Axis. It has values like "DEBT" , "EQUITY".
How to retrieve this values. I had a hard time find out.
I know on the client side , we can get the Cell value based on the Selection
and
iterating through the Row and Column Members. I need get this value as when
Pivot Fieldset is inserted to Axis and retrieve all the Member Value.
Any help is appreciated.

Thanks!
 
A

Alvin Bruney - ASP.NET MVP

I'll get back to this on the weekend, kinda busy at the moment (if you can
wait)

--
Regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
The Microsoft Office Web Components Black Book with .NET
Now Available @ www.lulu.com/owc
Forth-coming VSTO.NET - Wrox/Wiley 2006
 
R

RAGHAVAN JAYARAMAN

I somehow managed to get the Corresponding Row Axis value evaluated for the
hyperlink. Now there are some "0" ( Zero ) values for the Calculated Field.
I Shouldn't display Hyperlink , whenever the values Contains "0" . The
following is on PivotDetailRange (Detail Field ) for Trade Count Calculated
field with Hyperlink. [ Is there any MDX formula so that i can show
Hyperlink for only positive values ]

I have already pre-built the Metadata with @STARTDATE and @ENDDATE and
evaluating the Hyperlink for each User Click.

szTmp = "[" + DetailSet.Fields[0].Name + "]";
int iPos = sHyperlink.IndexOf("@STARTDATE");
if (iPos != -1)
{
string szNewVal1 = "[" + pivotView.FieldSets["Extract Start
Date"].Fields[0].Name + "]";
string szNewVal2 = "[" + pivotView.FieldSets["Extract End
Date"].Fields[0].Name + "]";
szNewVal1 = "\"\"\"+" + szNewVal1 + "+\"\"\"";
szNewVal2 = "\"\"\"+" + szNewVal2 + "+\"\"\"";
sHyperlink = sHyperlink.Replace("@STARTDATE",szNewVal1);
sHyperlink = sHyperlink.Replace("@ENDDATE",szNewVal2);
}
szExpression = szTmp + "+\"#" + sHyperlink + "#\"";
sNewFld = "Calculated Fld " + iCols ;
PivotFieldSet DetailSetNew = pivotView.AddFieldSet(sNewFld);
PivotField DetailField =
DetailSetNew.AddCalculatedField(sNewFld,sNewFld,sNewFld,szExpression.ToString());
DetailSetNew.Caption = sColumnName; //DetailSet.Caption;
DetailField.Caption = sColumnName; //DetailSet.Fields[0].Caption;
DetailSet.DisplayInFieldList = false;
DetailField.IsHyperlink = true;
pivotView.DataAxis.InsertFieldSet(DetailSetNew,null,true);

Also i need to get these Values on the Cell Selection(client side). I know
how to do for Pivot Totals for Cube and how can i capture the Current Cell
Value for Pivot Details ( pivotDetailRange) on the Drillthrough event.
Please check my other related thread.
" How to retrieve Pivot Detail Cell Value ". I need this so that i can save
OWC getting replaced by Cognos / RS 2005. Im not sure if these tools could
achieve this.

Thanks!

Alvin Bruney - ASP.NET MVP said:
I'll get back to this on the weekend, kinda busy at the moment (if you can
wait)

--
Regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
The Microsoft Office Web Components Black Book with .NET
Now Available @ www.lulu.com/owc
Forth-coming VSTO.NET - Wrox/Wiley 2006
-------------------------------------------------------



RAGHAVAN JAYARAMAN said:
Alvin,
Is there a way to retrieve a Pivot Member Value ( Row Member , Column
Member) . For example i have a Pivot Field Called "Product" and it's dropped
on the Row Axis. It has values like "DEBT" , "EQUITY".
How to retrieve this values. I had a hard time find out.
I know on the client side , we can get the Cell value based on the Selection
and
iterating through the Row and Column Members. I need get this value as when
Pivot Fieldset is inserted to Axis and retrieve all the Member Value.
Any help is appreciated.

Thanks!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top