472,378 Members | 1,140 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

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

Is it possible to access another Page in code-behind

Dan
We have a simple site. It's a frameset with two frames a left and a right.
The left frame is essentially a list of records from a database (using a
server-side repeater control). When you click on one of the items in the
left frame, it targets the right frame and displays a form prefilled with
information for the item you clicked.

The problem is the left frame's list just shows the names of the items, and
the name of the item is editable in the right frame. So if I change the
name of the item in the right frame and save, I need it to automatically
update item's name in the left frame. How can I accomplish this?

Is there is a way to accomplish this through server side code?

Right now we're doing a clunky javascript solution which works, but I'm
hoping there is a better way. Basically in the save event for the right
frame (in the code-behind page), after the item is saved, we redirect to a
page that says "Your information has been saved" (or something to that
effect). On this page's body's onload event (in the <body> tag, i.e.
client-side) we are targetting the left frame to refresh with javascript.
It works, but like I said it seems clunky.

Is there anyway in the save event for the right frame (in the code-behind
page), to tell the left frame to refresh.

Thanks in advance,
Dan
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.547 / Virus Database: 340 - Release Date: 12/2/2003
Nov 18 '05 #1
5 2317
Dan,

I'm not sure why this seams clunky... that is the way I woud do it. No, you
cannot control a user's window refresh from the server - although you could
resend the entire frameset. Same result.

Regards,
Jason S.

"Dan" <dh******@somewhere.com> wrote in message
news:#b**************@TK2MSFTNGP12.phx.gbl...
We have a simple site. It's a frameset with two frames a left and a right. The left frame is essentially a list of records from a database (using a
server-side repeater control). When you click on one of the items in the
left frame, it targets the right frame and displays a form prefilled with
information for the item you clicked.

The problem is the left frame's list just shows the names of the items, and the name of the item is editable in the right frame. So if I change the
name of the item in the right frame and save, I need it to automatically
update item's name in the left frame. How can I accomplish this?

Is there is a way to accomplish this through server side code?

Right now we're doing a clunky javascript solution which works, but I'm
hoping there is a better way. Basically in the save event for the right
frame (in the code-behind page), after the item is saved, we redirect to a
page that says "Your information has been saved" (or something to that
effect). On this page's body's onload event (in the <body> tag, i.e.
client-side) we are targetting the left frame to refresh with javascript.
It works, but like I said it seems clunky.

Is there anyway in the save event for the right frame (in the code-behind
page), to tell the left frame to refresh.

Thanks in advance,
Dan
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.547 / Virus Database: 340 - Release Date: 12/2/2003

Nov 18 '05 #2
Dan
Thanks for the response.

The real reason for wanting a better solution is because our application is
actually a lot more complicated than I posted originally but the same
principle applies. In our project, the list in the left frame is actually a
treeview, and the goal is to update the treenode's text with the appropriate
changes, while at the same time keeping the treeview's state by remembering
what nodes are expanded.

It's basically like the windows explorer and how it deals with files and
folders.

If I simply refresh the left frame, the entire treeview must be reloaded
from scratch and no state is able to be kept (the user is forced to drill
down to get to where they were before).

I was hoping there was a way to simple reference the left frame's treeview
and change it from the code-behind page of the right frame. There are other
options that I've considered which require much more work, but I thought I'd
see if there was an easier way before I started coding with those.

Thanks,
Dan
"Jason S" <so*****@somewhere.com> wrote in message
news:e0**************@TK2MSFTNGP09.phx.gbl...
Dan,

I'm not sure why this seams clunky... that is the way I woud do it. No, you cannot control a user's window refresh from the server - although you could resend the entire frameset. Same result.

Regards,
Jason S.

"Dan" <dh******@somewhere.com> wrote in message
news:#b**************@TK2MSFTNGP12.phx.gbl...
We have a simple site. It's a frameset with two frames a left and a

right.
The left frame is essentially a list of records from a database (using a
server-side repeater control). When you click on one of the items in the left frame, it targets the right frame and displays a form prefilled with information for the item you clicked.

The problem is the left frame's list just shows the names of the items,

and
the name of the item is editable in the right frame. So if I change the
name of the item in the right frame and save, I need it to automatically
update item's name in the left frame. How can I accomplish this?

Is there is a way to accomplish this through server side code?

Right now we're doing a clunky javascript solution which works, but I'm
hoping there is a better way. Basically in the save event for the right
frame (in the code-behind page), after the item is saved, we redirect to a page that says "Your information has been saved" (or something to that
effect). On this page's body's onload event (in the <body> tag, i.e.
client-side) we are targetting the left frame to refresh with javascript. It works, but like I said it seems clunky.

Is there anyway in the save event for the right frame (in the code-behind page), to tell the left frame to refresh.

Thanks in advance,
Dan
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.547 / Virus Database: 340 - Release Date: 12/2/2003


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.547 / Virus Database: 340 - Release Date: 12/2/2003
Nov 18 '05 #3
Ah, see, you didn't represent the entire problem. If I were you I would
save the path in the viewstate so that if I had to refresh it I could come
back to that area for the user. A la MSDN library
(msdn.microsoft.com/library).

As far as accessing the page across the frame from another page on the
server I really don't see that. It's an interesting question from the
perspective of the container page though. I don't know if you could make
the framesets runat=server or not but that may be a way.

Regards,
Jason

"Dan" <dh******@somewhere.com> wrote in message
news:ey**************@TK2MSFTNGP10.phx.gbl...
Thanks for the response.

The real reason for wanting a better solution is because our application is actually a lot more complicated than I posted originally but the same
principle applies. In our project, the list in the left frame is actually a treeview, and the goal is to update the treenode's text with the appropriate changes, while at the same time keeping the treeview's state by remembering what nodes are expanded.

It's basically like the windows explorer and how it deals with files and
folders.

If I simply refresh the left frame, the entire treeview must be reloaded
from scratch and no state is able to be kept (the user is forced to drill
down to get to where they were before).

I was hoping there was a way to simple reference the left frame's treeview
and change it from the code-behind page of the right frame. There are other options that I've considered which require much more work, but I thought I'd see if there was an easier way before I started coding with those.

Thanks,
Dan
"Jason S" <so*****@somewhere.com> wrote in message
news:e0**************@TK2MSFTNGP09.phx.gbl...
Dan,

I'm not sure why this seams clunky... that is the way I woud do it. No, you
cannot control a user's window refresh from the server - although you

could
resend the entire frameset. Same result.

Regards,
Jason S.

"Dan" <dh******@somewhere.com> wrote in message
news:#b**************@TK2MSFTNGP12.phx.gbl...
We have a simple site. It's a frameset with two frames a left and a

right.
The left frame is essentially a list of records from a database (using a server-side repeater control). When you click on one of the items in the left frame, it targets the right frame and displays a form prefilled with information for the item you clicked.

The problem is the left frame's list just shows the names of the items,
and
the name of the item is editable in the right frame. So if I change
the name of the item in the right frame and save, I need it to automatically update item's name in the left frame. How can I accomplish this?

Is there is a way to accomplish this through server side code?

Right now we're doing a clunky javascript solution which works, but I'm hoping there is a better way. Basically in the save event for the right frame (in the code-behind page), after the item is saved, we redirect

to a page that says "Your information has been saved" (or something to that
effect). On this page's body's onload event (in the <body> tag, i.e.
client-side) we are targetting the left frame to refresh with javascript. It works, but like I said it seems clunky.

Is there anyway in the save event for the right frame (in the code-behind page), to tell the left frame to refresh.

Thanks in advance,
Dan
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.547 / Virus Database: 340 - Release Date: 12/2/2003


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.547 / Virus Database: 340 - Release Date: 12/2/2003

Nov 18 '05 #4
Dan
Thanks for the help.

I ended up having the right frame post, save, set a couple session
variables, and redirect to a page whose onload event submits the left frame.
The left frame then recursively loops through the treenodes until it finds
the one that has been edited (comparing its id with that of 1 of the session
variables), and changes its text to the new text (from the other session
variable). This way the tree keeps its state (remembering which branches
were expanded) and the text of the node changes appropriately. Still wish
there was a better way though.

Thanks,
Dan
"Jason S" <so*****@somewhere.com> wrote in message
news:ey**************@TK2MSFTNGP09.phx.gbl...
Ah, see, you didn't represent the entire problem. If I were you I would
save the path in the viewstate so that if I had to refresh it I could come
back to that area for the user. A la MSDN library
(msdn.microsoft.com/library).

As far as accessing the page across the frame from another page on the
server I really don't see that. It's an interesting question from the
perspective of the container page though. I don't know if you could make
the framesets runat=server or not but that may be a way.

Regards,
Jason

"Dan" <dh******@somewhere.com> wrote in message
news:ey**************@TK2MSFTNGP10.phx.gbl...
Thanks for the response.

The real reason for wanting a better solution is because our application is
actually a lot more complicated than I posted originally but the same
principle applies. In our project, the list in the left frame is actually a
treeview, and the goal is to update the treenode's text with the appropriate
changes, while at the same time keeping the treeview's state by

remembering
what nodes are expanded.

It's basically like the windows explorer and how it deals with files and
folders.

If I simply refresh the left frame, the entire treeview must be reloaded
from scratch and no state is able to be kept (the user is forced to drill down to get to where they were before).

I was hoping there was a way to simple reference the left frame's treeview and change it from the code-behind page of the right frame. There are

other
options that I've considered which require much more work, but I thought

I'd
see if there was an easier way before I started coding with those.

Thanks,
Dan
"Jason S" <so*****@somewhere.com> wrote in message
news:e0**************@TK2MSFTNGP09.phx.gbl...
Dan,

I'm not sure why this seams clunky... that is the way I woud do it. No,
you
cannot control a user's window refresh from the server - although you

could
resend the entire frameset. Same result.

Regards,
Jason S.

"Dan" <dh******@somewhere.com> wrote in message
news:#b**************@TK2MSFTNGP12.phx.gbl...
> We have a simple site. It's a frameset with two frames a left and a
right.
> The left frame is essentially a list of records from a database
(using a > server-side repeater control). When you click on one of the items
in the
> left frame, it targets the right frame and displays a form prefilled with
> information for the item you clicked.
>
> The problem is the left frame's list just shows the names of the

items, and
> the name of the item is editable in the right frame. So if I change the > name of the item in the right frame and save, I need it to automatically > update item's name in the left frame. How can I accomplish this?
>
> Is there is a way to accomplish this through server side code?
>
> Right now we're doing a clunky javascript solution which works, but I'm > hoping there is a better way. Basically in the save event for the right > frame (in the code-behind page), after the item is saved, we

redirect to
a
> page that says "Your information has been saved" (or something to

that > effect). On this page's body's onload event (in the <body> tag, i.e. > client-side) we are targetting the left frame to refresh with

javascript.
> It works, but like I said it seems clunky.
>
> Is there anyway in the save event for the right frame (in the

code-behind
> page), to tell the left frame to refresh.
>
> Thanks in advance,
> Dan
>
>
> ---
> Outgoing mail is certified Virus Free.
> Checked by AVG anti-virus system (http://www.grisoft.com).
> Version: 6.0.547 / Virus Database: 340 - Release Date: 12/2/2003
>
>

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.547 / Virus Database: 340 - Release Date: 12/2/2003


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.548 / Virus Database: 341 - Release Date: 12/5/2003
Nov 18 '05 #5
Hmm, too bad you can't just save the id of the last leaf that was opened and
then call something like tree.navigateto(leafID) and let the control sort it
out.

Jason S.

"Dan" <dh******@somewhere.com> wrote in message
news:e8**************@TK2MSFTNGP09.phx.gbl...
Thanks for the help.

I ended up having the right frame post, save, set a couple session
variables, and redirect to a page whose onload event submits the left frame. The left frame then recursively loops through the treenodes until it finds
the one that has been edited (comparing its id with that of 1 of the session variables), and changes its text to the new text (from the other session
variable). This way the tree keeps its state (remembering which branches
were expanded) and the text of the node changes appropriately. Still wish
there was a better way though.

Thanks,
Dan
"Jason S" <so*****@somewhere.com> wrote in message
news:ey**************@TK2MSFTNGP09.phx.gbl...
Ah, see, you didn't represent the entire problem. If I were you I would
save the path in the viewstate so that if I had to refresh it I could come
back to that area for the user. A la MSDN library
(msdn.microsoft.com/library).

As far as accessing the page across the frame from another page on the
server I really don't see that. It's an interesting question from the
perspective of the container page though. I don't know if you could make the framesets runat=server or not but that may be a way.

Regards,
Jason

"Dan" <dh******@somewhere.com> wrote in message
news:ey**************@TK2MSFTNGP10.phx.gbl...
Thanks for the response.

The real reason for wanting a better solution is because our application
is
actually a lot more complicated than I posted originally but the same
principle applies. In our project, the list in the left frame is actually
a
treeview, and the goal is to update the treenode's text with the

appropriate
changes, while at the same time keeping the treeview's state by

remembering
what nodes are expanded.

It's basically like the windows explorer and how it deals with files

and folders.

If I simply refresh the left frame, the entire treeview must be reloaded from scratch and no state is able to be kept (the user is forced to

drill down to get to where they were before).

I was hoping there was a way to simple reference the left frame's treeview and change it from the code-behind page of the right frame. There are

other
options that I've considered which require much more work, but I thought I'd
see if there was an easier way before I started coding with those.

Thanks,
Dan
"Jason S" <so*****@somewhere.com> wrote in message
news:e0**************@TK2MSFTNGP09.phx.gbl...
> Dan,
>
> I'm not sure why this seams clunky... that is the way I woud do it. No, you
> cannot control a user's window refresh from the server - although
you could
> resend the entire frameset. Same result.
>
> Regards,
> Jason S.
>
> "Dan" <dh******@somewhere.com> wrote in message
> news:#b**************@TK2MSFTNGP12.phx.gbl...
> > We have a simple site. It's a frameset with two frames a left and a > right.
> > The left frame is essentially a list of records from a database (using
a
> > server-side repeater control). When you click on one of the items

in the
> > left frame, it targets the right frame and displays a form prefilled with
> > information for the item you clicked.
> >
> > The problem is the left frame's list just shows the names of the

items,
> and
> > the name of the item is editable in the right frame. So if I
change the
> > name of the item in the right frame and save, I need it to

automatically
> > update item's name in the left frame. How can I accomplish this?
> >
> > Is there is a way to accomplish this through server side code?
> >
> > Right now we're doing a clunky javascript solution which works,
but I'm
> > hoping there is a better way. Basically in the save event for the

right
> > frame (in the code-behind page), after the item is saved, we

redirect
to
a
> > page that says "Your information has been saved" (or something to

that > > effect). On this page's body's onload event (in the <body> tag, i.e. > > client-side) we are targetting the left frame to refresh with
javascript.
> > It works, but like I said it seems clunky.
> >
> > Is there anyway in the save event for the right frame (in the
code-behind
> > page), to tell the left frame to refresh.
> >
> > Thanks in advance,
> > Dan
> >
> >
> > ---
> > Outgoing mail is certified Virus Free.
> > Checked by AVG anti-virus system (http://www.grisoft.com).
> > Version: 6.0.547 / Virus Database: 340 - Release Date: 12/2/2003
> >
> >
>
>
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.547 / Virus Database: 340 - Release Date: 12/2/2003


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.548 / Virus Database: 341 - Release Date: 12/5/2003

Nov 18 '05 #6

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

Similar topics

7
by: jason | last post by:
Is there a way - possibly a disconnected rs? - to update the contents of an existing pulldown on a page without having to re-submit the page for the user to see the pulldown populated with an...
20
by: CHIN | last post by:
Hi all.. here s my problem ( maybe some of you saw me on other groups, but i cant find the solution !! ) I have to upload a file to an external site, so, i made a .vbs file , that logins to...
2
by: Dave Bootsma | last post by:
Is it possible to programatically save a certain image from a certain web page? I want to automatically get a specific graphic from a specific web page programatically so I can automate the...
0
by: Naresh1 | last post by:
What is WebLogic Admin Training? WebLogic Admin Training is a specialized program designed to equip individuals with the skills and knowledge required to effectively administer and manage Oracle...
0
by: antdb | last post by:
Ⅰ. Advantage of AntDB: hyper-convergence + streaming processing engine In the overall architecture, a new "hyper-convergence" concept was proposed, which integrated multiple engines and...
0
hi
by: WisdomUfot | last post by:
It's an interesting question you've got about how Gmail hides the HTTP referrer when a link in an email is clicked. While I don't have the specific technical details, Gmail likely implements measures...
0
Oralloy
by: Oralloy | last post by:
Hello Folks, I am trying to hook up a CPU which I designed using SystemC to I/O pins on an FPGA. My problem (spelled failure) is with the synthesis of my design into a bitstream, not the C++...
0
by: Carina712 | last post by:
Setting background colors for Excel documents can help to improve the visual appeal of the document and make it easier to read and understand. Background colors can be used to highlight important...
0
BLUEPANDA
by: BLUEPANDA | last post by:
At BluePanda Dev, we're passionate about building high-quality software and sharing our knowledge with the community. That's why we've created a SaaS starter kit that's not only easy to use but also...
1
by: ezappsrUS | last post by:
Hi, I wonder if someone knows where I am going wrong below. I have a continuous form and two labels where only one would be visible depending on the checkbox being checked or not. Below is the...
0
by: jack2019x | last post by:
hello, Is there code or static lib for hook swapchain present? I wanna hook dxgi swapchain present for dx11 and dx9.
0
DizelArs
by: DizelArs | last post by:
Hi all) Faced with a problem, element.click() event doesn't work in Safari browser. Tried various tricks like emulating touch event through a function: let clickEvent = new Event('click', {...

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.