CHAPTER 12 (Web hosting asp) CASE STUDY: USING .NET FOR
Monday, December 31st, 2007CHAPTER 12 CASE STUDY: USING .NET FOR AN XML APPLICATION 371 Figure 12-6. Handling updating errors The next subroutine, GridViewDeleted, is similar: Sub GridViewDeleted(ByVal s As Object, ByVal e As GridViewDeletedEventArgs) If Not e.Exception Is Nothing Then lblError.Text = “
Error: Could not delete row” e.ExceptionHandled = True End If End Sub Again, the page displays an error if it can t delete a row. The code block also contains a subroutine called addNews. This subroutine handles the Add News button click event: Sub addNews(sender As Object, e As System.EventArgs) response.redirect(”addNews.aspx”) end sub When users click the Add Newsbutton, the browser redirects to the addNews.aspx page. The page adds new content to the database.
In case you need quality webspace to host and run your web applications, try our personal web hosting services.