DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

+ Reply to Thread
Results 1 to 3 of 3

Hybrid View

  1. #1
    Join Date
    Dec 2005
    Posts
    12

    Returning Object Arrays

    Hello,

    I have (what I believe is) a simple syntax issue wrt returning user-defined object arrays:

    Say I have a class clsGx that I am implementing as an array Gx(maxIndices):

    And say, after population, I want to pass it to a function that returns another array of clsGx instances (Gx2(maxIndices))as follows

    Set Gx2 = exch(Gx)

    With exch being defined as follows:

    Private Fuction exch(Gx() As clsGx) as clsGx
    ...
    End Function


    Currently, I am receiving a compile errors including can't assign to array. Any suggestions?

  2. #2
    Join Date
    Nov 2003
    Location
    Portland, OR
    Posts
    8,387
    Phil Weber
    http://www.philweber.com

    Please post questions to the forums, where others may benefit.
    I do not offer free assistance by e-mail. Thank you!

  3. #3
    Join Date
    Nov 2003
    Location
    Alameda, CA
    Posts
    1,737
    you forgot the last couple of parenthesis (the function is returning an array):

    Private Fuction exch(Gx() As clsGx) as clsGx()

    Marco
    "There are two ways to write error-free programs. Only the third one works."
    Unknown

Similar Threads

  1. Replies: 2
    Last Post: 07-05-2002, 12:29 PM
  2. Replies: 0
    Last Post: 05-08-2002, 08:22 AM
  3. Validating XML
    By Jaco de Villiers in forum XML
    Replies: 1
    Last Post: 06-01-2001, 05:50 PM
  4. Returning arrays from object?
    By Mike in forum ASP.NET
    Replies: 0
    Last Post: 07-07-2000, 05:39 AM
  5. Re: COM object Password Security
    By Tom Shreve in forum Enterprise
    Replies: 0
    Last Post: 04-07-2000, 08:15 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


Top DevX Stories

Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL


Sponsored Links