• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 208
  • Last Modified:

Communication Between .vb File and .aspx File

I have a GridView on an .aspx form and the content is controlled by an ObjectDataSource. The actual table update takes place in a .vb file. My question is now: how can I communicate a situation in the .vb file (e.g. no records found, missing update etc.) to the user of the .aspx file? In case of an error found in the .vb file, I want to put a message to the user in e.g. a label on the .aspx file.
0
Kim Neesgaard
Asked:
Kim Neesgaard
  • 4
  • 2
1 Solution
 
David RobitailleAnalyst ProgrammerCommented:
Usualy i raise Application exception (using Throw New ApplicationException("text")) and than catch it in the RowUpdated of the grid view
 here all my inspirations:
http://www.asp.net/learn/data-access/tutorial-18-vb.aspx
0
 
Kim NeesgaardAuthor Commented:
Hi!

This is EXACTLY what I was looking for - THANK YOU! I have tested it and it works perfectly!
0
 
Kim NeesgaardAuthor Commented:
Nothing more to add.
0
Cloud Class® Course: Ruby Fundamentals

This course will introduce you to Ruby, as well as teach you about classes, methods, variables, data structures, loops, enumerable methods, and finishing touches.

 
David RobitailleAnalyst ProgrammerCommented:
Well, I could just wait that the question to be close, but I think you should select my comment as the solution instead of your comment and mine as the assisted solution.
0
 
Kim NeesgaardAuthor Commented:
I am new to EE and sorry if I have done something wrong! Of course your solution must be selected - it help me a lot. I will try to make it correct.
0
 
Kim NeesgaardAuthor Commented:
Now I hope things is done the right way! Thanks one more time.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Cloud Class® Course: CompTIA Cloud+

The CompTIA Cloud+ Basic training course will teach you about cloud concepts and models, data storage, networking, and network infrastructure.

  • 4
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now