Showing posts with label message. Show all posts
Showing posts with label message. Show all posts

Saturday, March 31, 2012

There are too many people accessing the Web site at this time.

What resource have I exhausted if a remote client gets the following message?

"The page cannot be displayed
There are too many people accessing the Web site at this time. "You've exhausted IIS. If you're running Windows XP or Windows 2000 Professional, your IIS process can only handle 10 concurrent connections (at the same time). This is by design and you cannot change this, although with XP you can disable HTTP keep-alives in the properties of the
Web site. When you do this, a limit of 10 concurrent connections still exists, but IIS does not maintain connections for inactive users.

If more than ten connections are needed, you will need to upgrade to one of Microsoft's server platforms.

There can be only one page directive.

Hi all,

I'm getting the "There can be only one 'page' directive."error message at an application that I just uploaded from my dev machine to a shared 'production' server. But here's the deal.

It goes to the login page just fine. Then it drops to default.aspx, presenting...nothing! It's supposed to "Response.Redirect("home.aspx")" But it doesn't. Then, if I point manually to home.aspx, I get:

Line 43: <%# DataBinder.Eval(Container, "DataItem.text")%>
Line 44: </a>
Line 45: <%@dotnet.itags.org. Page Language="vb" AutoEventWireup="false" Codebehind="home.aspx.vb" Inherits="MAB.home" %>
Line 46: <%@dotnet.itags.org. Register TagPrefix="uc1" TagName="MAB" src="http://pics.10026.com/?src=MAB.ascx" %>
Line 47: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" />
with weird spacing and all. And the line numbers are screwey anyway. None of this happened on my local dev machine.

Anyone recognize the symptoms? I'm guessing that it's all one problem.

Thanks for reading,

Chris

Have you simply opened the aspx page and inspect the contents?

Looks like you have some funky include code going on or the like


double check for a control ( .ascx) that has a page directive in it - did you make sure the server is running the same version framework your using ?
Problem might be with page directive of control ( .ascx) .
I was thinking the same stuff y'all were.

There is one user control, it doesn't have a page directive, just the "<%@. Control Language-..." directive. I agree that it looks like messed up include, but I'm not using any includes anywhere in the app.

The lines 43 and 44 shown in the error page are exactly what I'd predict. Then it looks like it lists lines 1-3 as 45-47.

I don't know if the server is running the same framework version. Hmm. I'll look into that if you think it's a viable issue. What do I do if they're different?

Chris
So my application was developed under framework v. 1.1.4322.0 and the web host I use says "We are currently running ASP.Net 1.1 framework." How 'off' would the versions have to be to cause these kinds of problems? Anyone else have any ideas?

Chris
asp v1.1 means 1.1.4322 - so you should be OK - there are only 3 I think 1.0, 1.1, and 2.0

post your home.aspx code - might give more clues
OK, how? When I cut and paste the code in it's altered into WYSIWYG mash. Is there a trick to it?
hmmm. try putting it between [ code] tags

[ code]

put code here

[ /code]

I had to add a space to the tag so it would show up !
so thats....... bracket code bracket with no spaces

: )
If this works, it was by opening it in notepad and copy-pasting out of that instead of out of VS.


<title>home</title><%@. Page Language="vb" AutoEventWireup="false" Codebehind="home.aspx.vb" Inherits="MAB.home" %>
<%@. Register TagPrefix="uc1" TagName="MAB" src="http://pics.10026.com/?src=MAB.ascx" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" />
<HTML>
<HEAD>
<title>home</title>
<meta content="Microsoft Visual Studio .NET 7.1" name="GENERATOR">
<meta content="Visual Basic .NET 7.1" name="CODE_LANGUAGE">
<meta content="JavaScript" name="vs_defaultClientScript">
<meta content="http://schemas.microsoft.com/intellisense/ie5" name="vs_targetSchema">
<LINK href="http://links.10026.com/?link=Styles.css" type="text/css" rel="stylesheet">
</HEAD>

<body>
<form id="Form1" method="post" runat="server">
<uc1:MAB id="MAB1" runat="server" />
<div id="wrapper">
<div class="left">
<h3>Topics With Newest Entries</h3>
<div class="summary">
<asp:repeater id="rNew" runat="server">
<HeaderTemplate>
<ul>
</HeaderTemplate>
<FooterTemplate>
</ul>
</FooterTemplate>
<ItemTemplate>
<li>
<span class="bold">
<a href="http://links.10026.com/?link=topic.aspx?sub=<%# DataBinder.Eval(Container, "DataItem.topic_ID") %>">
<%# DataBinder.Eval(Container, "DataItem.topic_name").toUpper %></a></span>
</li>
</ItemTemplate>
</asp:repeater>
</div>
<h3>Newest Picture Links</h3>
<div class="summary">
<asp:Repeater ID="rPics" Runat=server>
<ItemTemplate>
<a href="http://links.10026.com/?link=topic.aspx?sub=<%# DataBinder.Eval(Container, "DataItem.topic_ID")%>">
<%# DataBinder.Eval(Container, "DataItem.text")%>
</a>
</ItemTemplate>
</asp:Repeater>
</div>
</div
<div class="right">
<h2>Editor Highlights</h2>
<div class="summary">
<asp:repeater id="rEd" runat="server">
<ItemTemplate>
<span class="bold">
<a href="http://links.10026.com/?link=topic.aspx?sub=<%# DataBinder.Eval(Container, "DataItem.topic_ID") %>">
<%# DataBinder.Eval(Container, "DataItem.topic_name").toUpper %></a>
</span>by
<%# DataBinder.Eval(Container, "DataItem.member_name") %>,
</ItemTemplate>
</asp:repeater>
</div>
</div
<div class="right">
<h2>Highest Rated</h2>
<asp:repeater id="rHigh" runat="server">
<ItemTemplate>
<div class="summary" style="background-color: #ffd;">
<div class="headline">
<span class="bold">
<a href="http://links.10026.com/?link=topic.aspx?sub=<%# DataBinder.Eval(Container, "DataItem.topic_ID") %>">
<%# DataBinder.Eval(Container, "DataItem.topic_name").toUpper %></a>
</span>by
<%# DataBinder.Eval(Container, "DataItem.member_name") %>
on
<%# DataBinder.Eval(Container, "DataItem.creation_date").ToShortDateString %>
</div>
<%# DataBinder.Eval(Container, "DataItem.text") %>
</div>
</ItemTemplate>
</asp:repeater></div>
</div>
<asp:label id="lTest" Runat="server" Font-Size="Larger" Font-Bold="True" ForeColor="#400000" />
</form>
</body>
</HTML

well - for starters

<title>home</title><@.Page Language="vb" AutoEventWireup="false" Codebehind="home.aspx.vb"Inherits="MAB.home" >
needs to be switched around
the <@.Page directive has to be first line ( I believe) and title belongs in head tags
so make that like this

<@.Page Language="vb" AutoEventWireup="false" Codebehind="home.aspx.vb"Inherits="MAB.home" >
<head>
<title>home</title>
<meta...
other head stuff.....
</head
try that and see what happens

I'm becoming kind of freaked out about this. There is no <title>home</title> in my source before the page directive. If I paste from VS, it's trying to render the HTML. I'm trying it below to compare how it looks to the above suck.

<%@. Page Language="vb" AutoEventWireup="false" Codebehind="home.aspx.vb" Inherits="MAB.home" %> <%@. Register TagPrefix="uc1" TagName="MAB" src="http://pics.10026.com/?src=MAB.ascx" %>
<META content="Microsoft Visual Studio .NET 7.1" name=GENERATOR>
<META content="Visual Basic .NET 7.1" name=CODE_LANGUAGE>
<META content=JavaScript name=vs_defaultClientScript>
<META content=http://schemas.microsoft.com/intellisense/ie5 name=vs_targetSchema><LINK href="http://links.10026.com/?link=Styles.css" type=text/css rel=stylesheet>
<FORM id=Form1 method=post runat="server"><?xml:namespace prefix = uc1 /><uc1:MAB id=MAB1 runat="server"></uc1:MAB>
<DIV id=wrapper>
<DIV class=left>
<H3>Topics With Newest Entries</H3>
<DIV class=summary><?xml:namespace prefix = asp /><asp:repeater id=rNew runat="server"><HEADERTEMPLATE></HEADERTEMPLATE></asp:repeater>
<UL><FOOTERTEMPLATE></FOOTERTEMPLATE></UL><ITEMTEMPLATE>
<LI><SPAN class=bold><A href="http://links.10026.com/?link=http://forums.asp.net/topic.aspx?sub=%3C%#%20DataBinder.Eval%28Container,%20" %="" )="" dataitem.topic_id="">"> <%# DataBinder.Eval(Container, "DataItem.topic_name").toUpper %></A></SPAN> </ITEMTEMPLATE></LI></DIV>
<H3>Newest Picture Links</H3>
<DIV class=summary><asp:Repeater id=rPics runat="server"><ITEMTEMPLATE><A href="http://links.10026.com/?link=http://forums.asp.net/topic.aspx?sub=%3C%#%20DataBinder.Eval%28Container,%20" )="" dataitem.topic_id="">"> <%# DataBinder.Eval(Container, "DataItem.text")%> </A></ITEMTEMPLATE></asp:Repeater></DIV></DIV>
<DIV class=right>
<H2>Editor Highlights</H2>
<DIV class=summary><asp:repeater id=rEd runat="server"><ITEMTEMPLATE><SPAN class=bold><A href="http://links.10026.com/?link=http://forums.asp.net/topic.aspx?sub=%3C%#%20DataBinder.Eval%28Container,%20" %="" )="" dataitem.topic_id="">"> <%# DataBinder.Eval(Container, "DataItem.topic_name").toUpper %></A> </SPAN>by <%# DataBinder.Eval(Container, "DataItem.member_name") %>, </ITEMTEMPLATE></asp:repeater></DIV></DIV>
<DIV class=right>
<H2>Highest Rated</H2><asp:repeater id=rHigh runat="server"><ITEMTEMPLATE></ITEMTEMPLATE></asp:repeater>
<DIV class=summary style="BACKGROUND-COLOR: rgb(255,255,221)">
<DIV class=headline><SPAN class=bold><A href="http://links.10026.com/?link=http://forums.asp.net/topic.aspx?sub=%3C%#%20DataBinder.Eval%28Container,%20" %="" )="" dataitem.topic_id="">"> <%# DataBinder.Eval(Container, "DataItem.topic_name").toUpper %></A> </SPAN>by <%# DataBinder.Eval(Container, "DataItem.member_name") %> on <%# DataBinder.Eval(Container, "DataItem.creation_date").ToShortDateString %> </DIV><%# DataBinder.Eval(Container, "DataItem.text") %> </DIV></DIV></DIV><asp:label id=lTest runat="server" forecolor="#400000" font-bold="True" font-size="Larger"></asp:label></FORM><BR>
post the mab.ascx and the home.vb.aspx please - they should be plain text - if not - you can paste into notepad then copy-paste.
First, thanks for all your time. Now, these are pasted from VS. When I do that, it looks terrible in the post screen, but turns out almost OK. When I paste from notepad, every tab and space shows up as a etc. So:
--
mab.ascx:
--

<%@. Control Language="vb" AutoEventWireup="false" Codebehind="MAB.ascx.vb" Inherits="MAB.MAB" TargetSchema="http://schemas.microsoft.com/intellisense/ie5" %>

Add a Topic
Editor Queue
Admin Feedback
MAB Home


OrSearch

--
home.aspx.vb
--

Imports System.Data.SqlClient
Imports System.Text.RegularExpressions

Public Class home
Inherits System.Web.UI.Page
Public Conn As New SqlConnection(ConfigurationSettings.AppSettings("conString"))
Protected WithEvents cMAB As MAB

#Region " Web Form Designer Generated Code "

'This call is required by the Web Form Designer.
<System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent()

End Sub
Protected WithEvents rNew As System.Web.UI.WebControls.Repeater
Protected WithEvents rPics As System.Web.UI.WebControls.Repeater
Protected WithEvents rEd As System.Web.UI.WebControls.Repeater
Protected WithEvents rHigh As System.Web.UI.WebControls.Repeater
Protected WithEvents lTest As System.Web.UI.WebControls.Label
Protected WithEvents ddTopic As System.Web.UI.WebControls.DropDownList
Protected WithEvents Label1 As System.Web.UI.WebControls.Label
Protected WithEvents newtopic As System.Web.UI.WebControls.HyperLink
Protected WithEvents hEditorQueue As System.Web.UI.WebControls.HyperLink

'NOTE: The following placeholder declaration is required by the Web Form Designer.
'Do not delete or move it.
Private designerPlaceholderDeclaration As System.Object

Private Sub Page_Init(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Init
'CODEGEN: This method call is required by the Web Form Designer
'Do not modify it using the code editor.
InitializeComponent()
End Sub

#End Region

Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Const homeSize As Integer = 8 'number of articles per column here
Const homeLength As Integer = 200 'number of characters to display per article

Dim qs As String = "SELECT top 10 MAB_articles.article_ID, (SELECT top 1 MAB_articleIndex.topic_ID FROM MAB_articleIndex WHERE "
qs &= "MAB_articleIndex.article_ID = MAB_articles.article_ID) as topic_ID, ( SELECT top 1 topic_name FROM MAB_topics, MAB_articleIndex "
qs &= "WHERE MAB_topics.topic_ID = MAB_articleIndex.topic_ID AND MAB_articleIndex.article_ID = MAB_articles.article_ID) as topic_name "
qs &= "INTO T FROM MAB_articles ORDER BY MAB_articles.mod_date SELECT distinct topic_ID, topic_name FROM T drop table T"
Dim daNew As New SqlDataAdapter(qs, Conn)
Dim dsNew As New DataSet
Conn.Open()
daNew.Fill(dsNew, "articles")
Conn.Close()
rNew.DataSource = dsNew.Tables("articles")
rNew.DataBind()

qs = "SELECT text, (SELECT TOP 1 MAB_topics.topic_ID FROM MAB_topics, MAB_articleIndex WHERE MAB_articles.article_ID = "
qs &= "MAB_articleIndex.article_ID AND MAB_topics.topic_ID = MAB_articleIndex.topic_ID ORDER BY MAB_articleIndex.topic_ID ASC) "
qs &= " as topic_ID FROM MAB_articles WHERE CONTAINS(text, '""img src=*""')"
Dim daPics As New SqlDataAdapter(qs, Conn)
Dim dsPics As New DataSet
Conn.Open()
daPics.Fill(dsPics, "images")
Conn.Close()
For i As Integer = 0 To dsPics.Tables(0).Rows.Count - 1
'regex match for images and extract image tags into the "text" column of the dataset
Dim pat As String = "<img src=.+?>"
Dim r As Regex = New Regex(pat, RegexOptions.IgnoreCase Or RegexOptions.Multiline)
Dim m As Match = r.Match(dsPics.Tables(0).Rows(i).Item("text"))
'Dim matchcount As Integer = 0
Dim newImageString As String = ""
While (m.Success)
'matchcount += 1
newImageString &= m.Value
m = m.NextMatch
End While
dsPics.Tables(0).Rows(i).Item("text") = newImageString
Next
rPics.DataSource = dsPics.Tables(0)
rPics.DataBind()

qs = "SELECT distinct top 20 (MAB_articles.rating * MAB_articles.ed_pick) as ranking, (SELECT TOP 1 MAB_topics.topic_ID FROM MAB_topics, MAB_articleIndex WHERE MAB_articles.article_ID = MAB_articleIndex.article_ID AND MAB_topics.topic_ID = MAB_articleIndex.topic_ID ORDER BY MAB_articleIndex.topic_ID ASC) as topic_ID, (SELECT TOP 1 MAB_topics.topic_name FROM MAB_topics, MAB_articleIndex WHERE MAB_articles.article_ID = MAB_articleIndex.article_ID AND MAB_topics.topic_ID = MAB_articleIndex.topic_ID ORDER BY MAB_articleIndex.topic_ID ASC) as topic_name, MAB_articles.creation_date, MAB_members.member_name, substring(MAB_articles.text, 1, 200) as text FROM MAB_articles, MAB_topics, MAB_articleIndex, MAB_members WHERE MAB_articles.article_ID = MAB_articleIndex.article_ID AND MAB_topics.topic_ID = MAB_articleIndex.topic_ID AND MAB_members.member_ID = MAB_articles.author_ID AND MAB_articles.ed_pick > 0 ORDER BY ranking DESC"
Dim daEd As New SqlDataAdapter(qs, Conn)
Dim dsEd As New DataSet
Conn.Open()
daEd.Fill(dsEd, "articles")
Conn.Close()
For i As Integer = 0 To dsEd.Tables(0).Rows.Count - 1
dsEd.Tables("articles").Rows(i).Item(4) = deSpan(dsEd.Tables("articles").Rows(i).Item(4))
Next
rEd.DataSource = dsEd.Tables("articles")
rEd.DataBind()

qs = "SELECT distinct top 8 MAB_articles.rating, (SELECT TOP 1 MAB_topics.topic_ID FROM MAB_topics, MAB_articleIndex WHERE MAB_articles.article_ID = MAB_articleIndex.article_ID AND MAB_topics.topic_ID = MAB_articleIndex.topic_ID ORDER BY MAB_articleIndex.topic_ID ASC) as topic_ID, (SELECT TOP 1 MAB_topics.topic_name FROM MAB_topics, MAB_articleIndex WHERE MAB_articles.article_ID = MAB_articleIndex.article_ID AND MAB_topics.topic_ID = MAB_articleIndex.topic_ID ORDER BY MAB_articleIndex.topic_ID ASC) as topic_name, MAB_articles.creation_date, MAB_members.member_name, substring(MAB_articles.text, 1, 200) as text FROM MAB_articles, MAB_topics, MAB_articleIndex, MAB_members WHERE MAB_articles.article_ID = MAB_articleIndex.article_ID AND MAB_topics.topic_ID = MAB_articleIndex.topic_ID AND MAB_members.member_ID = MAB_articles.author_ID ORDER BY MAB_articles.rating DESC"
Dim daHigh As New SqlDataAdapter(qs, Conn)
Dim dsHigh As New DataSet
Conn.Open()
daHigh.Fill(dsHigh, "articles")
Conn.Close()
For i As Integer = 0 To dsHigh.Tables(0).Rows.Count - 1
dsHigh.Tables("articles").Rows(i).Item(4) = deSpan(dsHigh.Tables("articles").Rows(i).Item(4))
Next
rHigh.DataSource = dsHigh.Tables("articles")
rHigh.DataBind()
End Sub

Public Function deSpan(ByVal str As String) As String
Dim letterPlace As Integer = 0
Dim spanCount As Integer = 0
While letterPlace < str.Length - 6
If str.Substring(letterPlace, 6) = "<span " Then
spanCount += 1
ElseIf str.Substring(letterPlace, 6) = "</span" Then
spanCount -= 1
End If
letterPlace += 1
End While
Dim braceCount As Integer = 0
For j As Integer = 0 To str.Length - 1
If str.Chars(j) = "<" Then
braceCount += 1
ElseIf str.Chars(j) = ">" Then
braceCount -= 1
End If
Next
For k As Integer = 1 To braceCount
str &= ">"
Next
For i As Integer = 1 To spanCount
str &= "</span>"
Next
Return str
End Function

Private Sub cMAB_topicChanged(ByVal sender As Object, ByVal e As EventArgs) Handles cMAB.topicChanged
Response.Redirect("topic.aspx?sub=3")
End Sub

End Class

Chris (fingers crossed on how it turns out)
Well - I don't see anything wrong there...
You said in your first post that the default.aspx works ( which we haven't seen )
It takes you to login.aspx. From login.aspx, the user is supposed to be redirected to home.aspx
This is where it's failing right ? -Then if you manually type in home.aspx, you get the error.
can you post login aspx and it's vb code?
very weird since it works on development - I would assume its a path or security issue on production server

There is no consumer connection point 'IMessageConsumer' on 'bla [2]'.

I created a static connected webpart.

INTERFACE:
public interface IMessage
{
string Message { get;}
}

USERCONTROL PROVIDER:
public partial class Control1 : System.Web.UI.UserControl, IMessage,
IWebPart
{
protected void Page_Load(object sender, EventArgs e)
{

}
[ConnectionProvider("Message","IMessageProvider")]
public IMessage GetMessage()
{
return this;
}
public string Message
{
get
{
return TextBox1.Text;
}
}

#region IWebPart Members (ETC)

USERCONTROL CONSUMER
public partial class Control2 : System.Web.UI.UserControl, IWebPart
{
protected void Page_Load(object sender, EventArgs e)
{

}

private IMessage _message;

[ConnectionConsumer("Message","IMessageConsumer",AllowsMultipleConnections=true)]
void SetMessage(IMessage message)
{
this._message = message;
}

protected override void OnPreRender(EventArgs e)
{
if (_message != null)
Label1.Text = _message.Message;
base.OnPreRender(e);
}
#region IWebPart Members (ETC)

DEFAULT.ASPX:

<body>
<form id="form1" runat="server">

<div>
<asp:WebPartManager ID="WebPartManager1" runat="server"
Personalization-Enabled="true">
<StaticConnections>
<asp:WebPartConnection ID="conId"
ConsumerID="dataConsumer" ProviderID="dataProvider"
ConsumerConnectionPointID="IMessageConsumer"
ProviderConnectionPointID="IMessageProvider" />
</StaticConnections>

</asp:WebPartManager>
<asp:WebPartZone ID="WebPartZone1" runat="server">
<ZoneTemplate>
<uc1:Control1 ID="dataProvider" runat="server" />
<uc2:Control2 ID="dataConsumer" runat="server" />
</ZoneTemplate>
</asp:WebPartZone>

</div>
</form>
</body>

And I get this error :"There is no consumer connection point
'IMessageConsumer' on 'bla [2]'. "... Checkded it with multiple
tutorials, but can't find what I'm doing wrong.

Hope someone can help me!
Regards,
PatrickUSERCONTROL CONSUMER

Quote:

Originally Posted by

public partial class Control2 : System.Web.UI.UserControl, IWebPart
{
protected void Page_Load(object sender, EventArgs e)
{
>
}
>
private IMessage _message;
>
[ConnectionConsumer("Message","IMessageConsumer",AllowsMultipleConnections=*true)]
void SetMessage(IMessage message)
{
this._message = message;
}
>


Solved it, I forgot to make the SetMessage public ;-)

There is no consumer connection point 'IMessageConsumer' on 'bla '.

I created a static connected webpart.
INTERFACE:
public interface IMessage
{
string Message { get;}
}
USERCONTROL PROVIDER:
public partial class Control1 : System.Web.UI.UserControl, IMessage,
IWebPart
{
protected void Page_Load(object sender, EventArgs e)
{
}
[ConnectionProvider("Message","IMessageProvider")]
public IMessage GetMessage()
{
return this;
}
public string Message
{
get
{
return TextBox1.Text;
}
}
#region IWebPart Members (ETC)
USERCONTROL CONSUMER
public partial class Control2 : System.Web.UI.UserControl, IWebPart
{
protected void Page_Load(object sender, EventArgs e)
{
}
private IMessage _message;
[ConnectionConsumer("Message","IMessageConsumer",AllowsMultipleConnections=t
rue)]
void SetMessage(IMessage message)
{
this._message = message;
}
protected override void OnPreRender(EventArgs e)
{
if (_message != null)
Label1.Text = _message.Message;
base.OnPreRender(e);
}
#region IWebPart Members (ETC)
DEFAULT.ASPX:
<body>
<form id="form1" runat="server">
<div>
<asp:WebPartManager ID="WebPartManager1" runat="server"
Personalization-Enabled="true">
<StaticConnections>
<asp:WebPartConnection ID="conId"
ConsumerID="dataConsumer" ProviderID="dataProvider"
ConsumerConnectionPointID="IMessageConsumer"
ProviderConnectionPointID="IMessageProvider" />
</StaticConnections>
</asp:WebPartManager>
<asp:WebPartZone ID="WebPartZone1" runat="server">
<ZoneTemplate>
<uc1:Control1 ID="dataProvider" runat="server" />
<uc2:Control2 ID="dataConsumer" runat="server" />
</ZoneTemplate>
</asp:WebPartZone>
</div>
</form>
</body>
And I get this error :"There is no consumer connection point
'IMessageConsumer' on 'bla [2]'. "... Checkded it with multiple
tutorials, but can't find what I'm doing wrong.
Hope someone can help me!
Regards,
Patrick> USERCONTROL CONSUMER
> public partial class Control2 : System.Web.UI.UserControl, IWebPart
> {
> protected void Page_Load(object sender, EventArgs e)
> {
> }
> private IMessage _message;
> [ConnectionConsumer("Message","IMessageConsumer",AllowsMultipleConnection=
s=3D=ADtrue)]
> void SetMessage(IMessage message)
> {
> this._message =3D message;
> }
>
Solved it, I forgot to make the SetMessage public ;-)

Wednesday, March 28, 2012

This application is currently offline.........

Hello All,

I got this message when I "Build" my application. What did I do wrong.

"This application is currently offline. To enable the application, remove the app_offline.htm file from the application root directory. "

Thanks

So, did you look in your Solution Explorer, find the file, and do what it said?

Thanks

Yes. I deleted the file and it works fine now.

Why and how this file is created. File says the same thing as "This application is currently offline......."


yes I m also getting this error in my application .....what can be the reason behind it and what is the resolution for this


the resolution is - find the file called 'app_offline.htm' and remove it

Monday, March 26, 2012

This group has 0 topics. Click here to post the first message!

Wow! Did someone hack us or google is doing some clean-up?
Anyway, I don't see a single message in
microsoft.public.dotnet.framework.aspnetMust be a temp glitch.
I get 356,000 messages when I search for "a"
in microsoft.public.dotnet.framework.aspnet
Your message saying that you
"don't see a single message" is there, btw. :-)
Juan T. Llibre
ASP.NET MVP
===========
"Stefan Kiryazov" <chefo@.bulgaria.com> wrote in message
news:1106588619.966334.120670@.z14g2000cwz.googlegroups.com...
> Wow! Did someone hack us or google is doing some clean-up?
> Anyway, I don't see a single message in
> microsoft.public.dotnet.framework.aspnet
>
This is a newsgroup. Google is a web search engine. Google can do nothing to
this newsgroup. It sounds like you're using a browser interface to view
these newsgroups. In that case, there is something wrong with the browser
interface you're using. Try using Outlook Express newsreader instead.
msnews.microsoft.com is the NNTP server.
HTH,
Kevin Spencer
Microsoft MVP
.Net Developer
Neither a follower nor a lender be.
"Stefan Kiryazov" <chefo@.bulgaria.com> wrote in message
news:1106588619.966334.120670@.z14g2000cwz.googlegroups.com...
> Wow! Did someone hack us or google is doing some clean-up?
> Anyway, I don't see a single message in
> microsoft.public.dotnet.framework.aspnet
>
I use google groups beta. I noticed that when I search I actually see
those good old several hundred thousand messages but when I browsed
google saw the group empty. A colleague of mine confirmed this
The horse's mouth is always better than recycled. Use an NNTP client, such
as Microsoft Outlook Newsreader, and go to msnews.microsoft.com for all the
public Microsoft newsgroups.
HTH,
Kevin Spencer
Microsoft MVP
.Net Developer
Neither a follower nor a lender be.
"Stefan Kiryazov" <chefo@.bulgaria.com> wrote in message
news:1106669524.796984.11550@.z14g2000cwz.googlegroups.com...
>I use google groups beta. I noticed that when I search I actually see
> those good old several hundred thousand messages but when I browsed
> google saw the group empty. A colleague of mine confirmed this
>
Also, as this is not a Google newsgroup, you're not going to find any help
using Google here.
HTH,
Kevin Spencer
Microsoft MVP
.Net Developer
Neither a follower nor a lender be.
"Stefan Kiryazov" <chefo@.bulgaria.com> wrote in message
news:1106669524.796984.11550@.z14g2000cwz.googlegroups.com...
>I use google groups beta. I noticed that when I search I actually see
> those good old several hundred thousand messages but when I browsed
> google saw the group empty. A colleague of mine confirmed this
>
OK, sorry for cross posting
But I got quire upset for the priceless archive, but as long as it is
OK I feel secure ;-)
But I didn't understand that about the horse's mouth

This group has 0 topics. Click here to post the first message!

Wow! Did someone hack us or google is doing some clean-up?

Anyway, I don't see a single message in
microsoft.public.dotnet.framework.aspnetMust be a temp glitch.

I get 356,000 messages when I search for "a"
in microsoft.public.dotnet.framework.aspnet

Your message saying that you
"don't see a single message" is there, btw. :-)

Juan T. Llibre
ASP.NET MVP
===========
"Stefan Kiryazov" <chefo@.bulgaria.com> wrote in message
news:1106588619.966334.120670@.z14g2000cwz.googlegr oups.com...
> Wow! Did someone hack us or google is doing some clean-up?
> Anyway, I don't see a single message in
> microsoft.public.dotnet.framework.aspnet
This is a newsgroup. Google is a web search engine. Google can do nothing to
this newsgroup. It sounds like you're using a browser interface to view
these newsgroups. In that case, there is something wrong with the browser
interface you're using. Try using Outlook Express newsreader instead.
msnews.microsoft.com is the NNTP server.

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
Neither a follower nor a lender be.

"Stefan Kiryazov" <chefo@.bulgaria.com> wrote in message
news:1106588619.966334.120670@.z14g2000cwz.googlegr oups.com...
> Wow! Did someone hack us or google is doing some clean-up?
> Anyway, I don't see a single message in
> microsoft.public.dotnet.framework.aspnet
I use google groups beta. I noticed that when I search I actually see
those good old several hundred thousand messages but when I browsed
google saw the group empty. A colleague of mine confirmed this
The horse's mouth is always better than recycled. Use an NNTP client, such
as Microsoft Outlook Newsreader, and go to msnews.microsoft.com for all the
public Microsoft newsgroups.

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
Neither a follower nor a lender be.

"Stefan Kiryazov" <chefo@.bulgaria.com> wrote in message
news:1106669524.796984.11550@.z14g2000cwz.googlegro ups.com...
>I use google groups beta. I noticed that when I search I actually see
> those good old several hundred thousand messages but when I browsed
> google saw the group empty. A colleague of mine confirmed this
Also, as this is not a Google newsgroup, you're not going to find any help
using Google here.

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
Neither a follower nor a lender be.

"Stefan Kiryazov" <chefo@.bulgaria.com> wrote in message
news:1106669524.796984.11550@.z14g2000cwz.googlegro ups.com...
>I use google groups beta. I noticed that when I search I actually see
> those good old several hundred thousand messages but when I browsed
> google saw the group empty. A colleague of mine confirmed this
OK, sorry for cross posting

But I got quire upset for the priceless archive, but as long as it is
OK I feel secure ;-)
But I didn't understand that about the horse's mouth

This Image Generating thing...

Hey!

I wrote a message yersterday and got some good answers and have now managed
to generate a nice image. The problem is that it's all generated in an
Images.Aspx file and I don't really want that. I am writing a WebControl
Library and I want to generate everything from there...

In the Render Sub of the Control I output some HTML and there I need to
reference to a file in the <img> element, is there anyway to NOT have to
point to a aspx file (that generated the picture) there and instead point to
a more local way that I can include in my WebControl Library?

I guess it's possible to render the image as a file and put on the
serverdisk and then point to it but that would be a security risk I guess
and can't really asume, that people that would use this control, like to set
permissions on the server to make it work.

How do I do this?

best regards/
Lars NetzelIf I am correct, you want to create a WebControl that creates an image AND
includes the <img=>... tags when rendered, correct?

You COULD put the binary image inline, but I would not recomend that.

From a browser's point of view an img tag creates another request to the
server to grab the image. So you would need 2 controls/pages:
1) The image creation page, which it looks like you aready have
(images.aspx)
2) The web control which renders the <img> tag.

The webcontrol will render something like "<img
src="/images.aspx?parameters" height=x width=x/>"
When the browser then gets this HTML, it will call up /images.aspx to grab
the actual image.

That's the most straight forward way of doing it that I can think of off
hand.

Steve

"Lars Netzel" <troligt@.apa.se> wrote in message
news:uNUt7i78EHA.2112@.TK2MSFTNGP14.phx.gbl...
> Hey!
> I wrote a message yersterday and got some good answers and have now
managed
> to generate a nice image. The problem is that it's all generated in an
> Images.Aspx file and I don't really want that. I am writing a WebControl
> Library and I want to generate everything from there...
> In the Render Sub of the Control I output some HTML and there I need to
> reference to a file in the <img> element, is there anyway to NOT have to
> point to a aspx file (that generated the picture) there and instead point
to
> a more local way that I can include in my WebControl Library?
> I guess it's possible to render the image as a file and put on the
> serverdisk and then point to it but that would be a security risk I guess
> and can't really asume, that people that would use this control, like to
set
> permissions on the server to make it work.
> How do I do this?
> best regards/
> Lars Netzel
Okay! Thanx, I was afraid of that that was the only way. The thign is I've
seen really cool Chart Controls for the web that renders 3d illustrations
using GDI+ and since they cost a lot I asume they have protected the code
for the image rendering and if it is like you say.. that you can only render
the image from an aspx file.. the code is pretty much open to all... and
also a bit harder to distribute, the user will need to add the aspx file to
his projects.. I wanted to see if it's possible to make a ONE dll solution
for the solution that would incluse all the pictures and just work.

What's your thoughts on this?

/Lars

"Steve Lutz" <slutz@.nospam.comcast.net> skrev i meddelandet
news:uq6Spt%238EHA.1204@.TK2MSFTNGP10.phx.gbl...
> If I am correct, you want to create a WebControl that creates an image AND
> includes the <img=>... tags when rendered, correct?
> You COULD put the binary image inline, but I would not recomend that.
> From a browser's point of view an img tag creates another request to the
> server to grab the image. So you would need 2 controls/pages:
> 1) The image creation page, which it looks like you aready have
> (images.aspx)
> 2) The web control which renders the <img> tag.
> The webcontrol will render something like "<img
> src="http://pics.10026.com/?src=/images.aspx?parameters" height=x width=x/>"
> When the browser then gets this HTML, it will call up /images.aspx to grab
> the actual image.
> That's the most straight forward way of doing it that I can think of off
> hand.
> Steve
>
> "Lars Netzel" <troligt@.apa.se> wrote in message
> news:uNUt7i78EHA.2112@.TK2MSFTNGP14.phx.gbl...
>> Hey!
>>
>> I wrote a message yersterday and got some good answers and have now
> managed
>> to generate a nice image. The problem is that it's all generated in an
>> Images.Aspx file and I don't really want that. I am writing a WebControl
>> Library and I want to generate everything from there...
>>
>> In the Render Sub of the Control I output some HTML and there I need to
>> reference to a file in the <img> element, is there anyway to NOT have to
>> point to a aspx file (that generated the picture) there and instead point
> to
>> a more local way that I can include in my WebControl Library?
>>
>> I guess it's possible to render the image as a file and put on the
>> serverdisk and then point to it but that would be a security risk I guess
>> and can't really asume, that people that would use this control, like to
> set
>> permissions on the server to make it work.
>>
>> How do I do this?
>>
>> best regards/
>> Lars Netzel
>>
>>
Hi Lars,

First, if your ASP.Net code is pretty much open to all, you have a SERIOUS
security hole on your web server!

Second, you must understand that in a web page, an image is requested via a
URL. Now, you could always write a custom HTTP handler that handles the
image request, but you will still have to have a URL that the HTTP handler
can respond to. It is actually much simpler (and just as secure) to do it
the easy way, and write an ASPX page that serves up the image.

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
Neither a follower nor a lender be.

"Lars Netzel" <troligt@.apa.se> wrote in message
news:O67b7c$8EHA.824@.TK2MSFTNGP11.phx.gbl...
> Okay! Thanx, I was afraid of that that was the only way. The thign is I've
> seen really cool Chart Controls for the web that renders 3d illustrations
> using GDI+ and since they cost a lot I asume they have protected the code
> for the image rendering and if it is like you say.. that you can only
> render the image from an aspx file.. the code is pretty much open to
> all... and also a bit harder to distribute, the user will need to add the
> aspx file to his projects.. I wanted to see if it's possible to make a ONE
> dll solution for the solution that would incluse all the pictures and just
> work.
> What's your thoughts on this?
> /Lars
>
> "Steve Lutz" <slutz@.nospam.comcast.net> skrev i meddelandet
> news:uq6Spt%238EHA.1204@.TK2MSFTNGP10.phx.gbl...
>> If I am correct, you want to create a WebControl that creates an image
>> AND
>> includes the <img=>... tags when rendered, correct?
>>
>> You COULD put the binary image inline, but I would not recomend that.
>>
>> From a browser's point of view an img tag creates another request to the
>> server to grab the image. So you would need 2 controls/pages:
>> 1) The image creation page, which it looks like you aready have
>> (images.aspx)
>> 2) The web control which renders the <img> tag.
>>
>> The webcontrol will render something like "<img
>> src="http://pics.10026.com/?src=/images.aspx?parameters" height=x width=x/>"
>> When the browser then gets this HTML, it will call up /images.aspx to
>> grab
>> the actual image.
>>
>> That's the most straight forward way of doing it that I can think of off
>> hand.
>>
>> Steve
>>
>>
>>
>> "Lars Netzel" <troligt@.apa.se> wrote in message
>> news:uNUt7i78EHA.2112@.TK2MSFTNGP14.phx.gbl...
>>> Hey!
>>>
>>> I wrote a message yersterday and got some good answers and have now
>> managed
>>> to generate a nice image. The problem is that it's all generated in an
>>> Images.Aspx file and I don't really want that. I am writing a WebControl
>>> Library and I want to generate everything from there...
>>>
>>> In the Render Sub of the Control I output some HTML and there I need to
>>> reference to a file in the <img> element, is there anyway to NOT have to
>>> point to a aspx file (that generated the picture) there and instead
>>> point
>> to
>>> a more local way that I can include in my WebControl Library?
>>>
>>> I guess it's possible to render the image as a file and put on the
>>> serverdisk and then point to it but that would be a security risk I
>>> guess
>>> and can't really asume, that people that would use this control, like to
>> set
>>> permissions on the server to make it work.
>>>
>>> How do I do this?
>>>
>>> best regards/
>>> Lars Netzel
>>>
>>>
>>
>>
So how does the big guys do this then, check this demosite out... It's a
picture that I guess has do be dynamically rendered... and there's no aspx
reference in the SRC of IMG element

http://demo.xceedsoft.com/XceedChartExplorer/

/Lars Netzel

"Kevin Spencer" <kevin@.DIESPAMMERSDIEtakempis.com> skrev i meddelandet
news:OBZXio$8EHA.2568@.TK2MSFTNGP10.phx.gbl...
> Hi Lars,
> First, if your ASP.Net code is pretty much open to all, you have a SERIOUS
> security hole on your web server!
> Second, you must understand that in a web page, an image is requested via
> a URL. Now, you could always write a custom HTTP handler that handles the
> image request, but you will still have to have a URL that the HTTP handler
> can respond to. It is actually much simpler (and just as secure) to do it
> the easy way, and write an ASPX page that serves up the image.
> --
> HTH,
> Kevin Spencer
> Microsoft MVP
> .Net Developer
> Neither a follower nor a lender be.
> "Lars Netzel" <troligt@.apa.se> wrote in message
> news:O67b7c$8EHA.824@.TK2MSFTNGP11.phx.gbl...
>> Okay! Thanx, I was afraid of that that was the only way. The thign is
>> I've seen really cool Chart Controls for the web that renders 3d
>> illustrations using GDI+ and since they cost a lot I asume they have
>> protected the code for the image rendering and if it is like you say..
>> that you can only render the image from an aspx file.. the code is pretty
>> much open to all... and also a bit harder to distribute, the user will
>> need to add the aspx file to his projects.. I wanted to see if it's
>> possible to make a ONE dll solution for the solution that would incluse
>> all the pictures and just work.
>>
>> What's your thoughts on this?
>>
>> /Lars
>>
>>
>>
>> "Steve Lutz" <slutz@.nospam.comcast.net> skrev i meddelandet
>> news:uq6Spt%238EHA.1204@.TK2MSFTNGP10.phx.gbl...
>>> If I am correct, you want to create a WebControl that creates an image
>>> AND
>>> includes the <img=>... tags when rendered, correct?
>>>
>>> You COULD put the binary image inline, but I would not recomend that.
>>>
>>> From a browser's point of view an img tag creates another request to the
>>> server to grab the image. So you would need 2 controls/pages:
>>> 1) The image creation page, which it looks like you aready have
>>> (images.aspx)
>>> 2) The web control which renders the <img> tag.
>>>
>>> The webcontrol will render something like "<img
>>> src="http://pics.10026.com/?src=/images.aspx?parameters" height=x width=x/>"
>>> When the browser then gets this HTML, it will call up /images.aspx to
>>> grab
>>> the actual image.
>>>
>>> That's the most straight forward way of doing it that I can think of off
>>> hand.
>>>
>>> Steve
>>>
>>>
>>>
>>> "Lars Netzel" <troligt@.apa.se> wrote in message
>>> news:uNUt7i78EHA.2112@.TK2MSFTNGP14.phx.gbl...
>>>> Hey!
>>>>
>>>> I wrote a message yersterday and got some good answers and have now
>>> managed
>>>> to generate a nice image. The problem is that it's all generated in an
>>>> Images.Aspx file and I don't really want that. I am writing a
>>>> WebControl
>>>> Library and I want to generate everything from there...
>>>>
>>>> In the Render Sub of the Control I output some HTML and there I need to
>>>> reference to a file in the <img> element, is there anyway to NOT have
>>>> to
>>>> point to a aspx file (that generated the picture) there and instead
>>>> point
>>> to
>>>> a more local way that I can include in my WebControl Library?
>>>>
>>>> I guess it's possible to render the image as a file and put on the
>>>> serverdisk and then point to it but that would be a security risk I
>>>> guess
>>>> and can't really asume, that people that would use this control, like
>>>> to
>>> set
>>>> permissions on the server to make it work.
>>>>
>>>> How do I do this?
>>>>
>>>> best regards/
>>>> Lars Netzel
>>>>
>>>>
>>>
>>>
>>
>>
they are mapping the requested images to an image generating service on the
server ( ie. rewriting xxx.png as ImageGen.aspx?xxx )

"Lars Netzel" <troligt@.apa.se> wrote in message
news:%23X4ee$B9EHA.3820@.TK2MSFTNGP11.phx.gbl...
> So how does the big guys do this then, check this demosite out... It's a
> picture that I guess has do be dynamically rendered... and there's no aspx
> reference in the SRC of IMG element
> http://demo.xceedsoft.com/XceedChartExplorer/
>
> /Lars Netzel
>
> "Kevin Spencer" <kevin@.DIESPAMMERSDIEtakempis.com> skrev i meddelandet
> news:OBZXio$8EHA.2568@.TK2MSFTNGP10.phx.gbl...
> > Hi Lars,
> > First, if your ASP.Net code is pretty much open to all, you have a
SERIOUS
> > security hole on your web server!
> > Second, you must understand that in a web page, an image is requested
via
> > a URL. Now, you could always write a custom HTTP handler that handles
the
> > image request, but you will still have to have a URL that the HTTP
handler
> > can respond to. It is actually much simpler (and just as secure) to do
it
> > the easy way, and write an ASPX page that serves up the image.
> > --
> > HTH,
> > Kevin Spencer
> > Microsoft MVP
> > .Net Developer
> > Neither a follower nor a lender be.
> > "Lars Netzel" <troligt@.apa.se> wrote in message
> > news:O67b7c$8EHA.824@.TK2MSFTNGP11.phx.gbl...
> >> Okay! Thanx, I was afraid of that that was the only way. The thign is
> >> I've seen really cool Chart Controls for the web that renders 3d
> >> illustrations using GDI+ and since they cost a lot I asume they have
> >> protected the code for the image rendering and if it is like you say..
> >> that you can only render the image from an aspx file.. the code is
pretty
> >> much open to all... and also a bit harder to distribute, the user will
> >> need to add the aspx file to his projects.. I wanted to see if it's
> >> possible to make a ONE dll solution for the solution that would incluse
> >> all the pictures and just work.
> >>
> >> What's your thoughts on this?
> >>
> >> /Lars
> >>
> >>
> >>
> >> "Steve Lutz" <slutz@.nospam.comcast.net> skrev i meddelandet
> >> news:uq6Spt%238EHA.1204@.TK2MSFTNGP10.phx.gbl...
> >>> If I am correct, you want to create a WebControl that creates an image
> >>> AND
> >>> includes the <img=>... tags when rendered, correct?
> >>>
> >>> You COULD put the binary image inline, but I would not recomend that.
> >>>
> >>> From a browser's point of view an img tag creates another request to
the
> >>> server to grab the image. So you would need 2 controls/pages:
> >>> 1) The image creation page, which it looks like you aready have
> >>> (images.aspx)
> >>> 2) The web control which renders the <img> tag.
> >>>
> >>> The webcontrol will render something like "<img
> >>> src="http://pics.10026.com/?src=/images.aspx?parameters" height=x width=x/>"
> >>> When the browser then gets this HTML, it will call up /images.aspx to
> >>> grab
> >>> the actual image.
> >>>
> >>> That's the most straight forward way of doing it that I can think of
off
> >>> hand.
> >>>
> >>> Steve
> >>>
> >>>
> >>>
> >>> "Lars Netzel" <troligt@.apa.se> wrote in message
> >>> news:uNUt7i78EHA.2112@.TK2MSFTNGP14.phx.gbl...
> >>>> Hey!
> >>>>
> >>>> I wrote a message yersterday and got some good answers and have now
> >>> managed
> >>>> to generate a nice image. The problem is that it's all generated in
an
> >>>> Images.Aspx file and I don't really want that. I am writing a
> >>>> WebControl
> >>>> Library and I want to generate everything from there...
> >>>>
> >>>> In the Render Sub of the Control I output some HTML and there I need
to
> >>>> reference to a file in the <img> element, is there anyway to NOT have
> >>>> to
> >>>> point to a aspx file (that generated the picture) there and instead
> >>>> point
> >>> to
> >>>> a more local way that I can include in my WebControl Library?
> >>>>
> >>>> I guess it's possible to render the image as a file and put on the
> >>>> serverdisk and then point to it but that would be a security risk I
> >>>> guess
> >>>> and can't really asume, that people that would use this control, like
> >>>> to
> >>> set
> >>>> permissions on the server to make it work.
> >>>>
> >>>> How do I do this?
> >>>>
> >>>> best regards/
> >>>> Lars Netzel
> >>>>
> >>>>
> >>>
> >>>
> >>
> >>
I've given you the basics. There are several ways to achieve this, one of
which I mentioned: a custom HTTP Handler. With a custom HTTP Handler, you
could use any file extension you like. However, as I said, that isn't
necessary in your case, and would probably be much more difficult for you to
implement, or you wouldn't have to ask.

If I was steering you wrong, believe me, somebody would have told you by
now! ;-)

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
Neither a follower nor a lender be.

"Lars Netzel" <troligt@.apa.se> wrote in message
news:%23X4ee$B9EHA.3820@.TK2MSFTNGP11.phx.gbl...
> So how does the big guys do this then, check this demosite out... It's a
> picture that I guess has do be dynamically rendered... and there's no aspx
> reference in the SRC of IMG element
> http://demo.xceedsoft.com/XceedChartExplorer/
>
> /Lars Netzel
>
> "Kevin Spencer" <kevin@.DIESPAMMERSDIEtakempis.com> skrev i meddelandet
> news:OBZXio$8EHA.2568@.TK2MSFTNGP10.phx.gbl...
>> Hi Lars,
>>
>> First, if your ASP.Net code is pretty much open to all, you have a
>> SERIOUS security hole on your web server!
>>
>> Second, you must understand that in a web page, an image is requested via
>> a URL. Now, you could always write a custom HTTP handler that handles the
>> image request, but you will still have to have a URL that the HTTP
>> handler can respond to. It is actually much simpler (and just as secure)
>> to do it the easy way, and write an ASPX page that serves up the image.
>>
>> --
>> HTH,
>>
>> Kevin Spencer
>> Microsoft MVP
>> .Net Developer
>> Neither a follower nor a lender be.
>>
>> "Lars Netzel" <troligt@.apa.se> wrote in message
>> news:O67b7c$8EHA.824@.TK2MSFTNGP11.phx.gbl...
>>> Okay! Thanx, I was afraid of that that was the only way. The thign is
>>> I've seen really cool Chart Controls for the web that renders 3d
>>> illustrations using GDI+ and since they cost a lot I asume they have
>>> protected the code for the image rendering and if it is like you say..
>>> that you can only render the image from an aspx file.. the code is
>>> pretty much open to all... and also a bit harder to distribute, the user
>>> will need to add the aspx file to his projects.. I wanted to see if it's
>>> possible to make a ONE dll solution for the solution that would incluse
>>> all the pictures and just work.
>>>
>>> What's your thoughts on this?
>>>
>>> /Lars
>>>
>>>
>>>
>>> "Steve Lutz" <slutz@.nospam.comcast.net> skrev i meddelandet
>>> news:uq6Spt%238EHA.1204@.TK2MSFTNGP10.phx.gbl...
>>>> If I am correct, you want to create a WebControl that creates an image
>>>> AND
>>>> includes the <img=>... tags when rendered, correct?
>>>>
>>>> You COULD put the binary image inline, but I would not recomend that.
>>>>
>>>> From a browser's point of view an img tag creates another request to
>>>> the
>>>> server to grab the image. So you would need 2 controls/pages:
>>>> 1) The image creation page, which it looks like you aready have
>>>> (images.aspx)
>>>> 2) The web control which renders the <img> tag.
>>>>
>>>> The webcontrol will render something like "<img
>>>> src="http://pics.10026.com/?src=/images.aspx?parameters" height=x width=x/>"
>>>> When the browser then gets this HTML, it will call up /images.aspx to
>>>> grab
>>>> the actual image.
>>>>
>>>> That's the most straight forward way of doing it that I can think of
>>>> off
>>>> hand.
>>>>
>>>> Steve
>>>>
>>>>
>>>>
>>>> "Lars Netzel" <troligt@.apa.se> wrote in message
>>>> news:uNUt7i78EHA.2112@.TK2MSFTNGP14.phx.gbl...
>>>>> Hey!
>>>>>
>>>>> I wrote a message yersterday and got some good answers and have now
>>>> managed
>>>>> to generate a nice image. The problem is that it's all generated in an
>>>>> Images.Aspx file and I don't really want that. I am writing a
>>>>> WebControl
>>>>> Library and I want to generate everything from there...
>>>>>
>>>>> In the Render Sub of the Control I output some HTML and there I need
>>>>> to
>>>>> reference to a file in the <img> element, is there anyway to NOT have
>>>>> to
>>>>> point to a aspx file (that generated the picture) there and instead
>>>>> point
>>>> to
>>>>> a more local way that I can include in my WebControl Library?
>>>>>
>>>>> I guess it's possible to render the image as a file and put on the
>>>>> serverdisk and then point to it but that would be a security risk I
>>>>> guess
>>>>> and can't really asume, that people that would use this control, like
>>>>> to
>>>> set
>>>>> permissions on the server to make it work.
>>>>>
>>>>> How do I do this?
>>>>>
>>>>> best regards/
>>>>> Lars Netzel
>>>>>
>>>>>
>>>>
>>>>
>>>
>>>
>>
>>
I appriciate you answers and your time spent on this thread. I just wanted
to see if there were other options than using an aspx file as image source.

I guess we'll wait until asp.net 2.0 and see what the DynamicImage control
can achieve!

/Lars

"Kevin Spencer" <kevin@.DIESPAMMERSDIEtakempis.com> skrev i meddelandet
news:Ofx27kC9EHA.2608@.TK2MSFTNGP10.phx.gbl...
> I've given you the basics. There are several ways to achieve this, one of
> which I mentioned: a custom HTTP Handler. With a custom HTTP Handler, you
> could use any file extension you like. However, as I said, that isn't
> necessary in your case, and would probably be much more difficult for you
> to implement, or you wouldn't have to ask.
> If I was steering you wrong, believe me, somebody would have told you by
> now! ;-)
> --
> HTH,
> Kevin Spencer
> Microsoft MVP
> .Net Developer
> Neither a follower nor a lender be.
> "Lars Netzel" <troligt@.apa.se> wrote in message
> news:%23X4ee$B9EHA.3820@.TK2MSFTNGP11.phx.gbl...
>> So how does the big guys do this then, check this demosite out... It's a
>> picture that I guess has do be dynamically rendered... and there's no
>> aspx reference in the SRC of IMG element
>>
>> http://demo.xceedsoft.com/XceedChartExplorer/
>>
>>
>> /Lars Netzel
>>
>>
>> "Kevin Spencer" <kevin@.DIESPAMMERSDIEtakempis.com> skrev i meddelandet
>> news:OBZXio$8EHA.2568@.TK2MSFTNGP10.phx.gbl...
>>> Hi Lars,
>>>
>>> First, if your ASP.Net code is pretty much open to all, you have a
>>> SERIOUS security hole on your web server!
>>>
>>> Second, you must understand that in a web page, an image is requested
>>> via a URL. Now, you could always write a custom HTTP handler that
>>> handles the image request, but you will still have to have a URL that
>>> the HTTP handler can respond to. It is actually much simpler (and just
>>> as secure) to do it the easy way, and write an ASPX page that serves up
>>> the image.
>>>
>>> --
>>> HTH,
>>>
>>> Kevin Spencer
>>> Microsoft MVP
>>> .Net Developer
>>> Neither a follower nor a lender be.
>>>
>>> "Lars Netzel" <troligt@.apa.se> wrote in message
>>> news:O67b7c$8EHA.824@.TK2MSFTNGP11.phx.gbl...
>>>> Okay! Thanx, I was afraid of that that was the only way. The thign is
>>>> I've seen really cool Chart Controls for the web that renders 3d
>>>> illustrations using GDI+ and since they cost a lot I asume they have
>>>> protected the code for the image rendering and if it is like you say..
>>>> that you can only render the image from an aspx file.. the code is
>>>> pretty much open to all... and also a bit harder to distribute, the
>>>> user will need to add the aspx file to his projects.. I wanted to see
>>>> if it's possible to make a ONE dll solution for the solution that would
>>>> incluse all the pictures and just work.
>>>>
>>>> What's your thoughts on this?
>>>>
>>>> /Lars
>>>>
>>>>
>>>>
>>>> "Steve Lutz" <slutz@.nospam.comcast.net> skrev i meddelandet
>>>> news:uq6Spt%238EHA.1204@.TK2MSFTNGP10.phx.gbl...
>>>>> If I am correct, you want to create a WebControl that creates an image
>>>>> AND
>>>>> includes the <img=>... tags when rendered, correct?
>>>>>
>>>>> You COULD put the binary image inline, but I would not recomend that.
>>>>>
>>>>> From a browser's point of view an img tag creates another request to
>>>>> the
>>>>> server to grab the image. So you would need 2 controls/pages:
>>>>> 1) The image creation page, which it looks like you aready have
>>>>> (images.aspx)
>>>>> 2) The web control which renders the <img> tag.
>>>>>
>>>>> The webcontrol will render something like "<img
>>>>> src="http://pics.10026.com/?src=/images.aspx?parameters" height=x width=x/>"
>>>>> When the browser then gets this HTML, it will call up /images.aspx to
>>>>> grab
>>>>> the actual image.
>>>>>
>>>>> That's the most straight forward way of doing it that I can think of
>>>>> off
>>>>> hand.
>>>>>
>>>>> Steve
>>>>>
>>>>>
>>>>>
>>>>> "Lars Netzel" <troligt@.apa.se> wrote in message
>>>>> news:uNUt7i78EHA.2112@.TK2MSFTNGP14.phx.gbl...
>>>>>> Hey!
>>>>>>
>>>>>> I wrote a message yersterday and got some good answers and have now
>>>>> managed
>>>>>> to generate a nice image. The problem is that it's all generated in
>>>>>> an
>>>>>> Images.Aspx file and I don't really want that. I am writing a
>>>>>> WebControl
>>>>>> Library and I want to generate everything from there...
>>>>>>
>>>>>> In the Render Sub of the Control I output some HTML and there I need
>>>>>> to
>>>>>> reference to a file in the <img> element, is there anyway to NOT have
>>>>>> to
>>>>>> point to a aspx file (that generated the picture) there and instead
>>>>>> point
>>>>> to
>>>>>> a more local way that I can include in my WebControl Library?
>>>>>>
>>>>>> I guess it's possible to render the image as a file and put on the
>>>>>> serverdisk and then point to it but that would be a security risk I
>>>>>> guess
>>>>>> and can't really asume, that people that would use this control, like
>>>>>> to
>>>>> set
>>>>>> permissions on the server to make it work.
>>>>>>
>>>>>> How do I do this?
>>>>>>
>>>>>> best regards/
>>>>>> Lars Netzel
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>
>>>
>>
>>
okey, thanx, so they are also in need of an "online" service for the
picture, might not be a local "kick ass" solution that I thought.

/Lars

"gerry" <germ@.hotmail.com> skrev i meddelandet
news:e15WrOC9EHA.3336@.TK2MSFTNGP11.phx.gbl...
> they are mapping the requested images to an image generating service on
> the
> server ( ie. rewriting xxx.png as ImageGen.aspx?xxx )
>
> "Lars Netzel" <troligt@.apa.se> wrote in message
> news:%23X4ee$B9EHA.3820@.TK2MSFTNGP11.phx.gbl...
>> So how does the big guys do this then, check this demosite out... It's a
>> picture that I guess has do be dynamically rendered... and there's no
>> aspx
>> reference in the SRC of IMG element
>>
>> http://demo.xceedsoft.com/XceedChartExplorer/
>>
>>
>> /Lars Netzel
>>
>>
>> "Kevin Spencer" <kevin@.DIESPAMMERSDIEtakempis.com> skrev i meddelandet
>> news:OBZXio$8EHA.2568@.TK2MSFTNGP10.phx.gbl...
>> > Hi Lars,
>>> > First, if your ASP.Net code is pretty much open to all, you have a
> SERIOUS
>> > security hole on your web server!
>>> > Second, you must understand that in a web page, an image is requested
> via
>> > a URL. Now, you could always write a custom HTTP handler that handles
> the
>> > image request, but you will still have to have a URL that the HTTP
> handler
>> > can respond to. It is actually much simpler (and just as secure) to do
> it
>> > the easy way, and write an ASPX page that serves up the image.
>>> > --
>> > HTH,
>>> > Kevin Spencer
>> > Microsoft MVP
>> > .Net Developer
>> > Neither a follower nor a lender be.
>>> > "Lars Netzel" <troligt@.apa.se> wrote in message
>> > news:O67b7c$8EHA.824@.TK2MSFTNGP11.phx.gbl...
>> >> Okay! Thanx, I was afraid of that that was the only way. The thign is
>> >> I've seen really cool Chart Controls for the web that renders 3d
>> >> illustrations using GDI+ and since they cost a lot I asume they have
>> >> protected the code for the image rendering and if it is like you say..
>> >> that you can only render the image from an aspx file.. the code is
> pretty
>> >> much open to all... and also a bit harder to distribute, the user will
>> >> need to add the aspx file to his projects.. I wanted to see if it's
>> >> possible to make a ONE dll solution for the solution that would
>> >> incluse
>> >> all the pictures and just work.
>> >>
>> >> What's your thoughts on this?
>> >>
>> >> /Lars
>> >>
>> >>
>> >>
>> >> "Steve Lutz" <slutz@.nospam.comcast.net> skrev i meddelandet
>> >> news:uq6Spt%238EHA.1204@.TK2MSFTNGP10.phx.gbl...
>> >>> If I am correct, you want to create a WebControl that creates an
>> >>> image
>> >>> AND
>> >>> includes the <img=>... tags when rendered, correct?
>> >>>
>> >>> You COULD put the binary image inline, but I would not recomend that.
>> >>>
>> >>> From a browser's point of view an img tag creates another request to
> the
>> >>> server to grab the image. So you would need 2 controls/pages:
>> >>> 1) The image creation page, which it looks like you aready have
>> >>> (images.aspx)
>> >>> 2) The web control which renders the <img> tag.
>> >>>
>> >>> The webcontrol will render something like "<img
>> >>> src="http://pics.10026.com/?src=/images.aspx?parameters" height=x width=x/>"
>> >>> When the browser then gets this HTML, it will call up /images.aspx to
>> >>> grab
>> >>> the actual image.
>> >>>
>> >>> That's the most straight forward way of doing it that I can think of
> off
>> >>> hand.
>> >>>
>> >>> Steve
>> >>>
>> >>>
>> >>>
>> >>> "Lars Netzel" <troligt@.apa.se> wrote in message
>> >>> news:uNUt7i78EHA.2112@.TK2MSFTNGP14.phx.gbl...
>> >>>> Hey!
>> >>>>
>> >>>> I wrote a message yersterday and got some good answers and have now
>> >>> managed
>> >>>> to generate a nice image. The problem is that it's all generated in
> an
>> >>>> Images.Aspx file and I don't really want that. I am writing a
>> >>>> WebControl
>> >>>> Library and I want to generate everything from there...
>> >>>>
>> >>>> In the Render Sub of the Control I output some HTML and there I need
> to
>> >>>> reference to a file in the <img> element, is there anyway to NOT
>> >>>> have
>> >>>> to
>> >>>> point to a aspx file (that generated the picture) there and instead
>> >>>> point
>> >>> to
>> >>>> a more local way that I can include in my WebControl Library?
>> >>>>
>> >>>> I guess it's possible to render the image as a file and put on the
>> >>>> serverdisk and then point to it but that would be a security risk I
>> >>>> guess
>> >>>> and can't really asume, that people that would use this control,
>> >>>> like
>> >>>> to
>> >>> set
>> >>>> permissions on the server to make it work.
>> >>>>
>> >>>> How do I do this?
>> >>>>
>> >>>> best regards/
>> >>>> Lars Netzel
>> >>>>
>> >>>>
>> >>>
>> >>>
>> >>
>> >>
>>>>
>>

This Image Generating thing...

Hey!
I wrote a message yersterday and got some good answers and have now managed
to generate a nice image. The problem is that it's all generated in an
Images.Aspx file and I don't really want that. I am writing a WebControl
Library and I want to generate everything from there...
In the Render Sub of the Control I output some HTML and there I need to
reference to a file in the <img> element, is there anyway to NOT have to
point to a aspx file (that generated the picture) there and instead point to
a more local way that I can include in my WebControl Library?
I guess it's possible to render the image as a file and put on the
serverdisk and then point to it but that would be a security risk I guess
and can't really asume, that people that would use this control, like to set
permissions on the server to make it work.
How do I do this?
best regards/
Lars NetzelIf I am correct, you want to create a WebControl that creates an image AND
includes the <img=>... tags when rendered, correct?
You COULD put the binary image inline, but I would not recomend that.
From a browser's point of view an img tag creates another request to the
server to grab the image. So you would need 2 controls/pages:
1) The image creation page, which it looks like you aready have
(images.aspx)
2) The web control which renders the <img> tag.
The webcontrol will render something like "<img
src="/images.aspx?parameters" height=x width=x/>"
When the browser then gets this HTML, it will call up /images.aspx to grab
the actual image.
That's the most straight forward way of doing it that I can think of off
hand.
Steve
"Lars Netzel" <troligt@.apa.se> wrote in message
news:uNUt7i78EHA.2112@.TK2MSFTNGP14.phx.gbl...
> Hey!
> I wrote a message yersterday and got some good answers and have now
managed
> to generate a nice image. The problem is that it's all generated in an
> Images.Aspx file and I don't really want that. I am writing a WebControl
> Library and I want to generate everything from there...
> In the Render Sub of the Control I output some HTML and there I need to
> reference to a file in the <img> element, is there anyway to NOT have to
> point to a aspx file (that generated the picture) there and instead point
to
> a more local way that I can include in my WebControl Library?
> I guess it's possible to render the image as a file and put on the
> serverdisk and then point to it but that would be a security risk I guess
> and can't really asume, that people that would use this control, like to
set
> permissions on the server to make it work.
> How do I do this?
> best regards/
> Lars Netzel
>
Okay! Thanx, I was afraid of that that was the only way. The thign is I've
seen really Chart Controls for the web that renders 3d illustrations
using GDI+ and since they cost a lot I asume they have protected the code
for the image rendering and if it is like you say.. that you can only render
the image from an aspx file.. the code is pretty much open to all... and
also a bit harder to distribute, the user will need to add the aspx file to
his projects.. I wanted to see if it's possible to make a ONE dll solution
for the solution that would incluse all the pictures and just work.
What's your thoughts on this?
/Lars
"Steve Lutz" <slutz@.nospam.comcast.net> skrev i meddelandet
news:uq6Spt%238EHA.1204@.TK2MSFTNGP10.phx.gbl...
> If I am correct, you want to create a WebControl that creates an image AND
> includes the <img=>... tags when rendered, correct?
> You COULD put the binary image inline, but I would not recomend that.
> From a browser's point of view an img tag creates another request to the
> server to grab the image. So you would need 2 controls/pages:
> 1) The image creation page, which it looks like you aready have
> (images.aspx)
> 2) The web control which renders the <img> tag.
> The webcontrol will render something like "<img
> src="http://pics.10026.com/?src=/images.aspx?parameters" height=x width=x/>"
> When the browser then gets this HTML, it will call up /images.aspx to grab
> the actual image.
> That's the most straight forward way of doing it that I can think of off
> hand.
> Steve
>
> "Lars Netzel" <troligt@.apa.se> wrote in message
> news:uNUt7i78EHA.2112@.TK2MSFTNGP14.phx.gbl...
> managed
> to
> set
>
Hi Lars,
First, if your ASP.Net code is pretty much open to all, you have a SERIOUS
security hole on your web server!
Second, you must understand that in a web page, an image is requested via a
URL. Now, you could always write a custom HTTP handler that handles the
image request, but you will still have to have a URL that the HTTP handler
can respond to. It is actually much simpler (and just as secure) to do it
the easy way, and write an ASPX page that serves up the image.
HTH,
Kevin Spencer
Microsoft MVP
.Net Developer
Neither a follower nor a lender be.
"Lars Netzel" <troligt@.apa.se> wrote in message
news:O67b7c$8EHA.824@.TK2MSFTNGP11.phx.gbl...
> Okay! Thanx, I was afraid of that that was the only way. The thign is I've
> seen really Chart Controls for the web that renders 3d illustrations
> using GDI+ and since they cost a lot I asume they have protected the code
> for the image rendering and if it is like you say.. that you can only
> render the image from an aspx file.. the code is pretty much open to
> all... and also a bit harder to distribute, the user will need to add the
> aspx file to his projects.. I wanted to see if it's possible to make a ONE
> dll solution for the solution that would incluse all the pictures and just
> work.
> What's your thoughts on this?
> /Lars
>
> "Steve Lutz" <slutz@.nospam.comcast.net> skrev i meddelandet
> news:uq6Spt%238EHA.1204@.TK2MSFTNGP10.phx.gbl...
>
So how does the big guys do this then, check this demosite out... It's a
picture that I guess has do be dynamically rendered... and there's no aspx
reference in the SRC of IMG element
http://demo.xceedsoft.com/XceedChartExplorer/
/Lars Netzel
"Kevin Spencer" <kevin@.DIESPAMMERSDIEtakempis.com> skrev i meddelandet
news:OBZXio$8EHA.2568@.TK2MSFTNGP10.phx.gbl...
> Hi Lars,
> First, if your ASP.Net code is pretty much open to all, you have a SERIOUS
> security hole on your web server!
> Second, you must understand that in a web page, an image is requested via
> a URL. Now, you could always write a custom HTTP handler that handles the
> image request, but you will still have to have a URL that the HTTP handler
> can respond to. It is actually much simpler (and just as secure) to do it
> the easy way, and write an ASPX page that serves up the image.
> --
> HTH,
> Kevin Spencer
> Microsoft MVP
> .Net Developer
> Neither a follower nor a lender be.
> "Lars Netzel" <troligt@.apa.se> wrote in message
> news:O67b7c$8EHA.824@.TK2MSFTNGP11.phx.gbl...
>
they are mapping the requested images to an image generating service on the
server ( ie. rewriting xxx.png as ImageGen.aspx?xxx )
"Lars Netzel" <troligt@.apa.se> wrote in message
news:%23X4ee$B9EHA.3820@.TK2MSFTNGP11.phx.gbl...
> So how does the big guys do this then, check this demosite out... It's a
> picture that I guess has do be dynamically rendered... and there's no aspx
> reference in the SRC of IMG element
> http://demo.xceedsoft.com/XceedChartExplorer/
>
> /Lars Netzel
>
> "Kevin Spencer" <kevin@.DIESPAMMERSDIEtakempis.com> skrev i meddelandet
> news:OBZXio$8EHA.2568@.TK2MSFTNGP10.phx.gbl...
SERIOUS
via
the
handler
it
pretty
the
off
an
to
>
I've given you the basics. There are several ways to achieve this, one of
which I mentioned: a custom HTTP Handler. With a custom HTTP Handler, you
could use any file extension you like. However, as I said, that isn't
necessary in your case, and would probably be much more difficult for you to
implement, or you wouldn't have to ask.
If I was steering you wrong, believe me, somebody would have told you by
now! ;-)
HTH,
Kevin Spencer
Microsoft MVP
.Net Developer
Neither a follower nor a lender be.
"Lars Netzel" <troligt@.apa.se> wrote in message
news:%23X4ee$B9EHA.3820@.TK2MSFTNGP11.phx.gbl...
> So how does the big guys do this then, check this demosite out... It's a
> picture that I guess has do be dynamically rendered... and there's no aspx
> reference in the SRC of IMG element
> http://demo.xceedsoft.com/XceedChartExplorer/
>
> /Lars Netzel
>
> "Kevin Spencer" <kevin@.DIESPAMMERSDIEtakempis.com> skrev i meddelandet
> news:OBZXio$8EHA.2568@.TK2MSFTNGP10.phx.gbl...
>
I appriciate you answers and your time spent on this thread. I just wanted
to see if there were other options than using an aspx file as image source.
I guess we'll wait until asp.net 2.0 and see what the DynamicImage control
can achieve!
/Lars
"Kevin Spencer" <kevin@.DIESPAMMERSDIEtakempis.com> skrev i meddelandet
news:Ofx27kC9EHA.2608@.TK2MSFTNGP10.phx.gbl...
> I've given you the basics. There are several ways to achieve this, one of
> which I mentioned: a custom HTTP Handler. With a custom HTTP Handler, you
> could use any file extension you like. However, as I said, that isn't
> necessary in your case, and would probably be much more difficult for you
> to implement, or you wouldn't have to ask.
> If I was steering you wrong, believe me, somebody would have told you by
> now! ;-)
> --
> HTH,
> Kevin Spencer
> Microsoft MVP
> .Net Developer
> Neither a follower nor a lender be.
> "Lars Netzel" <troligt@.apa.se> wrote in message
> news:%23X4ee$B9EHA.3820@.TK2MSFTNGP11.phx.gbl...
>
okey, thanx, so they are also in need of an "online" service for the
picture, might not be a local "kick ass" solution that I thought.
/Lars
"gerry" <germ@.hotmail.com> skrev i meddelandet
news:e15WrOC9EHA.3336@.TK2MSFTNGP11.phx.gbl...
> they are mapping the requested images to an image generating service on
> the
> server ( ie. rewriting xxx.png as ImageGen.aspx?xxx )
>
> "Lars Netzel" <troligt@.apa.se> wrote in message
> news:%23X4ee$B9EHA.3820@.TK2MSFTNGP11.phx.gbl...
> SERIOUS
> via
> the
> handler
> it
> pretty
> the
> off
> an
> to
>

This is definitely a bug in IIS 6.0 and DotNet Framework 2.0!

This am I posted the following message thinking there was a problem with Dot
Net Framework 2.0. But problem occurs only with Dot Net 2.0 and IIS 6.0
installed machines. I tested this on my laptop running 5.1 and Framework 2.0
and runs perfectly fine.

Can anyone from Microsoft help me. I have all our ASP.Net applications
converted 2.0 and Iam left hanging with this bug.
Jay

Hello,

We have a website running ASP.Net 1.1 using forms authentication and even
protects .htm/.doc files. We have associated such files to ASP.Net in
Application Settings.

Everything was working great until we moved to 2.0.

If we try to access a .htm page we get "Page cannot be displayed errror".
In the Application settings there are two check boxes "script engine" and
"verify that file exists" both are checked by default.

If the script engine check box is unchecked then it gives me "execute access
is
denied" error.

Why is this breaking change from 1.1 to 2.0, how do we resolve it?

Thanks.

--
Jay Balapa
www.atginc.comPlease first read this blog entry on troubleshooting.

http://blogs.msdn.com/david.wang/ar...leshooting.aspx

Realize that making random configuration changes prior to careful analysis
of the original error condition, as mentioned by the blog entry, does not
help your situation.

In your case, unchecking "Script Engine" does not help because it is the
means by which resources with Application Mappings can be executed when
Execute Permission is merely "Script" (which is the default setting). Don't
fiddle around with it nor the Execute Permission because... oh, just read
the blog entry for why.
:-)

So, please provide the log entry corresponding to the request which is
supposed to succeed but is not.

Now, since you are using non-standard configuration, also provide any
non-default Application mapping modifications as well as
web.config/machine.config modifications to make your current application
work.

In particular, are you seeing the failure on all content types mapped to
aspnet_isapi.dll or just .htm/.doc.

Since mapping non dot-net content to aspnet_isapi.dll to be protected by
Forms Authentication is not exactly the normal/default scenario, some things
actually did change on upgrade... But we need to first confirm your custom
configuration.

--
//David
IIS
http://blogs.msdn.com/David.Wang
This posting is provided "AS IS" with no warranties, and confers no rights.
//

"Jay Balapa" <jbalapa@.atginc.com> wrote in message
news:eRJ$8MmFGHA.216@.TK2MSFTNGP15.phx.gbl...
> This am I posted the following message thinking there was a problem with
> Dot Net Framework 2.0. But problem occurs only with Dot Net 2.0 and IIS
> 6.0 installed machines. I tested this on my laptop running 5.1 and
> Framework 2.0 and runs perfectly fine.
> Can anyone from Microsoft help me. I have all our ASP.Net applications
> converted 2.0 and Iam left hanging with this bug.
> Jay
>
> Hello,
> We have a website running ASP.Net 1.1 using forms authentication and even
> protects .htm/.doc files. We have associated such files to ASP.Net in
> Application Settings.
>
> Everything was working great until we moved to 2.0.
> If we try to access a .htm page we get "Page cannot be displayed errror".
> In the Application settings there are two check boxes "script engine" and
> "verify that file exists" both are checked by default.
>
> If the script engine check box is unchecked then it gives me "execute
> access
> is
> denied" error.
> Why is this breaking change from 1.1 to 2.0, how do we resolve it?
> Thanks.
> --
> Jay Balapa
> www.atginc.com
>
For the request in question, what is being logged in the IIS logfile? Please
post the relevant entry/entries.

Thanks

Cheers
Ken

"Jay Balapa" <jbalapa@.atginc.com> wrote in message
news:eRJ$8MmFGHA.216@.TK2MSFTNGP15.phx.gbl...
: This am I posted the following message thinking there was a problem with
Dot
: Net Framework 2.0. But problem occurs only with Dot Net 2.0 and IIS 6.0
: installed machines. I tested this on my laptop running 5.1 and Framework
2.0
: and runs perfectly fine.
:
: Can anyone from Microsoft help me. I have all our ASP.Net applications
: converted 2.0 and Iam left hanging with this bug.
: Jay
:
:
:
: Hello,
:
: We have a website running ASP.Net 1.1 using forms authentication and even
: protects .htm/.doc files. We have associated such files to ASP.Net in
: Application Settings.
:
:
: Everything was working great until we moved to 2.0.
:
: If we try to access a .htm page we get "Page cannot be displayed errror".
: In the Application settings there are two check boxes "script engine" and
: "verify that file exists" both are checked by default.
:
:
: If the script engine check box is unchecked then it gives me "execute
access
: is
: denied" error.
:
: Why is this breaking change from 1.1 to 2.0, how do we resolve it?
:
: Thanks.
:
: --
: Jay Balapa
: www.atginc.com
:
:
:
:
Ken and David,

Thanks for replying to my post.

***************************************888
> So, please provide the log entry corresponding to the request which is
> supposed to succeed but is not.
**********************************************88
Here are the log file entries- First entry is the aspx entry second is the
..htm entry not working.

2006-01-11 15:17:02 W3SVC1 10.0.0.32 POST /login.aspx - 80 - 10.0.0.163
Mozilla/4.0+(compatible;+MSIE+6.0;+Windows+NT+5.1;+SV1;+.N ET+CLR+1.1.4322;+.NET+CLR+1.0.3705;+.NET+CLR+2.0.5 0727)
302 0 0
2006-01-11 15:17:02 W3SVC1 10.0.0.32 GET /clients/vipdemo/gateway.htm - 80 -
10.0.0.163
Mozilla/4.0+(compatible;+MSIE+6.0;+Windows+NT+5.1;+SV1;+.N ET+CLR+1.1.4322;+.NET+CLR+1.0.3705;+.NET+CLR+2.0.5 0727)
200 0 0

********************************************
> web.config/machine.config modifications to make your current application
> work.
***********************************************8

We just followed the default forms authentication guidelines, following are
the entries-
In the root folder this was the entry-
<system.web>
<sessionState mode="InProc" cookieless="true" />
<trace enabled="true" requestLimit="10" pageOutput="true"
traceMode="SortByTime" localOnly="true"/>
<authentication mode="Forms">
<forms loginUrl="login.aspx" protection="All" />
</authentication>
<customErrors mode="Off"/>
</system.web
In the sub folder where we need protection we have this at the root-

<system.web>
<authorization>
<deny users="?"></deny>
</authorization>
</system.web
************************************************** ****888
> In particular, are you seeing the failure on all content types mapped to
> aspnet_isapi.dll or just .htm/.doc.
************************************************** **********
Iam only seeing failure on mapped files like .htm/.doc. There are no issues
with aspx files. If I take the mapping off everything works great, but
files are not protected.

Thanks again for all your help.

jay Balapa
www.atginc.com

"David Wang [Msft]" <someone@.online.microsoft.com> wrote in message
news:OQpGhynFGHA.3000@.TK2MSFTNGP14.phx.gbl...
> Please first read this blog entry on troubleshooting.
> http://blogs.msdn.com/david.wang/ar...leshooting.aspx
> Realize that making random configuration changes prior to careful analysis
> of the original error condition, as mentioned by the blog entry, does not
> help your situation.
> In your case, unchecking "Script Engine" does not help because it is the
> means by which resources with Application Mappings can be executed when
> Execute Permission is merely "Script" (which is the default setting).
> Don't fiddle around with it nor the Execute Permission because... oh, just
> read the blog entry for why.
> :-)
> So, please provide the log entry corresponding to the request which is
> supposed to succeed but is not.
> Now, since you are using non-standard configuration, also provide any
> non-default Application mapping modifications as well as
> web.config/machine.config modifications to make your current application
> work.
> In particular, are you seeing the failure on all content types mapped to
> aspnet_isapi.dll or just .htm/.doc.
> Since mapping non dot-net content to aspnet_isapi.dll to be protected by
> Forms Authentication is not exactly the normal/default scenario, some
> things actually did change on upgrade... But we need to first confirm your
> custom configuration.
> --
> //David
> IIS
> http://blogs.msdn.com/David.Wang
> This posting is provided "AS IS" with no warranties, and confers no
> rights.
> //
> "Jay Balapa" <jbalapa@.atginc.com> wrote in message
> news:eRJ$8MmFGHA.216@.TK2MSFTNGP15.phx.gbl...
>> This am I posted the following message thinking there was a problem with
>> Dot Net Framework 2.0. But problem occurs only with Dot Net 2.0 and IIS
>> 6.0 installed machines. I tested this on my laptop running 5.1 and
>> Framework 2.0 and runs perfectly fine.
>>
>> Can anyone from Microsoft help me. I have all our ASP.Net applications
>> converted 2.0 and Iam left hanging with this bug.
>> Jay
>>
>>
>>
>> Hello,
>>
>> We have a website running ASP.Net 1.1 using forms authentication and even
>> protects .htm/.doc files. We have associated such files to ASP.Net in
>> Application Settings.
>>
>>
>> Everything was working great until we moved to 2.0.
>>
>> If we try to access a .htm page we get "Page cannot be displayed errror".
>> In the Application settings there are two check boxes "script engine" and
>> "verify that file exists" both are checked by default.
>>
>>
>> If the script engine check box is unchecked then it gives me "execute
>> access
>> is
>> denied" error.
>>
>> Why is this breaking change from 1.1 to 2.0, how do we resolve it?
>>
>> Thanks.
>>
>> --
>> Jay Balapa
>> www.atginc.com
>>
>>
>>
>>
The log entry says that IIS handed the request to ASP.Net, so there is no
bug in IIS6 portion. I do not think there is a bug in the ASP.Net portion,
either, because I've used ASP.Net 2.0 to protect non-.Net content before
with no problems.

Is there anything in your .config file which prevents .htm or .doc from
being served by ASP.Net. In particular, what does your upgraded
machine.config look like for the httpHandler section -- is it actually
configured to serve the resources you are talking about.

--
//David
IIS
http://blogs.msdn.com/David.Wang
This posting is provided "AS IS" with no warranties, and confers no rights.
//

"Jay Balapa" <jbalapa@.atginc.com> wrote in message
news:OGtEYRsFGHA.524@.TK2MSFTNGP09.phx.gbl...
> Ken and David,
> Thanks for replying to my post.
>
> ***************************************888
>> So, please provide the log entry corresponding to the request which is
>> supposed to succeed but is not.
> **********************************************88
> Here are the log file entries- First entry is the aspx entry second is the
> .htm entry not working.
> 2006-01-11 15:17:02 W3SVC1 10.0.0.32 POST /login.aspx - 80 - 10.0.0.163
> Mozilla/4.0+(compatible;+MSIE+6.0;+Windows+NT+5.1;+SV1;+.N ET+CLR+1.1.4322;+.NET+CLR+1.0.3705;+.NET+CLR+2.0.5 0727)
> 302 0 0
> 2006-01-11 15:17:02 W3SVC1 10.0.0.32 GET /clients/vipdemo/gateway.htm -
> 80 - 10.0.0.163
> Mozilla/4.0+(compatible;+MSIE+6.0;+Windows+NT+5.1;+SV1;+.N ET+CLR+1.1.4322;+.NET+CLR+1.0.3705;+.NET+CLR+2.0.5 0727)
> 200 0 0
>
>
> ********************************************
>> web.config/machine.config modifications to make your current application
>> work.
> ***********************************************8
> We just followed the default forms authentication guidelines, following
> are the entries-
> In the root folder this was the entry-
> <system.web>
> <sessionState mode="InProc" cookieless="true" />
> <trace enabled="true" requestLimit="10" pageOutput="true"
> traceMode="SortByTime" localOnly="true"/>
> <authentication mode="Forms">
> <forms loginUrl="login.aspx" protection="All" />
> </authentication>
> <customErrors mode="Off"/>
> </system.web>
> In the sub folder where we need protection we have this at the root-
> <system.web>
> <authorization>
> <deny users="?"></deny>
> </authorization>
> </system.web>
>
> ************************************************** ****888
>> In particular, are you seeing the failure on all content types mapped to
>> aspnet_isapi.dll or just .htm/.doc.
> ************************************************** **********
> Iam only seeing failure on mapped files like .htm/.doc. There are no
> issues with aspx files. If I take the mapping off everything works great,
> but files are not protected.
> Thanks again for all your help.
> jay Balapa
> www.atginc.com
>
>
>
>
>
>
>
>
> "David Wang [Msft]" <someone@.online.microsoft.com> wrote in message
> news:OQpGhynFGHA.3000@.TK2MSFTNGP14.phx.gbl...
>> Please first read this blog entry on troubleshooting.
>>
>> http://blogs.msdn.com/david.wang/ar...leshooting.aspx
>>
>> Realize that making random configuration changes prior to careful
>> analysis of the original error condition, as mentioned by the blog entry,
>> does not help your situation.
>>
>> In your case, unchecking "Script Engine" does not help because it is the
>> means by which resources with Application Mappings can be executed when
>> Execute Permission is merely "Script" (which is the default setting).
>> Don't fiddle around with it nor the Execute Permission because... oh,
>> just read the blog entry for why.
>> :-)
>>
>> So, please provide the log entry corresponding to the request which is
>> supposed to succeed but is not.
>>
>> Now, since you are using non-standard configuration, also provide any
>> non-default Application mapping modifications as well as
>> web.config/machine.config modifications to make your current application
>> work.
>>
>> In particular, are you seeing the failure on all content types mapped to
>> aspnet_isapi.dll or just .htm/.doc.
>>
>> Since mapping non dot-net content to aspnet_isapi.dll to be protected by
>> Forms Authentication is not exactly the normal/default scenario, some
>> things actually did change on upgrade... But we need to first confirm
>> your custom configuration.
>>
>> --
>> //David
>> IIS
>> http://blogs.msdn.com/David.Wang
>> This posting is provided "AS IS" with no warranties, and confers no
>> rights.
>> //
>>
>> "Jay Balapa" <jbalapa@.atginc.com> wrote in message
>> news:eRJ$8MmFGHA.216@.TK2MSFTNGP15.phx.gbl...
>>> This am I posted the following message thinking there was a problem with
>>> Dot Net Framework 2.0. But problem occurs only with Dot Net 2.0 and IIS
>>> 6.0 installed machines. I tested this on my laptop running 5.1 and
>>> Framework 2.0 and runs perfectly fine.
>>>
>>> Can anyone from Microsoft help me. I have all our ASP.Net applications
>>> converted 2.0 and Iam left hanging with this bug.
>>> Jay
>>>
>>>
>>>
>>> Hello,
>>>
>>> We have a website running ASP.Net 1.1 using forms authentication and
>>> even
>>> protects .htm/.doc files. We have associated such files to ASP.Net in
>>> Application Settings.
>>>
>>>
>>> Everything was working great until we moved to 2.0.
>>>
>>> If we try to access a .htm page we get "Page cannot be displayed
>>> errror".
>>> In the Application settings there are two check boxes "script engine"
>>> and
>>> "verify that file exists" both are checked by default.
>>>
>>>
>>> If the script engine check box is unchecked then it gives me "execute
>>> access
>>> is
>>> denied" error.
>>>
>>> Why is this breaking change from 1.1 to 2.0, how do we resolve it?
>>>
>>> Thanks.
>>>
>>> --
>>> Jay Balapa
>>> www.atginc.com
>>>
>>>
>>>
>>>
>>
>>
I'm seeing this same problem with IIS 6 and ASP.NET 2.0 as well. On my
test machine, which has IIS 5.1, I can map htm files to ASP.NET 2.0 and
it works fine but when I move my app to the production server running
IIS 6 and configure the virtual directory to send htm files to ASP.NET
2.0 the files are not served. When I check the log files I see the
request comes in but zero bytes are sent out, no headers, nothing. I'm
not aware of any configuring being done to the server either as we just
installed .NET 2.0 on Monday and I'm the one primarily using it. I
should mention ASP.NET 1.1 on the same server can send htm files
without problem, it's only ASP.NET 2.0 and only on IIS 6 where the
problem occurs. Does anyone have any insight into this?
If you have 1.1 on the same W2K3 Server as the 2.0, you have to run the
ASP.NET in separate application pools. In IIS, create a new application
pool and then through the Properties dialog of your web app using 2.0,
change to the new application pool.
--
Christopher A. Reed
"The oxen are slow, but the earth is patient."

<zzhumphreyt@.gmail.com> wrote in message
news:1138804187.904844.308490@.f14g2000cwb.googlegr oups.com...
> I'm seeing this same problem with IIS 6 and ASP.NET 2.0 as well. On my
> test machine, which has IIS 5.1, I can map htm files to ASP.NET 2.0 and
> it works fine but when I move my app to the production server running
> IIS 6 and configure the virtual directory to send htm files to ASP.NET
> 2.0 the files are not served. When I check the log files I see the
> request comes in but zero bytes are sent out, no headers, nothing. I'm
> not aware of any configuring being done to the server either as we just
> installed .NET 2.0 on Monday and I'm the one primarily using it. I
> should mention ASP.NET 1.1 on the same server can send htm files
> without problem, it's only ASP.NET 2.0 and only on IIS 6 where the
> problem occurs. Does anyone have any insight into this?
I did that. I was looking into this more and discovered the default
web.config for htm files in 2.0 is set to the
System.Web.DefaultHttpHandler class. I used WinMerge to compare the
default web.config on the server to the one on my machine and they're
the same. Since this class wasn't working I was looking at other
httpHandlers in the config and saw the System.Web.StaticFileHandler
being used for some files. I added lines in my app's web.config to set
htm files to that and everything started working. I'm glad I'm found a
solution but I'm still confused why I would even need to do this in the
first place since the default config works on my machine but not the
server. I have ASP.NET 1.1 on my machine too, just like the server.
I'm at a loss and still inclined to believe there's a bug or something
screwy between ASP.NET 2.0 and IIS 6, or rather the
System.Web.DefaultHttpHandler class acts differently in this
environment than in others.

But to recap, if this can help others, I added these lines to my own
app's web.config file, I didn't touch the default web.config file here
C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\CONF IG\web.config because
I didn't want to affect other app's on the server.

<httpHandlers>
<add path="*.htm" verb="*" type="System.Web.StaticFileHandler"
validate="True" />
<add path="*.html" verb="*" type="System.Web.StaticFileHandler"
validate="True" />
</httpHandlers
Actually, DefaultHttpHandler has to act differently between IIS5.1 on XP Pro
and IIS6 on WS03 because of new functionality. The new functionality made
some of the old configuration not work (but others work even better), but I
think you'll find the new alternatives more powerful.

What you describe would work if you mapped .* instead of .htm to
ASPNET_ISAPI.DLL. With IIS6 and ASP.Net it is no longer necessary to
pick-and-choose the scriptmapping up-front. DefaultHttpHandler is able to
hand the request *back* to IIS6 for processing. How is this useful?

On ASP.Net 1.1, people liked to map content to ASP.Net to apply forms auth
to them. Unfortunately, ASP.Net 1.1 had no way to hand the request back to
IIS, so this only worked for static content; you could not apply ASP.Net
forms auth to ASP content and still have that page correctly process as ASP.
Thus it is necessary to pick-and-choose the extensions to configure
Application Mappings. Well on ASP.Net and IIS6, you *can* with the
DefaultHttpHandler and it works by default... it you configure
ASPNET_ISAPI.DLL as the wildcard application mapping.

Put another way - now that DefaultHttpHandler is able to hand requests back
to IIS it is now possible to setup infinite loops for request processing.
You found one of them - map .htm to ASPNET_ISAPI.DLL and then make a request
to .htm resource, which is routed to ASPNET_ISAPI.DLL, which has no
HttpHandler for .htm and falls through to DefaultHttpHandler, who hands the
request back to IIS, who routes .htm to ASPNET_ISAPI.DLL... and you have a
loop.

What you did, map .htm to StaticFileHandler , works because it breaks the
loop, but it is not as efficient as mapping .* to ASPNET_ISAPI.DLL, letting
DefaultHttpHandler route that request back to IIS, who has special logic to
break loops for wildcard application mappings... which then allows you to
take advantage of the native Static File Handler.

The entire area of applying ASP.Net HttpModule/HttpHandler to non-ASP.Net
resource and reconciling IIS ScriptMaps and HttpHandler is currently
confusing unless you understand both IIS and ASP.Net architecture (or you
just blindly follow whatever people seem to be doing)... and it is something
we are addressing in a unified approach in IIS7.

--
//David
IIS
http://blogs.msdn.com/David.Wang
This posting is provided "AS IS" with no warranties, and confers no rights.
//

<zzhumphreyt@.gmail.com> wrote in message
news:1138890016.293264.70150@.g47g2000cwa.googlegro ups.com...
>I did that. I was looking into this more and discovered the default
> web.config for htm files in 2.0 is set to the
> System.Web.DefaultHttpHandler class. I used WinMerge to compare the
> default web.config on the server to the one on my machine and they're
> the same. Since this class wasn't working I was looking at other
> httpHandlers in the config and saw the System.Web.StaticFileHandler
> being used for some files. I added lines in my app's web.config to set
> htm files to that and everything started working. I'm glad I'm found a
> solution but I'm still confused why I would even need to do this in the
> first place since the default config works on my machine but not the
> server. I have ASP.NET 1.1 on my machine too, just like the server.
> I'm at a loss and still inclined to believe there's a bug or something
> screwy between ASP.NET 2.0 and IIS 6, or rather the
> System.Web.DefaultHttpHandler class acts differently in this
> environment than in others.
> But to recap, if this can help others, I added these lines to my own
> app's web.config file, I didn't touch the default web.config file here
> C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\CONF IG\web.config because
> I didn't want to affect other app's on the server.
> <httpHandlers>
> <add path="*.htm" verb="*" type="System.Web.StaticFileHandler"
> validate="True" />
> <add path="*.html" verb="*" type="System.Web.StaticFileHandler"
> validate="True" />
> </httpHandlers