Posts in "dev"

Multiple IIf Logic Block

IIf function often used in MultiDimensionalExpression (MDX), It’s quiet simple to implement single block of IIf block. This an example of Multiple IIf logic block. Example1:

If…Then..Else… in MultiDimensionalExpression

A logical script in MDX to perform an “If..Then.. Else..” block.

Example1:The following example returns 0 if Measures.CurrentMember is an empty cell, 1 otherwise:

Example2:The following string returns the string “Yes” if Measures.CurrentMember is an empty cell, the string, “No” otherwise:

Example3:

Example4:Average Sales (Measure) By Time Day (Dimension)

Source:… Continue reading

Relative Contribution to Total Value (Percentage)

There’s a few scenario to calculate a percentage of a measure in OLAP CUBE (Analysis Service 2000). A Percentage is common calculation in MDX , and it can be solved by divide a measure to  total value (Grand Total). Sample 1:Measures.[Value Contribution to Total]:

Sample 2:Measures.[Value Contribution to Total]:

Sample 3:Measures.[Product Contribution to… Continue reading

Encrypt and Decrypt Web.Config (Connection Strings, etc) from ASP Page

Example: How to encrypt/decrypt connectionStrings and SessionState section on Web.Config file? This is a codebehid sample script written on C# to perform Encrypt and Decrypt procedure against few items on Web.Config file. Single ASP.NET page can perform this task easily, so you don’t have to write any code in command prompt. Declare this namespace:

Continue reading

MapGuide Open Source (MGOS)

I always looking for free web gis server with dotnet framework capabilities. Mostly everything that related with dotnet came with a charge. Recently i found that autodesk start their web gis opensource project, the MapGuide Open Source Project (MGOS). Surely it can run on dotnet framework and it’s free. MapGuide Open Source is a web-based… Continue reading

Sharpmap

One of my favorite geographic Information System (gis) web server is Sharpmap. It runs on dotnet 2.0 and using ASP.NET(C#) language. I like Sharmap, because it’s open source and free . The web server it self didn’t need any additional software/component to install. Just pure dotnetframework (v.2.0). So it can be easily deploy on common… Continue reading