|
-
Jan 10th, 2007, 09:30 AM
#1
Thread Starter
Lively Member
Help with code placement
Hi, wher i tend to use
User(Index).Item(ItemNo) = -1
effects the code.
where it is now, i dont get the msg "you stashed a"
and if i use it at the end then i dont get the last msgbox saying false, and this
might be why its not saving properly.
dont need the msgboxes, just added them to test it.
can somebody help sort it out
VB Code:
Public Sub Sta****em(Index As Integer, ByVal ItemNo As Integer)
On Error Resume Next
'MsgBox Item(User(Index).Item(ItemNo)).IName
'MsgBox Item(User(Index).Item(ItemNo)).OnPlayer
User(Index).Item(ItemNo) = -1
frmMain.wsk(Index).SendData Chr$(2) & "You just stashed a " & Item(User(Index).Item(ItemNo)).IName & vbCrLf & vbCrLf & Chr$(0)
Item(User(Index).Item(ItemNo)).OnPlayer = False
Call UpdateSingleItem(Index, ItemNo)
Call UpdateGeneralInfo(Index)
'MsgBox Item(User(Index).Item(ItemNo)).OnPlayer
End Sub
Last edited by totaly; Jan 10th, 2007 at 09:38 AM.
Reason: filtered word is actually stash item
-
Jan 10th, 2007, 09:39 AM
#2
Re: Help with code placement
first thing to do is to get rid of On Error Resume Next, then see what your code does.
-
Jan 10th, 2007, 09:48 AM
#3
Re: Help with code placement
 Originally Posted by bushmobile
first thing to do is to get rid of On Error Resume Next, then see what your code does.
Once you have gotten rid of it, never put it back.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|