Wrox Programmer Forums
|
BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3
This is the forum to discuss the Wrox book Beginning ASP.NET 3.5: In C# and VB by Imar Spaanjaars; ISBN: 9780470187593
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old January 14th, 2009, 04:34 AM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Hi goboomer,

Take a look at this code:

Code:
 
<%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default.aspx.vb" Inherits="_Default" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Untitled Page</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
    
        &lt;div&gt;<br />
        &lt;h1&gt;Hello World&lt;/h1&gt;<br />
        &lt;p&gt;Welcome to Beginning ASP.NET 3.5 on &lt;%= DateTime.Now.ToString() %&gt;&lt;/p&gt;<br />
        &lt;/div&gt;
    </div>
    </form>
<p>
    &nbsp;</p>
</body>
</html>
As you can see, all the angled brackets ( < and > ) have been converted to &gt; and &lt; This seems to indicate that you typed the code in *Design View* and not in Markup View. Before you type the relavant code, be sure to click the Source button at the bottom from the code window. That way, the code is no longer "escaped" and will be treated as actual code, not literal content.

Hope this helps,

Imar
__________________
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Follow me on Twitter

Author of Beginning ASP.NET 4.5 : in C# and VB, Beginning ASP.NET Web Pages with WebMatrix
and Beginning ASP.NET 4 : in C# and VB.
Did this post help you? Click the button below this post to show your appreciation!
 
Old January 14th, 2009, 09:32 AM
Friend of Wrox
 
Join Date: Nov 2007
Posts: 207
Thanks: 2
Thanked 15 Times in 15 Posts
Default yes....

That would be the issue... when entering in your vb code in the asp brackets you must do so in the source view and not the design view otherwise the file will render it as plain text and not see you are actually trying to add code to the page.
__________________
Jason Hall

Follow me on Twitter @jhall2013
 
Old January 14th, 2009, 10:07 PM
Registered User
 
Join Date: Jan 2009
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks for your help I did not realize that. That fixed my issue.





Similar Threads
Thread Thread Starter Forum Replies Last Post
ASP "Hello World" Bill_Thompson ASP.NET 2.0 Basics 3 December 14th, 2007 09:38 AM
GRPS "Hello World" rodmcleay C# 0 October 11th, 2005 10:56 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.