home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.lang.visual.basic      MS Visual Basic discussions, NOT dot-net      10,840 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 9,000 of 10,840   
   sfgsdfg to sfgsdfg   
   Re: visual basic 6 passing a control arr   
   22 Nov 04 22:17:59   
   
   From: sdfgdf@sdf.com   
      
   tis ok, found a solution in google groups...   
   just changed:   
      
   Private Sub Calc(L() As Control, Total As Control)   
   to   
   Private Sub Calc(L As Variant, Total As Control)   
      
   "sfgsdfg"  wrote in message   
   news:41a263f7$0$117$65c69314@mercury.nildram.net...   
   > Hello, is there a way to pass a control array to a function?   
   > i tried the following which works with normal arrays but not control   
   > arrays:(   
   >   
   > Private Sub Click1_Click()   
   >    Calc txtControlArray, txtSingleControl   
   > End Sub   
   >   
   > Private Sub Calc(L() As Control, Total As Control)   
   >    Dim x As Integer   
   >    Total = ""   
   >   
   >    For x = 0 To L.UBound   
   >        Total = Val(Total) + Val(L(x))   
   >    Next   
   > End Sub   
   >   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca