View Single Post
Old 01-26-2005, 12:56 AM   #3 (permalink)
Anomaly_
Insane
 
I would guess you're calling getItemID() on an uninitialized (NULL) member of the productSpecifications array. I don't know the extent of your program, but a HashMap object might be better suited for your list of ProductSpecifications rather an an array, ArrayList, or whatever you're using to index it.

Also, as a tip, you can use the "break;" command in that for loop so you don't have to use a boolean flag. It simply breaks out of the inner most loop.
Anomaly_ is offline  
 

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76