Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Web Controls > Error with Page Views

Reply
Thread Tools

Error with Page Views

 
 
Morris Neuman
Guest
Posts: n/a
 
      06-29-2009
Hi,

I have a few pages with Views and I sometimes get the error below. I am
using Expression web2. What am I doing wrong?

Compilation Error
Description: An error occurred during the compilation of a resource required
to service this request. Please review the following specific error details
and modify your source code appropriately.

Compiler Error Message: CS1002: ; expected

Source Error:



Line 4: <script runat="server">
Line 5:
Line 6: Â Â protected void Page_Load(object sender, EventArgs e)
Line 7: Â Â {
Line 8: Â Â Â Â if (Request.QueryString["ViewIndex"] != null)
Source File: c:\Inetpub\wwwroot\SpeechSoft\site_flash\products. aspx Line:
6

Pasted from <http://192.168.11.3/SpeechSoft/products.aspx>

My page code has the following:
<%@ Page Language="C#" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<script runat="server">

protected void Page_Load(object sender, EventArgs e)
{
if (Request.QueryString["ViewIndex"] != null)
{
string strIndex = Request.QueryString["ViewIndex"].ToString();

int iIndex = 0;
try
{
iIndex = Convert.ToInt32(strIndex);
}
catch
{
}

if (iIndex > 0 && iIndex < MultiView1.Views.Count)
{
MultiView1.ActiveViewIndex = iIndex;
}
}
}


protected void ShowView1_DialogicBoards(object sender, EventArgs e)
{
MultiView1.ActiveViewIndex = 1;
}
protected void ShowView0_TelephonySoftware(object sender, EventArgs e)
{
MultiView1.ActiveViewIndex = 0;
}
</script>


<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>SpeechSoft Products</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="Content-Style-Type" content="text/css" />
<meta content="Telephony, T1, VoIP, Voice mail, auto attendant, fax,
outdialing, scripting" name="keywords" />
<meta content="Overview of SpeechSoft Products CALLMaster and CALLMaster IP"
name="description" />
<link href="style.css" rel="stylesheet" type="text/css" />
<link href="layout.css" rel="stylesheet" type="text/css" />
<style type="text/css">
</style>
</head>
<body id="page2">
<form id="form1" runat="server">

<div id="main">
<!-- header -->
<div id="header">
<p>www.speechsoft.com</p>
<ul id="navi">
<li><a href="aboutSS-contacts.aspx">About Us</a></li>
<li><a href="aboutSS-contacts.aspx">Contact</a></li>
</ul>
<a href="index.aspx"><img src="images/logo.gif" id="logo" alt="" /></a>
<div id="menu">
<!--Valid flash version 8.0-->
<object classid="clsid27CDB6E-AE6D-11cf-96B8-444553540000"

codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,24"
width="404" height="39">
<param name="movie" value="flash/menu_v8.swf?button=2" />
<param name="quality" value="high" />
<param name="menu" value="false" />
<param name="wmode" value="transparent" />
<!--[if !IE]> <-->
<object data="flash/menu_v8.swf?button=2"
width="404" height="39" type="application/x-shockwave-flash">
<param name="quality" value="high" />
<param name="menu" value="false" />
<param name="pluginurl"
value="http://www.macromedia.com/go/getflashplayer" />
<param name="wmode" value="transparent" />
FAIL (the browser should render some flash content, not this).
</object>
<!--> <![endif]-->
</object>
</div>
</div>
<!-- content -->
<div id="content">
<div class="wrapper">
…..
</div>
</div>
</div>
</form>

</body>
</html>


--
Thanks
Morris

-----------------------------------------------------------------------------
Less Spam Better enjoyable experience
Visit : news://spacesst.com
 
Reply With Quote
 
 
 
 
Allen Chen [MSFT]
Guest
Posts: n/a
 
      06-30-2009
Hi Morris,

>I have a few pages with Views and I sometimes get the error below. I am
>using Expression web2. What am I doing wrong?


I cannot see the MultiView1 in the aspx code. Could you send me the
project? My email is http://www.velocityreviews.com/forums/(E-Mail Removed) update here after sending
the project in case I missed that email.

Regards,
Allen Chen
Microsoft Online Support

Delighting our customers is our #1 priority. We welcome your comments and
suggestions about how we can improve the support we provide to you. Please
feel free to let my manager know what you think of the level of service
provided. You can send feedback directly to my manager at:
(E-Mail Removed).

==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/en-us/subs...#notifications.

Note: MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 2 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions. Issues of this
nature are best handled working with a dedicated Microsoft Support Engineer
by contacting Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/en-us/subs.../aa948874.aspx
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.




-----------------------------------------------------------------------------
Less Spam Better enjoyable experience
Visit : news://spacesst.com
 
Reply With Quote
 
 
 
 
Allen Chen [MSFT]
Guest
Posts: n/a
 
      07-07-2009
Hi Morris,

>I have a few pages with Views and I sometimes get the error below. I am
>using Expression web2. What am I doing wrong?


Have you sent me the project?

Regards,
Allen Chen
Microsoft Online Support

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
listView controlling different page views? Andy B ASP .Net 2 11-27-2007 06:47 AM
Trade me 'Page views' counter news.xtra.co.nz NZ Computing 13 03-28-2006 06:21 AM
One billion page views Senti Computer Support 8 03-01-2006 03:11 AM
Page_Load Not Firing On Subsequent Views of the Page Guadala Harry ASP .Net 4 09-11-2004 07:36 AM
Having One Page Produce Multiple Views Tim Rogers ASP .Net 3 11-10-2003 02:02 PM



Advertisments