Search:
Namespaces
Discussions
.NET v1.1
Feedback
User Control Question
Messages
Related Types
This message was discovered on
ASPFriends.com 'aspngclient' list
.
Suneel Jhangiani
-- Moved from [aspngfreeforall] to [aspngclient] by Yannick Smits <
Click here to reveal e-mail address
> --
I'm trying to create a user control that is in my opinion fairly
complex, and am not sure exactly how to go about it.
What I am trying to do is create an enhanced IFrame and embed all the
additional code within the user control. The idea is that someone could
drop the control into there ASPX page and it would render the relevant
code for the IFRAME tag. However, due to the fact that the IFrame loads
content from another file, I need to have variables that allow the other
file to set height and width parameters which is where I am getting
stuck.
What I am trying to achieve is a scrollable area within a web page that
can use a custom scroll bar.
So, can anyone give me any help on doing this with an IFrame, or some
other methods?
Regards,
Suneel.
Reply to this message...
Alex Dresko
Can you give an example of what you want the end result to be in HTML?
Alex Dresko
Three Point Oh!
-----Original Message-----
From: Suneel Jhangiani [mailto:
Click here to reveal e-mail address
]
Sent: Wednesday, July 10, 2002 10:41 AM
To: aspngclient
Subject: [aspngclient] User Control Question
-- Moved from [aspngfreeforall] to [aspngclient] by Yannick Smits
<
Click here to reveal e-mail address
> --
I'm trying to create a user control that is in my opinion fairly
complex, and am not sure exactly how to go about it.
What I am trying to do is create an enhanced IFrame and embed all the
additional code within the user control. The idea is that someone could
drop the control into there ASPX page and it would render the relevant
code for the IFRAME tag. However, due to the fact that the IFrame loads
content from another file, I need to have variables that allow the other
file to set height and width parameters which is where I am getting
stuck.
What I am trying to achieve is a scrollable area within a web page that
can use a custom scroll bar.
So, can anyone give me any help on doing this with an IFrame, or some
other methods?
Regards,
Suneel.
| [aspngclient] member
Click here to reveal e-mail address
= YOUR ID
|
http://www.aspfriends.com/aspfriends/aspngclient.asp
= JOIN/QUIT
Reply to this message...
Suneel Jhangiani
Well, that's the tricky part, as the output should be as below, but
should be brought into the main page via an IFRAME tag.=20
Main Page
---------
<HTML>
<HEAD>
<TITLE>news</TITLE>
<META http-equiv=3D"Content-Type" content=3D"text/html;
charset=3Dwindows-1252">
</HEAD>
<BODY bgColor=3D"#003366">
<form name=3D"Form1" method=3D"post" action=3D"t.aspx"
id=3D"Form1">
{Other Content} =09
<IFRAME name=3D"News" src=3D" IFRAME Content Page " frameBorder=3D"0"
width=3D"322" height=3D"115">
{Other Content}
</form>
</BODY>
</HTML>
IFRAME Content Page
-------------------
<HTML>
<HEAD>
<TITLE>news</TITLE>
<META http-equiv=3D"Content-Type" content=3D"text/html;
charset=3Dwindows-1252">
<script language=3D"JavaScript"
src=3D"/Layout/Controls/Scrollbar/Scrollbar.js"></script>
<LINK href=3D"/Layout/StyleSheets/stylesheet.css"
type=3D"text/css" rel=3D"stylesheet">
<STYLE type=3D"text/css">
#content {POSITION: absolute}
BODY {MARGIN: 0px; OVERFLOW: hidden; WIDTH:
100%; HEIGHT: 100%}
</STYLE>
<script language=3D"javascript">
<!-- // Variables for scroller
var upH =3D 18; // Height of up-arrow
var upW =3D 12; // Width of up-arrow
var downH =3D 18; // Height of down-arrow
var downW =3D 12; // Width of down-arrow
var dragH =3D 26; // Height of Dragbar
var dragW =3D 17; // Width of Dragbar
var scrollH =3D 58; // Height of scrollbar
var speed =3D 4; // Scroll speed
//-->
</script>
</HEAD>
<BODY bgColor=3D"#003366" leftMargin=3D"0" topMargin=3D"0"
onload=3D"eventLoader();" marginheight=3D"0" marginwidth=3D"0">
<TABLE height=3D"200" cellSpacing=3D"0" cellPadding=3D"0"
width=3D"322" border=3D"0">
<TBODY>
<TR>
<TD> </TD>
</TR>
</TBODY>
</TABLE>
<!-- div containing up-arrow | change: top + left -->
<SPAN id=3D"up" style=3D"Z-INDEX: 1; LEFT: 310px; WIDTH:
1px; POSITION: absolute; TOP: 8px; HEIGHT: 1px">
<IMG height=3D"25"
src=3D"/Layout/Controls/Scrollbar/scroll_up.gif" width=3D"10" =
border=3D"0">
</SPAN>
<!-- div containing down-arrow | change: top + left -->
<SPAN id=3D"down" style=3D"Z-INDEX: 2; LEFT: 310px; WIDTH:
1px; POSITION: absolute; TOP: 85px; HEIGHT: 1px">
<IMG height=3D"25"
src=3D"/Layout/Controls/Scrollbar/scroll_down.gif" width=3D"10" =
border=3D"0">
</SPAN>
<!-- div containing scrollbar | change: top + left +
width + height -->
<SPAN id=3D"drag" style=3D"Z-INDEX: 3; LEFT: 310px; WIDTH:
17px; POSITION: absolute; TOP: 27px; HEIGHT: 26px">
<IMG height=3D"31"
src=3D"/Layout/Controls/Scrollbar/scroll_bar.gif" width=3D"10">
</SPAN>
<!-- div laying above scrollbar for netscape 6
protection | change: top + left + width + height -->
<SPAN id=3D"ruler" style=3D"Z-INDEX: 4; LEFT: 306px; WIDTH:
17px; POSITION: absolute; TOP: 27px; HEIGHT: 26px"></SPAN>
<!-- div containing content | change: top + left + width
+ height + clip -->
<SPAN id=3D"contentClip" style=3D"Z-INDEX: 5; LEFT: 6px;
VISIBILITY: visible; OVERFLOW: hidden; WIDTH: 300px; CLIP: rect(0px
320px 115px 0px); POSITION: absolute; TOP: 5px; HEIGHT: 110px">
<SPAN class=3D"News">
<SPAN id=3D"content" style=3D"LEFT: 0px;
WIDTH: 280px; TOP: 0px; HEIGHT: 110px">
<P><IMG height=3D"7"
src=3D"/Layout/Controls/Scrollbar/header.gif" width=3D"24"> Monday=20
06/05/2002</P>Sample
news item entry. This can be HTML based text and include all relevant
formatting commands. It can also include links and images, although care
should be given to image size.
<P><IMG height=3D"7"
src=3D"/Layout/Controls/Scrollbar/header.gif" width=3D"24"> Sunday
05/05/2002<P>Sample news item entry. This can be HTML based text and
include all relevant formatting commands. It can also include links and
images, although care should be given to image size.
<P><IMG height=3D"7"
src=3D"/Layout/Controls/Scrollbar/header.gif" width=3D"24"> Saturday
04/05/2002<P>Sample news item entry. This can be HTML based text and
include all relevant formatting commands. It can also include links and
images, although care should be given to image size.
</SPAN>
</SPAN>
</SPAN>
</P>
<P> </P>
</BODY>
</HTML>
-----Original Message-----
From: Alex Dresko [mailto:
Click here to reveal e-mail address
]=20
Sent: 10 July 2002 16:51
To: aspngclient
Subject: [aspngclient] RE: User Control Question
Can you give an example of what you want the end result to be in HTML?=20
Alex Dresko
Three Point Oh!
-----Original Message-----
From: Suneel Jhangiani [mailto:
Click here to reveal e-mail address
]=20
Sent: Wednesday, July 10, 2002 10:41 AM
To: aspngclient
Subject: [aspngclient] User Control Question
-- Moved from [aspngfreeforall] to [aspngclient] by Yannick Smits
<
Click here to reveal e-mail address
> --
I'm trying to create a user control that is in my opinion fairly
complex, and am not sure exactly how to go about it.
What I am trying to do is create an enhanced IFrame and embed all the
additional code within the user control. The idea is that someone could
drop the control into there ASPX page and it would render the relevant
code for the IFRAME tag. However, due to the fact that the IFrame loads
content from another file, I need to have variables that allow the other
file to set height and width parameters which is where I am getting
stuck.
What I am trying to achieve is a scrollable area within a web page that
can use a custom scroll bar.
So, can anyone give me any help on doing this with an IFrame, or some
other methods?
Regards,
Suneel.
| [aspngclient] member
Click here to reveal e-mail address
=3D YOUR ID
|
http://www.aspfriends.com/aspfriends/aspngclient.asp
=3D JOIN/QUIT
| [aspngclient] member
Click here to reveal e-mail address
=3D YOUR ID
|
http://www.aspfriends.com/aspfriends/aspngclient.asp
=3D JOIN/QUIT
Reply to this message...
Alex Dresko
I don't see why you need a new user control to perform that operation.
You're not really adding enough (or any) new functionality to the IFRAME
tag to warrant creating a new control I don't think. Or maybe I don't
understand what it is that yo'ure trying to do.
Alex Dresko
Three Point Oh!
-----Original Message-----
From: Suneel Jhangiani [mailto:
Click here to reveal e-mail address
]
Sent: Wednesday, July 10, 2002 11:55 AM
To: aspngclient
Subject: [aspngclient] RE: User Control Question
Well, that's the tricky part, as the output should be as below, but
should be brought into the main page via an IFRAME tag.
Main Page
---------
<HTML>
<HEAD>
<TITLE>news</TITLE>
<META http-equiv="Content-Type" content="text/html;
charset=windows-1252">
</HEAD>
<BODY bgColor="#003366">
<form name="Form1" method="post" action="t.aspx"
id="Form1">
{Other Content}
<IFRAME name="News" src=" IFRAME Content Page " frameBorder="0"
width="322" height="115">
{Other Content}
</form>
</BODY>
</HTML>
IFRAME Content Page
-------------------
<HTML>
<HEAD>
<TITLE>news</TITLE>
<META http-equiv="Content-Type" content="text/html;
charset=windows-1252">
<script language="JavaScript"
src="/Layout/Controls/Scrollbar/Scrollbar.js"></script>
<LINK href="/Layout/StyleSheets/stylesheet.css"
type="text/css" rel="stylesheet">
<STYLE type="text/css">
#content {POSITION: absolute}
BODY {MARGIN: 0px; OVERFLOW: hidden; WIDTH:
100%; HEIGHT: 100%}
</STYLE>
<script language="javascript">
<!-- // Variables for scroller
var upH = 18; // Height of up-arrow
var upW = 12; // Width of up-arrow
var downH = 18; // Height of down-arrow
var downW = 12; // Width of down-arrow
var dragH = 26; // Height of Dragbar
var dragW = 17; // Width of Dragbar
var scrollH = 58; // Height of scrollbar
var speed = 4; // Scroll speed
//-->
</script>
</HEAD>
<BODY bgColor="#003366" leftMargin="0" topMargin="0"
onload="eventLoader();" marginheight="0" marginwidth="0">
<TABLE height="200" cellSpacing="0" cellPadding="0"
width="322" border="0">
<TBODY>
<TR>
<TD> </TD>
</TR>
</TBODY>
</TABLE>
<!-- div containing up-arrow | change: top + left -->
<SPAN id="up" style="Z-INDEX: 1; LEFT: 310px; WIDTH:
1px; POSITION: absolute; TOP: 8px; HEIGHT: 1px">
<IMG height="25"
src="/Layout/Controls/Scrollbar/scroll_up.gif" width="10" border="0">
</SPAN>
<!-- div containing down-arrow | change: top + left -->
<SPAN id="down" style="Z-INDEX: 2; LEFT: 310px; WIDTH:
1px; POSITION: absolute; TOP: 85px; HEIGHT: 1px">
<IMG height="25"
src="/Layout/Controls/Scrollbar/scroll_down.gif" width="10" border="0">
</SPAN>
<!-- div containing scrollbar | change: top + left +
width + height -->
<SPAN id="drag" style="Z-INDEX: 3; LEFT: 310px; WIDTH:
17px; POSITION: absolute; TOP: 27px; HEIGHT: 26px">
<IMG height="31"
src="/Layout/Controls/Scrollbar/scroll_bar.gif" width="10">
</SPAN>
<!-- div laying above scrollbar for netscape 6
protection | change: top + left + width + height -->
<SPAN id="ruler" style="Z-INDEX: 4; LEFT: 306px; WIDTH:
17px; POSITION: absolute; TOP: 27px; HEIGHT: 26px"></SPAN>
<!-- div containing content | change: top + left + width
+ height + clip -->
<SPAN id="contentClip" style="Z-INDEX: 5; LEFT: 6px;
VISIBILITY: visible; OVERFLOW: hidden; WIDTH: 300px; CLIP: rect(0px
320px 115px 0px); POSITION: absolute; TOP: 5px; HEIGHT: 110px">
<SPAN class="News">
<SPAN id="content" style="LEFT: 0px;
WIDTH: 280px; TOP: 0px; HEIGHT: 110px">
<P><IMG height="7"
src="/Layout/Controls/Scrollbar/header.gif" width="24"> Monday
06/05/2002</P>Sample
news item entry. This can be HTML based text and include all relevant
formatting commands. It can also include links and images, although care
should be given to image size.
<P><IMG height="7"
src="/Layout/Controls/Scrollbar/header.gif" width="24"> Sunday
05/05/2002<P>Sample news item entry. This can be HTML based text and
include all relevant formatting commands. It can also include links and
images, although care should be given to image size.
<P><IMG height="7"
src="/Layout/Controls/Scrollbar/header.gif" width="24"> Saturday
04/05/2002<P>Sample news item entry. This can be HTML based text and
include all relevant formatting commands. It can also include links and
images, although care should be given to image size.
</SPAN>
</SPAN>
</SPAN>
</P>
<P> </P>
</BODY>
</HTML>
-----Original Message-----
From: Alex Dresko [mailto:
Click here to reveal e-mail address
]
Sent: 10 July 2002 16:51
To: aspngclient
Subject: [aspngclient] RE: User Control Question
Can you give an example of what you want the end result to be in HTML?
Alex Dresko
Three Point Oh!
-----Original Message-----
From: Suneel Jhangiani [mailto:
Click here to reveal e-mail address
]
Sent: Wednesday, July 10, 2002 10:41 AM
To: aspngclient
Subject: [aspngclient] User Control Question
-- Moved from [aspngfreeforall] to [aspngclient] by Yannick Smits
<
Click here to reveal e-mail address
> --
I'm trying to create a user control that is in my opinion fairly
complex, and am not sure exactly how to go about it.
What I am trying to do is create an enhanced IFrame and embed all the
additional code within the user control. The idea is that someone could
drop the control into there ASPX page and it would render the relevant
code for the IFRAME tag. However, due to the fact that the IFrame loads
content from another file, I need to have variables that allow the other
file to set height and width parameters which is where I am getting
stuck.
What I am trying to achieve is a scrollable area within a web page that
can use a custom scroll bar.
So, can anyone give me any help on doing this with an IFrame, or some
other methods?
Regards,
Suneel.
| [aspngclient] member
Click here to reveal e-mail address
= YOUR ID
|
http://www.aspfriends.com/aspfriends/aspngclient.asp
= JOIN/QUIT
| [aspngclient] member
Click here to reveal e-mail address
= YOUR ID
|
http://www.aspfriends.com/aspfriends/aspngclient.asp
= JOIN/QUIT
| [aspngclient] member
Click here to reveal e-mail address
= YOUR ID
|
http://www.aspfriends.com/aspfriends/aspngclient.asp
= JOIN/QUIT
Reply to this message...
Ad
MBR BootFX
Best-of-breed application framework for .NET projects, developed by Matthew Baxter-Reynolds and MBR IT
Copyright © Matthew Baxter-Reynolds 2001-2008. '.NET 247 Software Development Services' is a trading style of MBR IT Solutions Ltd.
Contact Us
-
Terms of Use
-
Privacy Policy
-
www.dotnet247.com