By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,362 Members | 1,344 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,362 IT Pros & Developers. It's quick & easy.

Creation of DALC using stored procedures

P: 11
Hi
I am getting an error when I insert the records to the DB in DALC using the stored procedure.
The error is like this "Object reference not set to an instance of an object"

It is very urgrent please reply me if anyboby know the solution for this.

Thanks in advance.
Regards,
kani.Z
May 21 '08 #1
Share this Question
Share on Google+
5 Replies


ck9663
Expert 2.5K+
P: 2,878
I don't know what a DALC is. But in this situations, I would assume you have a dynamic t-sql that you use to execute your insert. Paste or display it somehow, copy the entire string to query analyzer and run it.

-- CK
May 21 '08 #2

P: 11
I don't know what a DALC is. But in this situations, I would assume you have a dynamic t-sql that you use to execute your insert. Paste or display it somehow, copy the entire string to query analyzer and run it.

-- CK

Thank you for ur reply.

How to invoke a DALC (Data Access Logic Component) class which uses stored procedure. Help me plz as soon as possible. Its very urgent.

Regards,
kani
May 21 '08 #3

Delerna
Expert 100+
P: 1,134
The error "Object reference not set to an instance of an object" is being generated in your front end application rather than the stored procedure.
What are you using for the front end?
Is it Internet explorer, Access, ????
What language are you using ???
Java, VBA, C# ???

Your error means you are referencing a class that has not been instantiated. Probably one of the ones to do with providing you the "Data Access Layer Component" functionality.
May 21 '08 #4

ck9663
Expert 2.5K+
P: 2,878
Thank you for ur reply.

How to invoke a DALC (Data Access Logic Component) class which uses stored procedure. Help me plz as soon as possible. Its very urgent.

Regards,
kani
This question is more of your front-end tool question than sql-server.

-- CK
May 21 '08 #5

P: 11
The error "Object reference not set to an instance of an object" is being generated in your front end application rather than the stored procedure.
What are you using for the front end?
Is it Internet explorer, Access, ????
What language are you using ???
Java, VBA, C# ???

Your error means you are referencing a class that has not been instantiated. Probably one of the ones to do with providing you the "Data Access Layer Component" functionality.

I am using the front end as VS .net2005, the language is C#
the back end is SQL server2005.

I have created the Stored procedures in sql and I want to access those SPs through DAL component.
For that I have added the dataset in C# website project, in that I have added the table from DB and connecting the DB by configuring the methods in the TableAdapter.

I am able to retrieve the data from the table but unable to insert,update or delete the data from the table using the option "Use existing stored procedure" while configure the methods in the TableAdapter.

plz help as soon as possible. Its very urgent....
Thanks in advance

Regards,
kani.Z
May 21 '08 #6

Post your reply

Sign in to post your reply or Sign up for a free account.