public void getQuickLaunchJson( ref ViewSelect.Response.Category Category )
        {
            CswTableSelect SessionDataSelect = _CswNbtResources.makeCswTableSelect( "getQuickLaunchXml_select", "session_data" );
            Collection<OrderByClause> OrderBy = new Collection<OrderByClause>();
            OrderBy.Add( new OrderByClause( SessionDataColumn_PrimaryKey, CswEnumOrderByType.Descending ) );

            string WhereClause = @"where " + SessionDataColumn_SessionId + "='" + _CswNbtResources.Session.SessionId + "' and "
                                 + SessionDataColumn_QuickLaunch + " = '" + CswConvert.ToDbVal( true ).ToString() + "'";
            DataTable SessionDataTable = SessionDataSelect.getTable( WhereClause, OrderBy );

            Int32 RowCount = 0;
            foreach( DataRow Row in SessionDataTable.Rows )
            {
                bool KeepInQuickLaunch = CswConvert.ToBoolean( Row[SessionDataColumn_KeepInQuickLaunch] );
                if( KeepInQuickLaunch )
                {
                    _addQuickLaunchProp( Row, Category );
                }
                else if( RowCount < 5 )
                {
                    _addQuickLaunchProp( Row, Category );
                    RowCount++;
                }
            }
        } // getQuickLaunchJson()
 private void _addQuickLaunchSearch( ViewSelect.Response.Category Category, string Text, CswNbtSessionDataId SessionDataId )
 {
     Category.items.Add(
         new ViewSelect.Response.Item( CswEnumNbtViewItemType.Search )
         {
             name = Text,
             itemid = SessionDataId.ToString(),
             iconurl = CswNbtMetaDataObjectClass.IconPrefix16 + "magglass.png"
         } );
 }
 private void _addQuickLaunchAction( ViewSelect.Response.Category Category, string Text, CswNbtSessionDataId SessionDataId, CswNbtAction Action )
 {
     Category.items.Add(
         new ViewSelect.Response.Item( CswEnumNbtViewItemType.Action )
         {
             name = Text,
             itemid = SessionDataId.ToString(),
             iconurl = CswNbtMetaDataObjectClass.IconPrefix16 + Action.IconFileName,
             url = CswConvert.ToString( Action.Url )
         } );
 }
        } // _addQuickLaunchProp()

        private void _addQuickLaunchView( ViewSelect.Response.Category Category, string Text, CswNbtSessionDataId SessionDataId, string ViewMode )
        {
            Category.items.Add(
                new ViewSelect.Response.Item( CswEnumNbtViewItemType.View )
            {
                name = Text,
                itemid = SessionDataId.ToString(),
                iconurl = "Images/view/view" + ViewMode.ToString().ToLower() + ".gif",
                mode = ViewMode
            } );
        }
        } // getQuickLaunchJson()

        private void _addQuickLaunchProp( DataRow Row, ViewSelect.Response.Category Category )
        {
            Int32 ItemId = CswConvert.ToInt32( Row[SessionDataColumn_PrimaryKey] );

            CswEnumNbtSessionDataType SessionType = CswConvert.ToString( Row[SessionDataColumn_SessionDataType] );
            string Name = Row[SessionDataColumn_Name].ToString();
            CswNbtSessionDataId SessionDataId = new CswNbtSessionDataId( ItemId );

            if( SessionType == CswEnumNbtSessionDataType.Action )
            {
                Int32 ActionId = CswConvert.ToInt32( Row[SessionDataColumn_ActionId] );
                CswNbtAction Action = _CswNbtResources.Actions[ActionId];
                _addQuickLaunchAction( Category, Name, SessionDataId, Action );
            }
            else if( SessionType == CswEnumNbtSessionDataType.View )
            {
                //Int32 ViewId = CswConvert.ToInt32( Row[SessionDataColumn_ViewId] );
                _addQuickLaunchView( Category, Name, SessionDataId, Row[SessionDataColumn_ViewMode].ToString() );
            }
            else if( SessionType == CswEnumNbtSessionDataType.Search )
            {
                _addQuickLaunchSearch( Category, Name, SessionDataId );
            }
        } // _addQuickLaunchProp()