I wanted to post my code in a question and it's at present, 90+ lines long. Is it ok to post the whole thing, or should I try and only post the most important pieces?
I would try to reduce it slightly, but there's significant value in posting a complete example if you possibly can.
I have an article I wrote on "short but complete examples" a while ago which I think still holds water. Basically take out everything that's definitely unrelated - particularly GUI and anything to do with files - so that the result is self-contained and short, but still clearly indicates what's going wrong.
This process often lets you find the problem yourself, admittedly :)
Having said all this, I would rather have a 100 line program which I can run and see failing than a 10 line snippet without enough context to diagnose the issue.
On the technical side, there is no limit and it might even break the user's browser if there is too much code.
That being said, do not post too much code. Try to break it down to pinpoint the part that is linked to the problem. It will be easier to read, faster to load and will not scare people off.