I think this problem is more complicated than many people believe it to be and I think you have to carefully consider what actually limits your accuracy. Especially if you are doing undergraduate labs... I will try to give all the factors I could think of here, but don't have time to elaborate how to mathematically account for all of them.
If you are a researcher and use gratings for measurements you are probably going to make sure your setup is good enough that your limiting setup is the spectral resolution of the grating. What is meant by that is that the diffraction peak you use to measure wavelength has a certain width. As you change the wavelength the peak moves, but to distinguish two wavelengths, you have to move by at least the width (if your apparatus for measuring intensity is good you might be able to get away with moving a certain fraction of the width). I won't go into the details of the maths since you can find that in any standard optics textbook or in Chris' answer above.
Now if you are an undergraduate I highly doubt they are going to give you an apparatus where you can get anywhere near that limit. The error in the wavelength measurement is going to contribute, but will probably not dominate. This can also happen in certain other situations in real research.
One surprisingly large error in this measurement comes from the incoherence of the wavefront. Assuming you use a laser you should check that the one with the otherwise favorable wavelength doesn't happen to have a massively different beam divergence. This would contribute a phase factor at the grating that will influence your measurements. Same goes for the line width of the laser.
If you are using Fraunhofer approximation for your calculations (which the spectral resolution criterion assumes), you have to make sure that you don't get a significant error from not being in the Fraunhofer limit. Note that it is not sufficient to just check $\frac{W^2}{L \lambda} << 1$ (where L is the aperture distance, W is the slit width, and $\lambda$ is the wavelength). Instead one has to properly calculate the error contribution from the phase of the quadratic term. Especially in the lab this is not to be underestimated. The distances to get Fraunhofer limit are quite far. Also note the wavelength factor in the criterion for Fraunhofer limit. In fact this is also going to work in the same direction as the the spectral resolution factor.
My last point is going to be how the absolute intensity of the individual peaks change with wavelength. This is in fact the most important point (put last so that people keep reading). For your measurement you will want to use the highest order peak visible, since that one gives the best precision by the spectral resolution criterion. But for larger wavelength the intensity of these peaks falls off. It is non-trivial to find the actual factor (in fact scalar diffraction theory can't give a rigorous derivation, one might need to use electromagnetic simulations), but it goes something like $\frac{1}{\lambda}$ (which comes from the scalar diffraction integral).
I only gave qualitative pointers to the issues involved. The maths should hopefully be straightforward to work out (except for the last point). Please feel free to contact me if not.