Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Whats wrong in this code?


Domino_
 Share

Recommended Posts

I have problem that My cmbCToolReq doesnt save when I add scrlitem in For i= 1 to max_items
when i delete scrlitem then all works fine… I even tryed but no result....
```
If (frmEditor_Item.cmbType.ListIndex = ITEM_TYPE_RECIPE) Then
            frmEditor_Item.fraRecipe.Visible = True

            frmEditor_Item.scrlRecipeResult1.Value = .RecipeResult1

            For i = 1 To MAX_ITEMS
                frmEditor_Item.scrlItem(i).Value = .RecipeItem(i)
            Next

            For i = 1 To MAX_ITEMS
                frmEditor_Item.cmbCToolReq.AddItem Trim$(Item(i).Name)
            Next i

            frmEditor_Item.cmbCToolReq.ListIndex = .ToolReq
        Else
            frmEditor_Item.fraRecipe.Visible = False
        End If

```
Here is last my try, whos not working…
```

If (frmEditor_Item.cmbType.ListIndex = ITEM_TYPE_RECIPE) Then
            frmEditor_Item.fraRecipe.Visible = True

            frmEditor_Item.scrlRecipeResult1.Value = .RecipeResult1

            For i = 1 To MAX_ITEMS
                frmEditor_Item.scrlItem(i).Value = .RecipeItem(i)
                frmEditor_Item.cmbCToolReq.AddItem Trim$(Item(i).Name)
            Next i

            frmEditor_Item.cmbCToolReq.ListIndex = .ToolReq
        Else
            frmEditor_Item.fraRecipe.Visible = False
        End If

```
FIXED
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...