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

Help with coding, and an issue with paperdolls?


GeminiXcasorm
 Share

Recommended Posts

Ohkay. so i recently added in an ungodly amount of paperdolls. i went from having 442 to something like 632\. and i kept getting this "error 9, subscript is out of range". And i thought it had something to do with maybe the background colors. so i took all of the ones that didnt have my default background colors and changed them opaque. And yet the problem proceeded to happen. so i opened it in vb6 in a test window, and it came up with a problem with this line : 

```
CopyMemory ByVal VarPtr(Item(n)), ByVal VarPtr(ItemData(0)), ItemSize

```

And i was curious, if noone can help me with it with that information, if i could send my source and project to someone if they could get it working? PLEASE AND THANK YOU!

p.s. will not sell soul for work. i already made that mistake once on here. 

![](http://i1244.photobucket.com/albums/gg571/gemini_castorm/HELP.png)
Link to comment
Share on other sites

as far as i know, numbers of paperdoll isn't involve with the error..

check this solution

* try to have only 400 paperdoll..check if it will work..
* try to check if the ItemRec on server side match the ItemRec on the client side
* try to delete the old item data

if it didn't work.. add me on skype (username: hisherwin) i'll try to help you there.

Note: don't add me if you didn't test the solution
Link to comment
Share on other sites

> as far as i know, numbers of paperdoll isn't involve with the error..
>
> check this solution
>
>  
>
> * try to have only 400 paperdoll..check if it will work..
> * try to check if the ItemRec on server side match the ItemRec on the client side
> * try to delete the old item data
>
> if it didn't work.. add me on skype (username: hisherwin) i'll try to help you there.
>
> Note: don't add me if you didn't test the solution

Do you think if i where to add you you could help me with some other stuff as well? i'm new to coding, and teaching myself using nothing but tutorials on the forums is kinda difficult, saying as i'm balancing that and highschool.

also, i deleted all the pictures i added. i think i'm going to go through them all one at a time, and only save the ones that i'm certain i want.
Link to comment
Share on other sites

As Sherwin said make sure the Item rec on server matches with that on client. 

You can do lenb(item(1)) on server and client to check whether the size is the same. 

(Copymemory doesn't care about how it is ordered or if all of them are of the same data type it only cares about the size)
Link to comment
Share on other sites

Well, I'll tell you right now, it is not an issue with there not being enough slots open for the number of images you are trying to load.

CopyMemory ByVal VarPtr(Item(n)
), ByVal VarPtr(ItemData(0)), ItemSize

I changed the color of the part of the code, it's just taking the number/amount of images you have, if I have to guess, somewhere along the line you have a misnumbered image. If that's not the case then I do not know what's up.
Link to comment
Share on other sites

> error 9 subscript out of range. i ordered them correctly and everything. the only thing i can think of is if its possibly coded to only have a certain color palate? Is there a tutorial somewhere on here to make it to it can handle any image type?

Nah, not a certain color palette. And there is no limit to an amount of paperdolls you can have. Send me the source/project if you want and I'll try to see what's the matter.
Link to comment
Share on other sites

If it helps any, I had a similar problem except for spell icons. The problem wasn't the amount of files I had but rather one or more of your files got corrupted in the process. Try lowering the amount of paperdolls loaded until it stops erroring then start increasing the amount loaded until you can narrow down the culprit.
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...