I’m sure I’m not the first person to come up with this. તેમ છતાં, I haven’t noticed anyone publish a trick like this since I started paying close attention to the community last July. તેથી, હું તે આ ઝડપી અને સરળ ડિબગ ટીપ પોસ્ટ કરશો વિચાર્યું.
હું આ ભૂલ પેદા કરવા માટે શરૂ છે કે જે ઇવેન્ટ રિસીવર પર કામ કરી રહ્યો છું 12 મધપૂડો:
Xyzzy લોડ કરવામાં ભૂલ અને ચાલી ઘટના રીસીવર Conchango.xyzzyEventReceiver, આવૃત્તિ 1.0.0.0 =, સંસ્કૃતિ = તટસ્થ, PublicKeyToken = blahbalhbalh. Additional information is below. : એક વસ્તુ એક ઉદાહરણ માટે ઓબ્જેક્ટ સંદર્ભ સુયોજિત નહિં.
I didn’t know where I had introduced this bug because I had done too many things in one of my code/deploy/test cycles.
હું પ્રયત્ન કર્યો છે આ ઉકેલ આશા સાથે ત્યાં મારા pdb વિચાર કે શેરપોઈન્ટ માતાનો 12 મધપૂડો સ્ટેક ટ્રેસ બતાવશે, but no luck. I don’t know if it’s possible and if someone does, મને જણાવવા વિનંતી
હું તે શક્ય છે ખબર જો તમારા પોતાના લોગ સંદેશાઓ લખી 12 મધપૂડો. Frankly, હું અમલ કરવા માટે થોડી ઓછી ડરામણી અને ઝડપી કંઈક ઇચ્છતા.
હું ઓછામાં ઓછા આ જેમ સામાન્ય અપવાદો મોહક અને ફરીથી ઘા દ્વારા કેટલાક પાયાના ટ્રેસ માહિતી મળી શકે કે મને આવી:
પ્રયત્ન કરવો { UpdateEditionDate(ગુણધર્મો); } ઝાલવું (અપવાદ અને) { ફેંકવું નવું અપવાદ("Dispatcher, UpdateEditionDate(): અપવાદ: [" + e.ToString() + "]."); }
આ માં દર્શાવ્યું 12 મધપૂડો thusly:
Xyzzy લોડ કરવામાં ભૂલ અને ચાલી ઘટના રીસીવર Conchango.xyzzyEventReceiver, આવૃત્તિ 1.0.0.0 =, સંસ્કૃતિ = તટસ્થ, PublicKeyToken = blahblahblah. Additional information is below. : મોકલનાર, UpdateEditionDate(): અપવાદ: [System.NullReferenceException: એક વસ્તુ એક ઉદાહરણ માટે ઓબ્જેક્ટ સંદર્ભ સુયોજિત નહિં. at Conchango.xyzzyManagementEventReceiver.UpdateEditionDate(SPItemEventProperties ગુણધર્મો) at Conchango.xyzzyManagementEventReceiver.Dispatcher(SPItemEventProperties ગુણધર્મો, શબ્દમાળા eventDescription)].
કે મને ચોક્કસ સમસ્યા ટ્રૅક કરવા માટે જરૂરી તમામ વિગત આપી હતી અને હું તેને આગળ જતાં ઘણો વાપરવા માટે અપેક્ષા.
</અંત>
મારા બ્લોગ પર સબ્સ્ક્રાઇબ કરો!
સારી હજુ સુધી, Enterprise લાઇબ્રેરી અથવા log4net જેવા લોગીંગ પુસ્તકાલય સમાવેશ અને તમારા જીવન પણ સરળ હશે.