problem with passing "Page" as parameter

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Karuna

    problem with passing "Page" as parameter

    Hi
    Am newbie to VB script. Am struck with a problem.
    I am trying to use an array of pages ( many pages added
    in "multipage" control).
    And am using a for loop sending each page item to a
    procedure and which would set the property of the page.

    But its failing. I get runtime error as :

    "Run time error :424
    Object required. "

    My code is as follows
    -----------------------

    Private Sub clustInfo()
    Dim hidePageArray
    Dim pageName
    hidePageArray = Array(Page1, Page2, Page3 _
    Page4, Page5, Page6)

    containerInfoPa ge.Visible = True

    For Each hidePageItem In hidePageArray
    sp hidePageItem
    Next hidePageItem
    End Sub

    Private Sub sp(ByVal pg As Page)
    containerInfoPa ge.pg.Visible = True
    End Sub

    PS: Here "containerInfoP age" is name of "multipage" control.
    Also how can i pass entire array it self to the Sub "sp" .

    can some one let me know what is going wrong here ?

    thanks and regds
    bsk
Working...