Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

object error

Posted on 2008-06-20
2
Medium Priority
?
183 Views
Last Modified: 2013-12-16
I am using a view from a different database to populate my datagrid. Once the user hits import button inside the datagrid the record is removed from view. the screen goes through the motions but doesn't remove the record from view and it gives me this error: Object reference not set to an instance of an object.
private void gridImport_ItemCommand(object source, DataGridCommandEventArgs e)
		{
			if(e.CommandName == "import")
			{			
				string proposal_number=e.CommandArgument.ToString();				
				
				TransferProposalPackage(proposal_number + ".pdf");
				ADTransfer.Transfer transfer = new ADTransfer.Transfer(proposal_number,Cycle.ColumnValue.pk_cycle.ToString());
				lblErrMsg.Text=transfer.errMessage;
				bindDataGrid();
 
						
			}			
 
		}

Open in new window

0
Comment
Question by:MoniMatthews
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 16

Accepted Solution

by:
ororiole earned 2000 total points
ID: 21833709
Set a breakpoint at the beginning of the event handler. Its short so you can single step thru it. One of the objects is null. Check their values and see which one it is.
0
 

Author Closing Comment

by:MoniMatthews
ID: 31469249
Thank you for your help.
0

Featured Post

The Orion Papers

Are you interested in becoming an AWS Certified Solutions Architect?

Discover a new interactive way of training for the exam.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Summary Displaying images in RichTextBox is a common requirement with limited solutions available. Pasting through clipboard or embedding into RTF content only support static images.  This article describes how to insert Windows control objects int…
In my previous two articles we discussed Binary Serialization (http://www.experts-exchange.com/A_4362.html) and XML Serialization (http://www.experts-exchange.com/A_4425.html). In this article we will try to know more about SOAP (Simple Object Acces…
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…

715 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question