I have an ASP.NET form with several FileUpload controls, each of which has an associated button. FileUpload1 is associated with a button called btnUpload1, FileUpload2 is associated with a button called btnUpload2, etc. I want to have one event handler for all the buttons but I'm struggling to work out how to refer to the relevant FileUpload control within the event handler. I tried the code shown below but this gave me an 'Object reference not set to an instance of an object' error on Line 6.
I suspect the solution is very simple but so far it has eluded me. Where am I going wrong?
David
===========================================================================1 Protected Sub btnUpload_Click(ByVal sender As Object, ByVal e As System.EventArgs)
Go to the complete details ...