Click here to Skip to main content
15,886,199 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
hi i am trying zoom in and zoom out in my code. .jpeg files it is working fine.
but when i try same with .pdf file zoom out i m getting below error.please help me

System.NullReferenceException: Object reference not set to an instance of an object. <br />
<br />
at CMSSystem.ImageViewer.btnZoomOut_Click(Object sender, EventArgs e)<br />
at System.Windows.Forms.Control.OnClick(EventArgs e)<br />
at System.Windows.Forms.Button.OnClick(EventArgs e)<br />
at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)<br />
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)<br />
at System.Windows.Forms.Control.WndProc(Message& m)<br />
at System.Windows.Forms.ButtonBase.WndProc(Message& m)<br />
at System.Windows.Forms.Button.WndProc(Message& m)<br />
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)<br />
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)<br />
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntP
Posted
Updated 7-Mar-13 0:13am
v2
Comments
Orcun Iyigun 7-Mar-13 6:16am    
Share your code and tell us where you get the exception please
OriginalGriff 7-Mar-13 6:17am    
Without your code? We can't help much.
Either put a breakpoint on the first line in the btnZoomOut_Click method and step through looking for the null reference, or post the code and indicate which line is causing the error.
Use the "Improve question" widget to edit your question and provide better information.

1 solution

one or multiple class/object(s) being used/involved is not initialised. need to look into the parameters of the function being invoked. or in which it is written.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900