/    Sign up×
Community /Pin to ProfileBookmark

asp list popup and return

hi ther all

i hav a asp list ,i wont to open the edit record file in popup windows
and when i click submit to return to windows list form and refresh it

the problem is that the edit asp file post the data to him self
and after all the data insert in to the database it response.redirect to asp list
file
i try this
in the list file

<form name=”popcal1″>
…. asp and html kod…..
<a href=”javascript:popcaltest1(‘tst’,’document.popcal1′,document.popcal1);”>Edit</a>

<script language=”javascript”>
function popcaltest1(vCaption, vField, vDate){
var nW = window.open(“”, “tst”, “resizable=no,scrollbars=no,width=500,height=520”);
nW.location.href = “incotermedit1.asp?key=<%=Server.URLEncode(rs(“id”)&””)%>&caption=” + escape(vCaption) + “&field=” + vField + “&date=” + vDate; nW = null;
}
</script>

it open the coreckt edit asp file
in the edit file i put this line

<% sField = “document.popcal1” %>
<html>
<script LANGUAGE=”JavaScript”><!–
function returndat(vDate, vField)
{eval(“window.opener.” + vField + “.value='” + vDate + “‘;”); self.close(); }
//–></script>

<body >

<form onsubmit=” returndat(”,'<%=sField%>’);” action=”incotermedit1.asp” method=”post”>

bat sum in this consept is not work…
is ther any way to solv this ??
tanks a lot
erez

to post a comment
JavaScript

2 Comments(s)

Copy linkTweet thisAlerts:
@bdetcheveryMar 20.2006 — I find it a little difficult to see what you are trying to do.

I think you have one form that displays data (unnamed file) and another form that allows the user to edit the data called incotermedit1.asp.

The incotermedit1.asp file should use various Request.Form("var") to get the variables you passed into it from the unamed file, lookup the data in the database and then return a form of data that displays the info and allows the user to save the changes.

I think that's what you are trying to do, but I'm confused about the need for javascript to do this. The only javascript you might need is the window.open line to open the incotermedit1.asp in a window without scrollbars and that is not resizable, after that I would think no other javascript would be needed.

Hope this helps,
Copy linkTweet thisAlerts:
@erez222authorMar 20.2006 — hi bdetchevery

u understand my bat i sed it again

the asp edit file save the data ,so i dont nide the java to save data

bat i do nide the java to focus back to the list form and do refresh to c the changes that the edit file save

and i remind u that the edit file opend in popup windows.

and i dont know how to focus back from the popup edit form to the

list form and refresh it

tanks for u'r time

erez
×

Success!

Help @erez222 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.17,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @nearjob,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...