Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Posting to a different page

Status
Not open for further replies.

ravula2000

IS-IT--Management
Mar 8, 2002
205
US
My page has a list of filenames in a listbox.
Clicking a 'Show' asp command button opens a grid with the selected file contents in the SAME PAGE.
But the design should be modified. I should have 2 frames. In one frame I need the list box with Command button.
Clicking the commnad button should open the grid in the other page.

Iam trying with this code

Frames.asp
<html>
<head><title>Frames</title>
</head>
<frameset id=&quot;fset_bnmx&quot; COLS=&quot;100%,*&quot; FRAMESPACING=&quot;1&quot; FRAMEBORDER=&quot;1&quot;>
<frame name=&quot;frmListFiles&quot; src=&quot;ListFiles.aspx&quot;>
<frame name=&quot;frmDataGrid&quot; src=&quot;frmdatagrid.aspx&quot; SCROLLING=&quot;auto&quot;>
</frameset>
</html>

ListFiles.aspx
Has the listbox with command button

Clicking the command button should open the grid in the frmdatagrid.aspx in the frame frmDataGrid
with the selected FILENAME from the listbox as a parameter

Can any body give me some solution.?

Please help. Thanks in advance.

Thanks
Srini
 
sounds to me like you need to be making your frameset page dynamically so that if there is a selection you can change the frameset itself. If this is not how you imagined it I think I have mis-understood you, could you re-explain?
 
No. I need to open show the file contents in a datagrid in a separate frame on selecting a file from the list.
I dont want to include/show the gird in the same page. The 2 pages should be independent, ie the context of the 1st page should not be disturbed by the other page.

In the frameset code that I wrote, first time when the frames are loaded, the grid frame doesnt appear and I can put a condition not to process/display any thing by using the filename selected=&quot;&quot;.
Once a file is selected the name should be passed to the grid frame and it should display the grid with contents.
I will provide a Cancel button on the grid and makes the grid frame invisible by using 1stgrid width=100%.

So when ever I need to see the grid i can use it with out disturbing the contents of my 1st frame.

Please let me know if you have any questions on my problem.

Thanks for your help
Srini

 
well what about using the querystring to define the file name? In that way you could use the method I said to build the frameset. Does this make sense?
 
I cant use querystring with the file name as their main functionality is - A filename is selected and a Import button will be pressed and that file contents will be exported to the database and the file has gone.
I wanted to add one more button for view the contents of the page before loading. THat one I want to show it in a grid in a diff page so that the contents of the main page doest disturb (view state)

Thanks for your cooperation that you are showing in my problem.

Srini
 
The trouble is that there are limited ways you can realistically do this. I think possibily the best way would be to upload the file to a directory via the filechooser page itself. Once you have done that you could, perhaps force a refresh of the second page via javascript. Then on the Page load area check for a files existance. This really is a difficult situation to be honest with you without going into advanced javascript. It would be much easier to use just one page with a datagrid that is originally hidden and then becomes visible. Maybe use user controls for the file chooser or the datagrid if you are worrying about re-usability.
What you are trying to do, sounds to me at least, very convoluted.
What is the application itself doing? maybe there is a better way round how you're trying to do things.
 
I did this with the panel controls by making them visible/invisible at runtime.
But still I want to try posting to the different frame. Let me learn..

Thanks for your help Rilez..

Srini
 
you cannot post to a different frame. You can post to a different page ie go to a different page after you have submitted but other than that it is impossible. You can change the make up of the frameset itself I suppose if it is built dymanically. What about using one page with a iframe in it?
Hope thats given you some ideas but I really think that there is a better way of doing it.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top