C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Reviews   Communities   Interview   Jobs   Projects   Training   Your Ad Here    
Silverlight Games | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Polls | Revenue Sharing | Lobby | Gift Shop |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...






Forums » .NET » ASP.NET »

To pass array of object


Posted Date: 03 Nov 2009      Posted By: Anu      Member Level: Silver     Points: 1   Responses: 2



I have two fnA() & fnB().

First fn i have written as

fnA()
{
ptblActTrx[] objAccountTransactions;
fnB(objAccountTransactions);
}

fnB(ptblActTrx[] objAccountTransactions)
{

}

I am getting a msg use of unassigned local variable.can any1 help m?





Responses

Author: Praveen    03 Nov 2009Member Level: DiamondRating: 2 out of 52 out of 5     Points: 2

hi,

try like this

nA()
{
ptblActTrx[] objAccountTransactions=null;
fnB(objAccountTransactions);
}

fnB(ptblActTrx[] objAccountTransactions)
{

}

hope that will give you an idea



Author: venkatesan    03 Nov 2009Member Level: DiamondRating: 2 out of 52 out of 5     Points: 2

assign null for the variable it will solves your issue.

Regards,
M.Venkatesan.
Dot Net Code Snippets



Post Reply
You must Sign In to post a response.
Next : Grid view
Previous : Difference
Return to Discussion Forum
Post New Message
Category: ASP.NET

Related Messages



dotNet Slackers

About Us    Contact Us    Privacy Policy    Terms Of Use