Solved

ASP.NET/VB: "Imports"  causes error

Posted on 2013-12-17
3
778 Views
Last Modified: 2013-12-27
How can I import these without getting an error?
<%@ Page Language="VB" %>
<%

Imports System
Imports System.Xml
Imports System.IO
Imports System.Text

HttpContext.Current.Response.Write("Hello World")

%>

Open in new window

Compiler Error Message: BC30035: Syntax error.
0
Comment
Question by:hankknight
3 Comments
 
LVL 8

Assisted Solution

by:5teveo
5teveo earned 250 total points
ID: 39724427
try ...

<%@ import namespace="Imports System" %>
.
.
<%@ import namespace="Imports System.Text" %>


<%@ Page Language="VB" %>
<%

HttpContext.Current.Response.Write("Hello World")

%>
0
 
LVL 29

Accepted Solution

by:
Paul Jackson earned 250 total points
ID: 39724442
should be :

<%@ Page Language="VB" %>

<%@Import namespace="System"%>
<%@Import namespace="System.Xml"%>
<%@Import namespace="System.IO"%>
<%@Import namespace="System.Text"%>

<%
HttpContext.Current.Response.Write("Hello World")
%> 

Open in new window

0
 
LVL 16

Author Comment

by:hankknight
ID: 39742026
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Problem Hi all,    While many today have fast Internet connection, there are many still who do not, or are connecting through devices with a slower connect, so light web pages and fast load times are still popular.    If your ASP.NET page …
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now