473,289 Members | 1,961 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,289 software developers and data experts.

Intellisense not working as expected with PreviousPage and Page Class

Is there something extra I need to do to make intellisense work when
referencing a page class? Here is my working Page_Load from a aspx page.
sourcePage does not get it's members listed with intellisense. It acts like
it is not a class but compiles fine.

Thanks,

protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
if (Page.PreviousPage != null)
{
Default sourcePage = (Default)PreviousPage;
int selectedIndex = sourcePage.GetDropDownListUnitsSelectedIndex();
DropDownListUnits.SelectedIndex = selectedIndex;
}
}

}

Peter Kellner
http://peterkellner.net
May 15 '06 #1
2 1724
Add the directive:

<%@ PreviousPageType VirtualPath="~/FirstPage.aspx" %>

-Brock
http://staff.develop.com/ballen

Is there something extra I need to do to make intellisense work when
referencing a page class? Here is my working Page_Load from a aspx
page. sourcePage does not get it's members listed with intellisense.
It acts like it is not a class but compiles fine.

Thanks,

protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
if (Page.PreviousPage != null)
{
Default sourcePage = (Default)PreviousPage;
int selectedIndex = sourcePage.GetDropDownListUnitsSelectedIndex();
DropDownListUnits.SelectedIndex = selectedIndex;
}
}
}

Peter Kellner
http://peterkellner.net

May 15 '06 #2
Thanks, Just what I was looking for. -Peter

"Brock Allen" <ba****@NOSPAMdevelop.com> wrote in message
news:b8************************@msnews.microsoft.c om...
Add the directive:

<%@ PreviousPageType VirtualPath="~/FirstPage.aspx" %>

-Brock
http://staff.develop.com/ballen

Is there something extra I need to do to make intellisense work when
referencing a page class? Here is my working Page_Load from a aspx
page. sourcePage does not get it's members listed with intellisense.
It acts like it is not a class but compiles fine.

Thanks,

protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
if (Page.PreviousPage != null)
{
Default sourcePage = (Default)PreviousPage;
int selectedIndex = sourcePage.GetDropDownListUnitsSelectedIndex();
DropDownListUnits.SelectedIndex = selectedIndex;
}
}
}

Peter Kellner
http://peterkellner.net


May 15 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Christopher W. Douglas | last post by:
I'm working in VB.Net, using Visual Studio 2003. I have a project, let's call it Foo, that contains common methods, forms, and objects I use in other projects. It compiles as Foo.dll, which I...
3
by: GC | last post by:
I have a web app with an aspx page in namespace Abc.WebModules.Vendors.Web. I also have business classes that are in Abc.WebModules.Vendors.Business. I have always been able to, in the aspx class,...
9
by: Jim Starcher | last post by:
I cannot get the intellisense hints to work on my class constructors. Would you please tell me what I am doing wrong? public class MyObject { //Constructors /// <summary> /// Used to...
2
by: louise raisbeck | last post by:
Hi, I am using c#. i have my server code within script tags on my aspx page i am not using code behind. Do you not get intellisense when working like this? it would speed up my work considerably...
2
by: Don | last post by:
I'm having problems with intellisense, autocomplete, etc. suddenly not working in certain classes of a project I'm working on. All the options are set, and it all works fine for most classes, but...
4
by: Alan Silver | last post by:
Hello, I'm doing a cross page post, and want to pick up information from the previous page. The problem is that the previous page contains a user control that is loaded into a Placeholder at run...
1
by: Jim McGivney | last post by:
I have been trying to get the values from a previous page on my target page. I have followed the help article:...
4
by: Bryce | last post by:
I have a search page that submits to a search results page. I have set the search results page to be authenticated, so when the user first tries to search, it redirects them to a login screen. When...
10
by: rjvrnjn | last post by:
I'm trying to pass a variable value from one page to another. Of all the ways that are available, I like the PreviousPage.FindControl() one as it lets me access the previous page controls and get the...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM). In this month's session, the creator of the excellent VBE...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: Aftab Ahmad | last post by:
Hello Experts! I have written a code in MS Access for a cmd called "WhatsApp Message" to open WhatsApp using that very code but the problem is that it gives a popup message everytime I clicked on...
0
by: Aftab Ahmad | last post by:
So, I have written a code for a cmd called "Send WhatsApp Message" to open and send WhatsApp messaage. The code is given below. Dim IE As Object Set IE =...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.