Welcome,
 Guest User.

  Click to Login   


 FarPoint HOME
 clubFarPoint HOME

SUPPORT
   Forum
   View Your Questions

RESOURCES
   Search
   Articles
   Product Docs
   FAQ
   Training Videos
   Feature Suggestions
   Subscriptions
   User Groups
   FarPoint Blog

DOWNLOAD
   Updates
   Trials

MY ACCOUNT
   Member Benefits
   MVP Status
   RSS Feeds
   Register Product
   View Products
   View Orders
   Order Now
   My Profile
   Product Profiles

   clubFarPoint Feedback...


There are 9 registered members online.


   

Articles
<< Return to Articles
Setting Multiple Columns Visible or Not Using a ParamArray
Submitted By: Gary Winey Last Updated: 11/21/2005 10:44:16 AM
Level: Intermediate  
Product(s): Spread for Windows Forms 2  
Language(s): Visual Basic.NET  
Description: Here are a couple overloaded functions I wrote that allow you to set multiple columns visible or not using a ParamArray.  
 

Introduction

Here are a couple overloaded functions I wrote that allow you to set multiple columns visible or not using a ParamArray.

I'm pretty sure these would work with Web forms also but I don't have time to test them to find out.


Imports FarPoint.Win.Spread

 

Public Class FarPointUtils

    ''' -----------------------------------------------------------------------------

    ''' <summary>

    ''' Converts a ParamArray of columns into individual SetColumnVisible calls. Accepts individual columns (eg 1, 2, 3, 7, 8) or ranges designated by key words Thru, To or dash '-' (eg 2 to 5 or 3 Thru 6 or 2-5). The key words Thru and To are case insensitive. If key words are used the entire phrase MUST be surrounded by double quotes (eg "0 - 4" or "1 to 3").

    ''' </summary>

    ''' <param name="farPointSheet"></param>

    ''' <param name="visible">False to hide column, otherwise True</param>

    ''' <param name="columns">Comma delimited list of columns to affect</param>

    ''' <remarks>

    ''' </remarks>

    ''' <history>

    '''     [glw2]      11/18/2005  Created

    ''' </history>

    ''' -----------------------------------------------------------------------------

    Public Shared Sub SetColumnVisibility(ByVal farPointSheet As FarPoint.Win.Spread.SheetView, _

                                          ByVal visible As Boolean, _

                                          ByVal ParamArray columns() As Object)

        If columns.Length = 0 Then Return

   


Subscribe to the RSS feed!RSS Subscribe


Click for Morrisville, North Carolina Forecast
 
Todays Trivia














FarPoint's Spread for Web Forms

     About Us | Contact UsComments & Suggestions | ©2008 FarPoint Technologies, Inc.