Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Convert Static Array to Dynamic and choose certain elements 2

Status
Not open for further replies.

waubain

Technical User
Dec 13, 2011
200
US
We recently installed AttachmateReflection for UNIX and OpenVMS Objects on our hospital computers. I have written a vba macro to automate a report I use daily. The macro begins by opening up a UserForm where selections can be made for other parts of the macro, frmHILO is then Hide and the macro continues retriving variable values from frmHILO. In the past I have run the report with all the LOCATIONS in the array below. What I would like to do now is have checkboxes where I can click as few or as many checkboxes as I want to filter the report on specific locations.

From what I have read, I would need to change my static array to a dynamic arrary and ReDim. I am not very familar with arrays, I have not found a similar example to know where to start.

This is my thought process:
In this case there would be 10 new checkboxes named

Label Array elements Checkbox name

ICU 1-8 chkLoc1
5EM 9-11 chkLoc2
5WM 12-14 chkLoc3
5ES 15-17 chkLoc4
5WS 18-20 chkLoc5
7EM 21-23 chkLoc6
7WM 24-26 chkLoc7
7ES 27-29 chkLoc8
7WS 30-32 chkLoc9
9E 33-34 chkLoc10

Dim DynamicArray() As Long

For i = 1 To 10
If frmHILO.Controls("chkLoc" & i).value = True Then
Build the array from the Dynamic array
End If
Next i

ReDim DynamicArray(1 To ??) then run in the code in the ***LOCATION CODE *** section

Any help would be appreciated. Below is the static array and code.

Code:
Dim N As Integer
            
    Dim strLoc(1 To 34) As String
    strLoc(1) = "IC/4WMICU"
    strLoc(2) = "IC/4WM"
    strLoc(3) = "IC/4WMPAL"
    strLoc(4) = "IC/4WMOB"
    strLoc(5) = "IC/4WSICU"
    strLoc(6) = "IC/4WS"
    strLoc(7) = "IC/4WSPAL"
    strLoc(8) = "IC/4WSOB"
    
    strLoc(9) = "IC/5EMOB"
    strLoc(10) = "IC/5EM"
    strLoc(11) = "IC/5EMPAL"
    
    strLoc(12) = "IC/5WMOB"
    strLoc(13) = "IC/5WM"
    strLoc(14) = "IC/5WMPAL"
    
    strLoc(15) = "IC/5ESOB"
    strLoc(16) = "IC/5ESPAL"
    strLoc(17) = "IC/5ES"
    
    strLoc(18) = "IC/5WSOB"
    strLoc(19) = "IC/5WS"
    strLoc(20) = "IC/5WSPAL"
    
    strLoc(21) = "IC/7EMOB"
    strLoc(22) = "IC/7EM"
    strLoc(23) = "IC/7EMPAL"
    
    strLoc(24) = "IC/7WMOB"
    strLoc(25) = "IC/7WM"
    strLoc(26) = "IC/7WMPAL"
        
    strLoc(27) = "IC/7ESOB"
    strLoc(28) = "IC/7ES"
    strLoc(29) = "IC/7ESPAL"
    
    strLoc(30) = "IC/7WSOB"
    strLoc(31) = "IC/7WS"
    strLoc(32) = "IC/7WSPAL"
    
    strLoc(33) = "IC/9WEST"
    strLoc(34) = "IC/9WPOB"
    
    Dim strLocationStrings(1 To 4) As String
    strLocationStrings(1) = "Select LOCATION:"
    strLocationStrings(2) = "Select another LOCATION:"
    strLocationStrings(3) = "CHOOSE 1-3:"
    strLocationStrings(4) = "CHOOSE 1-4:"

'******** LOCATION CODE ***************
          
        For N = LBound(strLoc) To UBound(strLoc)
        
            For i = 1 To 3
        
                Select Case .Parent.Application.WaitForStrings(strLocationStrings, , rcAllowKeystrokes)

                    Case 1
                    If Len(strLoc(N)) > 6 Then
                    .Transmit strLoc(N) & CR
                    Exit For
                    Else: .Transmit strLoc(N) & CR
                    End If
                    
                    Case 2
                    If Len(strLoc(N)) > 6 Then
                    .Transmit strLoc(N) & CR
                    Exit For
                    Else: .Transmit strLoc(N) & CR
                    End If
                    
                    Case 3
                    .Transmit "1" & CR
                    Exit For
                    
                    Case 4
                    .Transmit "1" & CR
                    Exit For
                
                End Select
            Next i
                
        Next N
    
    '******* END LOCATION CODE ************

You don't know what you don't know...
 
waubin,

No worries! I play with dynamic arrays all day long! But before addressing the dynamic arrays, I have a suggestion for your checkboxes: instead of placing numerous checkbox controls on your form and programming for each individual one (which requires re-coding your macro every time one of them changes or a new one is added), use a simple listbox control and change it to a check-listbox. You do this by adding a normal listbox control to your form and then changing the MultiSelect property of the list box to "1-fmMultiSelect" and the ListStyle property to "1-fmListStyleOption". Now the user can simply scroll through the list box and check the desired reports; and you can modify the reports without much coding.

In addition to this, you can add additional hidden columns to the listbox by changing the ColumnCount property and then adjusting the ColumnWidths. For example your listbox could contain all of the information in it like this:

These things never format well when you post them, so I hope it makes sense
Code:
Column 1		Column 2
(Not Visible)		(Visible to User)
IC/4WMICU		ICU 1-8
IC/4WM 		5EM 9-11 
IC/4WMPAL		5WM 12-14
IC/4WMOB 		5ES 15-17 
IC/4WSICU 		5WS 18-20 
IC/4WS 		7EM 21-23 
And so forth....

In this set up, the user would only see the second column in the list box with checkboxes next to them. The first column, which is hidden, contains the name of the report for each associated location. You can then easily add these report names to your array as you cycle through the listbox to see which items have been checked. To make a column invisible, set the ColumnCount property to 2, and change the ColumnWidths property to “0 pt” (you only need to specify the since of the first column, it will assume the second column takes up the rest of the space.

Okay, now to answer your question about arrays, then we’ll come back to this thought. To create a dynamic array you dimension it without any parameters:
Code:
Dim strLoc(1 to 34) As String  	‘-- This is a static array
Dim strLoc() As String 	‘-- This is a dynamic array

If you want to resize the array and completely erase everything that was previously in it, you would use the following (assume intCount is some variable you previously defined):
Code:
Redim strLoc(1 to intCount)

But, if you want to resize the array and KEEP all of the information that was previously in it, you would use this (assume intCount is some variable you previously defined):
Code:
Redim Preserve strLoc(1 to intCount)
If you want to resize a 2-dinemsional array, you would use the following format (assume intRowCount and intColumnCount are two variables that you previously defined):
Code:
Redim Preserve strLoc(1 to intRowCount, 1 to intColumnCount)

However, when working with a 2-dimensional array, you can only resize the rows once. You can continue to resize the number of columns, but not the rows. For example, the next time you resize the array you could only do this:

Code:
    Dim strLoc() As String
    Dim intColumnCount As Integer
    Dim F As Integer
    
    intColumnCount = 1
    ReDim strLoc(1 To 7, 1 To intColumnCount)  '(7 is just an arbitrary number)
    strLoc(1, intColumnCount) = "stuff " & intColumnCount
    For F = 1 To 12
        intColumnCount = intColumnCount + 1
        ReDim Preserve strLoc(1 To 7, intColumnCount) '(Note: 7 does not change)
        strLoc(1, intColumnCount) = "stuff " & intColumnCount
    Next F

A note on the use of UBound and LBound functions: They work so long as your array is not empty. If the array is empty, meaning it has not been sized, then these two functions will cause your program to crash. When using them, create an extra variable to hold the upper and lower bounds of your array, like so:
Code:
Dim intUBount As Integer
Dim bytLBound As Byte

intUBound = -1 ‘This step will tell you if a 0 – base array is empty
On Error Resume Next
bytLBound = LBound(strLoc)
intUBound = UBound(strLoc)
On Error Goto 0

For N = bytLBound to intUBound
	…whatever you need to do…
Next N

If you are using Option Base 1 at the top of your module, then you don’t need to worry about the LBound, it will always be 1, so long as you created this array yourself. However, if you used one of the VBA string functions to return an array, such as the Split() function, it will return an array with a base of 0 even if you have Option Base 1 at the top of your module. If you decide to use Option Base 1, you should place it at the top of all of your modules and forms, similar to Option Explicit, unless you have a need for 0 based arrays.

You can also completely erase a dynamic array and start completely over (as if it had never been resized) by using the Erase command.
Code:
Erase strLoc()

So, back to the example of using the listbox. To populate the listbox you would use something like the following:

Code:
Private Sub UserForm_Initialize()
    Dim strOptions(1 To 5, 1 To 2) As String
    Dim F As Integer
    
(Ideally you would read in the locations and their respective code strings into a dynamic array from a spreadsheet so that the only thing you ever need to change is the spreadsheet, but for simplicity I have used a static 2-dimensional array called strOptions.)

    strOptions(1, 1) = "IC/4WMICU"
    strOptions(1, 2) = "ICU 1-8"
    strOptions(2, 1) = "IC/4WM"
    strOptions(2, 2) = "5EM 9-11"
    strOptions(3, 1) = "IC/4WMPAL"
    strOptions(3, 2) = "5WM 12-14"
    strOptions(4, 1) = "IC/4WMOB"
    strOptions(4, 2) = "5ES 15-17"
    strOptions(5, 1) = "IC/4WSICU"
    strOptions(5, 2) = "5WS 18-20"
    
    With lstLoc
        For F = 1 To 5
	‘Remember, the List property and Index property of a ListBox control 
‘both use base 0, even though the ListCount property returns the total 
‘number of list items in base 1.

            .AddItem strOptions(F, 1)	
‘This will go in the first column, Column 0, which is invisible
            .List(.ListCount - 1, 1) = strOptions(F, 2)	
‘This will go into the second column, Column 1, which is visible to the user
        Next F
    End With
End Sub

Now, to RETRIEVE the selected items, and build your dynamic array, you will do the following:

Code:
Private Sub cmdBuildReport_Click()
    Dim strLoc() As String
    Dim intCount As Integer
    Dim F As Integer
    Dim N As Integer
    Dim strLoc(1 To 34) As String
    Dim strLocationStrings(1 To 4) As String
    
    For F = 1 To lstLoc.ListCount
        If lstLoc.Selected(F - 1) = True Then
            intCount = intCount + 1
            ReDim Preserve strLoc(1 To intCount)
            strLoc(intCount) = lstLoc.List(F - 1, 0)
        End If
    Next F
    
    strLoc(1) = "IC/4WMICU"
    strLoc(2) = "IC/4WM"
    strLoc(3) = "IC/4WMPAL"
    strLoc(4) = "IC/4WMOB"
    strLoc(5) = "IC/4WSICU"

    
    strLocationStrings(1) = "Select LOCATION:"
    strLocationStrings(2) = "Select another LOCATION:"
    strLocationStrings(3) = "CHOOSE 1-3:"
    strLocationStrings(4) = "CHOOSE 1-4:"
    
    '******** LOCATION CODE ***************
	(Place your location code here)
End Sub

Hope this helps, and hopefully it’s not too much for you to take in.


-Joshua
If it's not broken, it doesn't have enough parts yet.
 
Wow, the code looks really garbled if you are looking at this page with internet explorer. But firefox seems to show decently.

-Joshua
If it's not broken, it doesn't have enough parts yet.
 
On that last code example when building the array from the list box I forgot to erase your old code (I had pasted it as a reference when I was building my code). Ignore the part where it says:
strLoc(1) = "IC/4WMICU"
strLoc(2) = "IC/4WM"
strLoc(3) = "IC/4WMPAL"
strLoc(4) = "IC/4WMOB"
strLoc(5) = "IC/4WSICU"

-Joshua
If it's not broken, it doesn't have enough parts yet.
 
Joshua,
Thanks for the detailed reply. I looked this morning from home with FireFox and the code looked orderly, intimidating, but readable. I am looking at work now with IE and it is a jumbled mess.

It might take a while to wrap my mind around it, but did not want too much time to elaspe to say thanks.

Waubain

You don't know what you don't know...
 
>the code looks really garbled if you are looking at this page with internet explorer

A fix is being worked on.
 
FYI, there are TWO Attachmate forums, forum99 & forum1.

Skip,

[glasses]Just traded in my old subtlety...
for a NUANCE![tongue]
 
Two things.
1) This is not quite what I was thinking but that is my fault for lack of an adequate explanation. I will get back to that later.

2) I am getting an error: Run-time Error '9' "Subscript is Out of Range" when I run the macro with the new code.

The DeBug highlights the line, which probably really has to do with the bounds.
Code:
If Len(strLoc(N) > 6 Then

I feel the Userform is correct. I put in two MsgBox for intUBound and byteLBound. Both came back as 0(zero).This is the code pertaining to my the array.

Code:
Option Base 1
Const MaxChkBox As Integer = 5

Sub HILO_Report()
 
    ' *********************************
    '
    ' Author: Waubain
    ' New: 6/7/2012
    ' Purpose: Automate daily printing of Pharmacy Hi Lo Drug Levels
    '
    ' *********************************
 
    On Error GoTo ErrorHandler ' Error Handle
    
    Dim strLoc() As String
    Dim strEndDate As String
    Dim i As Integer
    Dim strPrinter As String
    Dim strReadline As String
    Dim N As Integer
    Dim F As Integer
    Dim intCount As Integer
    Dim intUBound As Integer
    Dim byteLBound As Byte
    
    On Error Resume Next
    byteLBound = LBound(strLoc)
    intUBound = UBound(strLoc)
    On Error GoTo 0
    
    
    For F = 1 To frmHILOTEST.lstLoc.ListCount
        If frmHILOTEST.lstLoc.Selected(F - 1) = True Then
            intCount = intCount + 1
            ReDim Preserve strLoc(1 To intCount)
            strLoc(intCount) = frmHILOTEST.lstLoc.List(F - 1, 0)
        End If
    Next F
    
    Dim strLocationStrings(1 To 4) As String
    strLocationStrings(1) = "Select LOCATION:"
    strLocationStrings(2) = "Select another LOCATION:"
    strLocationStrings(3) = "CHOOSE 1-3:"
    strLocationStrings(4) = "CHOOSE 1-4:"
        
    LF = Chr(10) ' set LF as LineFeed - Chr(rcLF) = Chr(10)
    CR = Chr(13)  ' Sets CR as Carriage ReturnCR - Later Chr(rcCR) = Chr(13) = Carriage return
    
    '***********
    '
    '.....skipping other code not relevant to this problem....
    '
    '******** LOCATION CODE ***************

        MsgBox byteLBound, vbOKOnly, "Lower Bound"   ' reports as 0
        MsgBox intUBound, vbOKOnly, "Upper Bound"    ' reports as 0
        
        For N = byteLBound To intUBound
        
            For i = 1 To 3
        
                Select Case .Parent.Application.WaitForStrings(strLocationStrings, , rcAllowKeystrokes)

                    Case 1
                    If Len(strLoc(N)) > 6 Then    'this line is highlighted
                    .Transmit strLoc(N) & CR
                    Exit For
                    Else: .Transmit strLoc(N) & CR
                    End If
                    
                    Case 2
                    If Len(strLoc(N)) > 6 Then
                    .Transmit strLoc(N) & CR
                    Exit For
                    Else: .Transmit strLoc(N) & CR
                    End If
                    
                    Case 3
                    .Transmit "1" & CR
                    Exit For
                    
                    Case 4
                    .Transmit "1" & CR
                    Exit For
                
                End Select
            Next i
                
        Next N
    
    '******* END LOCATION CODE ************

Any help on the above appreciated.

...So back to what I was originally thinking and did not verbalize well and I will simplify. There are 3 pharmacists that cover 3 areas in the hospital. This report gathers data on drug levels based on other portions of the code in the macro looking for high and low values. In my original macro it lists 34 virtual places a patient can be admitted to and have a drug level but in reality their are only three physical places: ICU, Floor, Psych (which correspond to 3 pharmacists). The way it is currently set up is with 34 checkboxes in a listbox.

What I was thinking was to have 3 checkboxes (checkbox or listbox).
The ICU checkbox would combine array elements 1 to 8, Floor combines eleements 9 to 32, and Psych combines elements 33 to 34). This way each pharmacist would have their own report for their area or in the event one pharmacist was sick the covering pharmacist could check any two boxes or all three if needed.

Sorry for any confusion but appreciative of all the help offered here. Either way I have learned something new....Waubain





You don't know what you don't know...
 
waubain,

Excellent try! Here is what is happening:
You declared your variables, then before you have done anything with the array you are checking the size of it. Of course it is going to come back with UBound and LBound of zero - it hasn't been sized yet. Then you fill your array with the desired data, but proceed to process your location codes without checking to see what the new size of the array is. Since you are using Option Base 1, when you resize your array the lower bound is automatically 1, but in your For... Next loop you are calling for and index if 0 (remember, bytLBound and intUBound are still zero because you didn't re-check), which doesn't exist.

Solution:
Code:
    ' *********************************
    '
    ' Author: Waubain
    ' New: 6/7/2012
    ' Purpose: Automate daily printing of Pharmacy Hi Lo Drug Levels
    '
    ' *********************************
    
    Dim strLoc()                    As String
    Dim strEndDate                  As String
    Dim i                           As Integer
    Dim strPrinter                  As String
    Dim strReadline                 As String
    Dim N                           As Integer
    Dim F                           As Integer
    Dim intCount                    As Integer
    Dim intUBound                   As Integer
    Dim bytLBound                   As Byte
    Dim lngButtons                  As VbMsgBoxStyle
    Dim strLocationStrings(1 To 4)  As String
    
    'Keep declerations at the top
    On Error GoTo ErrorHandler ' Error Handle
    
    For F = 1 To frmHILOTEST.lstLoc.ListCount
        If frmHILOTEST.lstLoc.Selected(F - 1) = True Then
            intCount = intCount + 1
            ReDim Preserve strLoc(1 To intCount)
            strLoc(intCount) = frmHILOTEST.lstLoc.List(F - 1, 0)
        End If
    Next F

    [highlight]On Error Resume Next[/highlight]
    [highlight]bytLBound = LBound(strLoc)[/highlight]
    [COLOR=darkgreen]'the bytLBound portion is really not necessary since you use Option Base 1. You know it
    'will be 1, unless you used some other source to return this array to you[/color]
    [highlight]intUBound = UBound(strLoc)[/highlight]
    [highlight]On Error GoTo 0[/highlight]
    [COLOR=darkgreen]'Note: Here you canceled out your statement up top to go to the error handler.
    'If you wish to continue this statement, you need to add it again after
    'the On Error Goto 0 statement
    '(On Error Goto 0 resets the error code to 0 if there was one)[/color]
    
    strLocationStrings(1) = "Select LOCATION:"
    strLocationStrings(2) = "Select another LOCATION:"
    strLocationStrings(3) = "CHOOSE 1-3:"
    strLocationStrings(4) = "CHOOSE 1-4:"
        
    LF = Chr(10) ' set LF as LineFeed - Chr(rcLF) = Chr(10)
    CR = Chr(13)  ' Sets CR as Carriage ReturnCR - Later Chr(rcCR) = Chr(13) = Carriage return
    
    '***********
    '
    '.....skipping other code not relevant to this problem....
    '
    '******** LOCATION CODE ***************

        [COLOR=darkgreen]'If you want to use a message box you could do it this way[/color]
        lngButtons = vbOKOnly + vbDefaultButton1 + vbApplicationModal + vbInformation
        MsgBox byteLBound, lngButtons, "Lower Bound"   ' reports as 0
        MsgBox intUBound, lngButtons, "Upper Bound"    ' reports as 0
        
        [COLOR=darkgreen]'Or just use Debug.Print to display the value in the Immediate Window[/color]
        Debug.Print "Upper Bound: " & intUBound
        Debug.Print "Lower Bound: " & bytLBound
        
        'Here you could just say For N = 1 to intUBound
        For N = byteLBound To intUBound
        
            For i = 1 To 3
        
                Select Case .Parent.Application.WaitForStrings(strLocationStrings, , rcAllowKeystrokes)

                    Case 1
                    If Len(strLoc(N)) > 6 Then    'this line is highlighted
                    .Transmit strLoc(N) & CR
                    Exit For
                    Else: .Transmit strLoc(N) & CR
                    End If
                    
                    Case 2
                    If Len(strLoc(N)) > 6 Then
                    .Transmit strLoc(N) & CR
                    Exit For
                    Else: .Transmit strLoc(N) & CR
                    End If
                    
                    Case 3
                    .Transmit "1" & CR
                    Exit For
                    
                    Case 4
                    .Transmit "1" & CR
                    Exit For
                
                End Select
            Next i
                
        Next N

-Joshua
If it's not broken, it doesn't have enough parts yet.
 
This is very frustrating. Usually I can figure these things out with a little help but I cannot understand why it is not working.

I made all the changes that Joshua recommended. When I run through the macro this portion never even runs. The macro completes because next line after this portion of the code is a hard return with would accept the ALL Locations default from the host program. I am also assuming this is not a multidimensional array, even though the form list box has 2 columns only one column values is used in the array.

Code:
For N = 1 To intUBound
        
            For i = 1 To 3
               Select Case .Parent.Application.WaitForStrings(strLocationStrings, , rcAllowKeystrokes)
                    Case 1
                    If Len(strLoc(N)) > 6 Then    'this line is highlighted
                    .Transmit strLoc(N) & CR
                    Exit For
                    Else: .Transmit strLoc(N) & CR
                    End If
                    Case 2
                    If Len(strLoc(N)) > 6 Then
                    .Transmit strLoc(N) & CR
                    Exit For
                    Else: .Transmit strLoc(N) & CR
                    End If
                    Case 3
                    .Transmit "1" & CR
                    Exit For
                    Case 4
                    .Transmit "1" & CR
                    Exit For
                End Select
            Next i
        Next N

Things that I have tried, and observed. It seems to have something to do with UBound or the array is not dimensioned (if that is the correct term)
If I comment out 'intUBound = UBound(strLoc) and replace N = 1 To intUBound with N = 1 TO UBound(strLoc) the macro will run when it gets to the Location code portion of the code I will get a "Subscript out of Range" error. If I click ok and finish the host program myself and then rerun the macro, the UserForm will open and all my checkboxes that I clicked on the first try are still there, like the form was never reinitialize. The macro will then run and fill in all the checked locations just like it should (now knows the value of UBound ??). The form never seems to reinitialize. I put an Erase strLoc() before the Sub Ends but that does not fix that issue. Also it if click more boxes than I originally clicked those are ignored, like the array is already built.

I hate to come back yet another time, but will give it one more try. Thanks again.

You don't know what you don't know...
 
waubain,

Frustrating indeed! I also experienced many of these pains when I was learning. But despair not my young dynamic-multidimensional padawan, I will see this through to the end… assuming I’m not working night shifts and the plant is not about to explode. So let’s address some of the comments you made:

The macro completes because next line after this portion of the code is a hard return with would accept the ALL Locations default from the host program.

Disable that All-Locations default until we get this puppy fixed. That will just garble up results and confuse us all.

It seems to have something to do with UBound or the array is not dimensioned (if that is the correct term). If I comment out 'intUBound = UBound(strLoc) and replace N = 1 To intUBound with N = 1 TO UBound(strLoc) the macro will run when it gets to the Location code portion of the code I will get a "Subscript out of Range" error.

If the array is not dimensioned then the UBound() function will give you a “Run-time error ‘9’: Subscript out of Range” error. Unless I’m on my wife’s computer, in which case it gives the following:
Laufzeitfehler ‘9’:
Index außerhalb des gültigen Bereichs

That’s why I always stick with an intUBound variable. It saves my program from crashing and I don’t have to try to translate strange German error messages. If intUBound is coming back 0, and you are using Option Base 1, then you know that the array doesn’t have anything in it. Now on the other hand, if you are not using Option Base 1, which I know you are in this case, but if you are not then you should set intUBound to -1 before determining the length of the array. Otherwise you won’t know whether it is 0 because the array was empty and it passed over the code or if it is 0 because it is a zero-base array with one element in it (index of 0).

If I click ok and finish the host program myself and then rerun the macro, the UserForm will open and all my checkboxes that I clicked on the first try are still there, like the form was never reinitialize. The macro will then run and fill in all the checked locations just like it should (now knows the value of UBound ??). The form never seems to reinitialize.

Are you fully unloading the form, or simply hiding it? If you simply hide it then it will not reinitialize when you view it again. It will pick up where it was left when you hid the form. If you want to start afresh, use the following:

Code:
WhatEverTheFormNameIs.Hide   (or simply, Me.Hide, if the code is placed within the form itself)
Unload WhatEverTheFormNameIs  (or simply, Unload Me)

I’m going to need to see the rest of your code in order to figure out what is going on. Post your entire procedures for initializing the form and forming the arrays to make the data request. If there is any sensitive information then be sure to replace it with fake information.



-Joshua
If it's not broken, it doesn't have enough parts yet.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top