> > function OnComplete() > { > if ( confirm("Do you wish to complete this order?") ) > { > btnComplete_ServerClick() > } > } > > > > <<<<<<<<<<<<<<<<<, the end > > > > now it's obvious this ain't gonna work, even with my wishful thinking, > because there's no object btnComplete_ServerClick when the script[/quote] function[quote] > is called... > > so how do you do it?!?!? > > thanks. > Dan. > >[/quote] [allowsmilie] => 1 [showsignature] => 0 [ipaddress] => [iconid] => 0 [visible] => 1 [attach] => 0 [infraction] => 0 [reportthreadid] => 0 [isusenetpost] => 1 [msgid] => <#wpCmLrUDHA.2040@TK2MSFTNGP11.phx.gbl> [ref] => [htmlstate] => on_nl2br [postusername] => S. Justin Gengo [ip] => sjgengo@aboutfo [isdeleted] => 0 [usergroupid] => [membergroupids] => [displaygroupid] => [password] => [passworddate] => [email] => [styleid] => [parentemail] => [homepage] => [icq] => [aim] => [yahoo] => [msn] => [skype] => [showvbcode] => [showbirthday] => [usertitle] => [customtitle] => [joindate] => [daysprune] => [lastvisit] => [lastactivity] => [lastpost] => [lastpostid] => [posts] => [reputation] => [reputationlevelid] => [timezoneoffset] => [pmpopup] => [avatarid] => [avatarrevision] => [profilepicrevision] => [sigpicrevision] => [options] => [akvbghsfs_optionsfield] => [birthday] => [birthday_search] => [maxposts] => [startofweek] => [referrerid] => [languageid] => [emailstamp] => [threadedmode] => [autosubscribe] => [pmtotal] => [pmunread] => [salt] => [ipoints] => [infractions] => [warnings] => [infractiongroupids] => [infractiongroupid] => [adminoptions] => [profilevisits] => [friendcount] => [friendreqcount] => [vmunreadcount] => [vmmoderatedcount] => [socgroupinvitecount] => [socgroupreqcount] => [pcunreadcount] => [pcmoderatedcount] => [gmmoderatedcount] => [assetposthash] => [fbuserid] => [fbjoindate] => [fbname] => [logintype] => [fbaccesstoken] => [newrepcount] => [vbseo_likes_in] => [vbseo_likes_out] => [vbseo_likes_unread] => [temp] => [field1] => [field2] => [field3] => [field4] => [field5] => [subfolders] => [pmfolders] => [buddylist] => [ignorelist] => [signature] => [searchprefs] => [rank] => [icontitle] => [iconpath] => [avatarpath] => [hascustomavatar] => 0 [avatardateline] => [avwidth] => [avheight] => [edit_userid] => [edit_username] => [edit_dateline] => [edit_reason] => [hashistory] => [pagetext_html] => [hasimages] => [signatureparsed] => [sighasimages] => [sigpic] => [sigpicdateline] => [sigpicwidth] => [sigpicheight] => [postcount] => 2 [islastshown] => [isfirstshown] => [attachments] => [allattachments] => ) --> > > > > function OnComplete() > > { > > if ( confirm("Do you wish to complete this order?") ) > > { > > btnComplete_ServerClick() > > } > > } > > > > > > > > <<<<<<<<<<<<<<<<<, the end > > > > > > > > now it's obvious this ain't gonna work, even with my wishful thinking, > > because there's no object btnComplete_ServerClick when the script[/quote] > function[quote] > > is called... > > > > so how do you do it?!?!? > > > > thanks. > > Dan. > > > >[/quote] > >[/quote] [allowsmilie] => 1 [showsignature] => 0 [ipaddress] => [iconid] => 0 [visible] => 1 [attach] => 0 [infraction] => 0 [reportthreadid] => 0 [isusenetpost] => 1 [msgid] => [ref] => <#wpCmLrUDHA.2040@TK2MSFTNGP11.phx.gbl> [htmlstate] => on_nl2br [postusername] => Daniel Bass [ip] => danielbassNOJUN [isdeleted] => 0 [usergroupid] => [membergroupids] => [displaygroupid] => [password] => [passworddate] => [email] => [styleid] => [parentemail] => [homepage] => [icq] => [aim] => [yahoo] => [msn] => [skype] => [showvbcode] => [showbirthday] => [usertitle] => [customtitle] => [joindate] => [daysprune] => [lastvisit] => [lastactivity] => [lastpost] => [lastpostid] => [posts] => [reputation] => [reputationlevelid] => [timezoneoffset] => [pmpopup] => [avatarid] => [avatarrevision] => [profilepicrevision] => [sigpicrevision] => [options] => [akvbghsfs_optionsfield] => [birthday] => [birthday_search] => [maxposts] => [startofweek] => [referrerid] => [languageid] => [emailstamp] => [threadedmode] => [autosubscribe] => [pmtotal] => [pmunread] => [salt] => [ipoints] => [infractions] => [warnings] => [infractiongroupids] => [infractiongroupid] => [adminoptions] => [profilevisits] => [friendcount] => [friendreqcount] => [vmunreadcount] => [vmmoderatedcount] => [socgroupinvitecount] => [socgroupreqcount] => [pcunreadcount] => [pcmoderatedcount] => [gmmoderatedcount] => [assetposthash] => [fbuserid] => [fbjoindate] => [fbname] => [logintype] => [fbaccesstoken] => [newrepcount] => [vbseo_likes_in] => [vbseo_likes_out] => [vbseo_likes_unread] => [temp] => [field1] => [field2] => [field3] => [field4] => [field5] => [subfolders] => [pmfolders] => [buddylist] => [ignorelist] => [signature] => [searchprefs] => [rank] => [icontitle] => [iconpath] => [avatarpath] => [hascustomavatar] => 0 [avatardateline] => [avwidth] => [avheight] => [edit_userid] => [edit_username] => [edit_dateline] => [edit_reason] => [hashistory] => [pagetext_html] => [hasimages] => [signatureparsed] => [sighasimages] => [sigpic] => [sigpicdateline] => [sigpicwidth] => [sigpicheight] => [postcount] => 3 [islastshown] => [isfirstshown] => [attachments] => [allattachments] => ) --> > > > > > > function OnComplete() > > > { > > > if ( confirm("Do you wish to complete this order?") ) > > > { > > > btnComplete_ServerClick() > > > } > > > } > > > > > > > > > > > > <<<<<<<<<<<<<<<<<, the end > > > > > > > > > > > > now it's obvious this ain't gonna work, even with my wishful thinking, > > > because there's no object btnComplete_ServerClick when the script[/quote] > > function[quote] > > > is called... > > > > > > so how do you do it?!?!? > > > > > > thanks. > > > Dan. > > > > > >[/quote] > > > >[/quote] > >[/quote] [allowsmilie] => 1 [showsignature] => 0 [ipaddress] => [iconid] => 0 [visible] => 1 [attach] => 0 [infraction] => 0 [reportthreadid] => 0 [isusenetpost] => 1 [msgid] => <#EiSajrUDHA.3312@tk2msftngp13.phx.gbl> [ref] => <#wpCmLrUDHA.2040@TK2MSFTNGP11.phx.gbl> [htmlstate] => on_nl2br [postusername] => S. Justin Gengo [ip] => sjgengo@aboutfo [isdeleted] => 0 [usergroupid] => [membergroupids] => [displaygroupid] => [password] => [passworddate] => [email] => [styleid] => [parentemail] => [homepage] => [icq] => [aim] => [yahoo] => [msn] => [skype] => [showvbcode] => [showbirthday] => [usertitle] => [customtitle] => [joindate] => [daysprune] => [lastvisit] => [lastactivity] => [lastpost] => [lastpostid] => [posts] => [reputation] => [reputationlevelid] => [timezoneoffset] => [pmpopup] => [avatarid] => [avatarrevision] => [profilepicrevision] => [sigpicrevision] => [options] => [akvbghsfs_optionsfield] => [birthday] => [birthday_search] => [maxposts] => [startofweek] => [referrerid] => [languageid] => [emailstamp] => [threadedmode] => [autosubscribe] => [pmtotal] => [pmunread] => [salt] => [ipoints] => [infractions] => [warnings] => [infractiongroupids] => [infractiongroupid] => [adminoptions] => [profilevisits] => [friendcount] => [friendreqcount] => [vmunreadcount] => [vmmoderatedcount] => [socgroupinvitecount] => [socgroupreqcount] => [pcunreadcount] => [pcmoderatedcount] => [gmmoderatedcount] => [assetposthash] => [fbuserid] => [fbjoindate] => [fbname] => [logintype] => [fbaccesstoken] => [newrepcount] => [vbseo_likes_in] => [vbseo_likes_out] => [vbseo_likes_unread] => [temp] => [field1] => [field2] => [field3] => [field4] => [field5] => [subfolders] => [pmfolders] => [buddylist] => [ignorelist] => [signature] => [searchprefs] => [rank] => [icontitle] => [iconpath] => [avatarpath] => [hascustomavatar] => 0 [avatardateline] => [avwidth] => [avheight] => [edit_userid] => [edit_username] => [edit_dateline] => [edit_reason] => [hashistory] => [pagetext_html] => [hasimages] => [signatureparsed] => [sighasimages] => [sigpic] => [sigpicdateline] => [sigpicwidth] => [sigpicheight] => [postcount] => 4 [islastshown] => [isfirstshown] => [attachments] => [allattachments] => ) --> > > > > > > > > > > function OnComplete() > > > > > { > > > > > if ( confirm("Do you wish to complete this order?") ) > > > > > { > > > > > btnComplete_ServerClick() > > > > > } > > > > > } > > > > > > > > > > > > > > > > > > > > <<<<<<<<<<<<<<<<<, the end > > > > > > > > > > > > > > > > > > > > now it's obvious this ain't gonna work, even with my wishful[/quote][/quote] > thinking,[quote][quote] > > > > > because there's no object btnComplete_ServerClick when the script > > > > function > > > > > is called... > > > > > > > > > > so how do you do it?!?!? > > > > > > > > > > thanks. > > > > > Dan. > > > > > > > > > > > > > > > > > > > > > > > >[/quote] > > > >[/quote] > >[/quote] [allowsmilie] => 1 [showsignature] => 0 [ipaddress] => [iconid] => 0 [visible] => 1 [attach] => 0 [infraction] => 0 [reportthreadid] => 0 [isusenetpost] => 1 [msgid] => [ref] => <#wpCmLrUDHA.2040@TK2MSFTNGP11.phx.gbl> <#EiSajrUDHA.3312@tk2msftngp13.phx.gbl> [htmlstate] => on_nl2br [postusername] => S. Justin Gengo [ip] => sjgengo@aboutfo [isdeleted] => 0 [usergroupid] => [membergroupids] => [displaygroupid] => [password] => [passworddate] => [email] => [styleid] => [parentemail] => [homepage] => [icq] => [aim] => [yahoo] => [msn] => [skype] => [showvbcode] => [showbirthday] => [usertitle] => [customtitle] => [joindate] => [daysprune] => [lastvisit] => [lastactivity] => [lastpost] => [lastpostid] => [posts] => [reputation] => [reputationlevelid] => [timezoneoffset] => [pmpopup] => [avatarid] => [avatarrevision] => [profilepicrevision] => [sigpicrevision] => [options] => [akvbghsfs_optionsfield] => [birthday] => [birthday_search] => [maxposts] => [startofweek] => [referrerid] => [languageid] => [emailstamp] => [threadedmode] => [autosubscribe] => [pmtotal] => [pmunread] => [salt] => [ipoints] => [infractions] => [warnings] => [infractiongroupids] => [infractiongroupid] => [adminoptions] => [profilevisits] => [friendcount] => [friendreqcount] => [vmunreadcount] => [vmmoderatedcount] => [socgroupinvitecount] => [socgroupreqcount] => [pcunreadcount] => [pcmoderatedcount] => [gmmoderatedcount] => [assetposthash] => [fbuserid] => [fbjoindate] => [fbname] => [logintype] => [fbaccesstoken] => [newrepcount] => [vbseo_likes_in] => [vbseo_likes_out] => [vbseo_likes_unread] => [temp] => [field1] => [field2] => [field3] => [field4] => [field5] => [subfolders] => [pmfolders] => [buddylist] => [ignorelist] => [signature] => [searchprefs] => [rank] => [icontitle] => [iconpath] => [avatarpath] => [hascustomavatar] => 0 [avatardateline] => [avwidth] => [avheight] => [edit_userid] => [edit_username] => [edit_dateline] => [edit_reason] => [hashistory] => [pagetext_html] => [hasimages] => [signatureparsed] => [sighasimages] => [sigpic] => [sigpicdateline] => [sigpicwidth] => [sigpicheight] => [postcount] => 5 [islastshown] => [isfirstshown] => [attachments] => [allattachments] => ) --> > > > > > > > > > > > > function OnComplete() > > > > > > { > > > > > > if ( confirm("Do you wish to complete this order?") ) > > > > > > { > > > > > > btnComplete_ServerClick() > > > > > > } > > > > > > } > > > > > > > > > > > > > > > > > > > > > > > > <<<<<<<<<<<<<<<<<, the end > > > > > > > > > > > > > > > > > > > > > > > > now it's obvious this ain't gonna work, even with my wishful[/quote] > > thinking,[quote] > > > > > > because there's no object btnComplete_ServerClick when the[/quote][/quote][/quote] script[quote][quote][quote] > > > > > function > > > > > > is called... > > > > > > > > > > > > so how do you do it?!?!? > > > > > > > > > > > > thanks. > > > > > > Dan. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >[/quote] > > > >[/quote] > >[/quote] [allowsmilie] => 1 [showsignature] => 0 [ipaddress] => [iconid] => 0 [visible] => 1 [attach] => 0 [infraction] => 0 [reportthreadid] => 0 [isusenetpost] => 1 [msgid] => [ref] => <#wpCmLrUDHA.2040@TK2MSFTNGP11.phx.gbl> <#EiSajrUDHA.3312@tk2msftngp13.phx.gbl> [htmlstate] => on_nl2br [postusername] => Daniel Bass [ip] => danielbassNOJUN [isdeleted] => 0 [usergroupid] => [membergroupids] => [displaygroupid] => [password] => [passworddate] => [email] => [styleid] => [parentemail] => [homepage] => [icq] => [aim] => [yahoo] => [msn] => [skype] => [showvbcode] => [showbirthday] => [usertitle] => [customtitle] => [joindate] => [daysprune] => [lastvisit] => [lastactivity] => [lastpost] => [lastpostid] => [posts] => [reputation] => [reputationlevelid] => [timezoneoffset] => [pmpopup] => [avatarid] => [avatarrevision] => [profilepicrevision] => [sigpicrevision] => [options] => [akvbghsfs_optionsfield] => [birthday] => [birthday_search] => [maxposts] => [startofweek] => [referrerid] => [languageid] => [emailstamp] => [threadedmode] => [autosubscribe] => [pmtotal] => [pmunread] => [salt] => [ipoints] => [infractions] => [warnings] => [infractiongroupids] => [infractiongroupid] => [adminoptions] => [profilevisits] => [friendcount] => [friendreqcount] => [vmunreadcount] => [vmmoderatedcount] => [socgroupinvitecount] => [socgroupreqcount] => [pcunreadcount] => [pcmoderatedcount] => [gmmoderatedcount] => [assetposthash] => [fbuserid] => [fbjoindate] => [fbname] => [logintype] => [fbaccesstoken] => [newrepcount] => [vbseo_likes_in] => [vbseo_likes_out] => [vbseo_likes_unread] => [temp] => [field1] => [field2] => [field3] => [field4] => [field5] => [subfolders] => [pmfolders] => [buddylist] => [ignorelist] => [signature] => [searchprefs] => [rank] => [icontitle] => [iconpath] => [avatarpath] => [hascustomavatar] => 0 [avatardateline] => [avwidth] => [avheight] => [edit_userid] => [edit_username] => [edit_dateline] => [edit_reason] => [hashistory] => [pagetext_html] => [hasimages] => [signatureparsed] => [sighasimages] => [sigpic] => [sigpicdateline] => [sigpicwidth] => [sigpicheight] => [postcount] => 6 [islastshown] => [isfirstshown] => [attachments] => [allattachments] => ) --> > > > > > > > > function OnComplete() > > > > { > > > > if ( confirm("Do you wish to complete this order?") ) > > > > { > > > > btnComplete_ServerClick() > > > > } > > > > } > > > > > > > > > > > > > > > > <<<<<<<<<<<<<<<<<, the end > > > > > > > > > > > > > > > > now it's obvious this ain't gonna work, even with my wishful[/quote][/quote][/quote] thinking,[quote][quote][quote] > > > > because there's no object btnComplete_ServerClick when the script > > > function > > > > is called... > > > > > > > > so how do you do it?!?!? > > > > > > > > thanks. > > > > Dan. > > > > > > > > > > > > > >[/quote] > > > >[/quote] > >[/quote] [allowsmilie] => 1 [showsignature] => 0 [ipaddress] => [iconid] => 0 [visible] => 1 [attach] => 0 [infraction] => 0 [reportthreadid] => 0 [isusenetpost] => 1 [msgid] => [ref] => <#wpCmLrUDHA.2040@TK2MSFTNGP11.phx.gbl> <#EiSajrUDHA.3312@tk2msftngp13.phx.gbl> [htmlstate] => on_nl2br [postusername] => Daniel Bass [ip] => danielbassNOJUN [isdeleted] => 0 [usergroupid] => [membergroupids] => [displaygroupid] => [password] => [passworddate] => [email] => [styleid] => [parentemail] => [homepage] => [icq] => [aim] => [yahoo] => [msn] => [skype] => [showvbcode] => [showbirthday] => [usertitle] => [customtitle] => [joindate] => [daysprune] => [lastvisit] => [lastactivity] => [lastpost] => [lastpostid] => [posts] => [reputation] => [reputationlevelid] => [timezoneoffset] => [pmpopup] => [avatarid] => [avatarrevision] => [profilepicrevision] => [sigpicrevision] => [options] => [akvbghsfs_optionsfield] => [birthday] => [birthday_search] => [maxposts] => [startofweek] => [referrerid] => [languageid] => [emailstamp] => [threadedmode] => [autosubscribe] => [pmtotal] => [pmunread] => [salt] => [ipoints] => [infractions] => [warnings] => [infractiongroupids] => [infractiongroupid] => [adminoptions] => [profilevisits] => [friendcount] => [friendreqcount] => [vmunreadcount] => [vmmoderatedcount] => [socgroupinvitecount] => [socgroupreqcount] => [pcunreadcount] => [pcmoderatedcount] => [gmmoderatedcount] => [assetposthash] => [fbuserid] => [fbjoindate] => [fbname] => [logintype] => [fbaccesstoken] => [newrepcount] => [vbseo_likes_in] => [vbseo_likes_out] => [vbseo_likes_unread] => [temp] => [field1] => [field2] => [field3] => [field4] => [field5] => [subfolders] => [pmfolders] => [buddylist] => [ignorelist] => [signature] => [searchprefs] => [rank] => [icontitle] => [iconpath] => [avatarpath] => [hascustomavatar] => 0 [avatardateline] => [avwidth] => [avheight] => [edit_userid] => [edit_username] => [edit_dateline] => [edit_reason] => [hashistory] => [pagetext_html] => [hasimages] => [signatureparsed] => [sighasimages] => [sigpic] => [sigpicdateline] => [sigpicwidth] => [sigpicheight] => [postcount] => 7 [islastshown] => [isfirstshown] => [attachments] => [allattachments] => ) --> > > > > > > > > > > function OnComplete() > > > > > { > > > > > if ( confirm("Do you wish to complete this order?") ) > > > > > { > > > > > btnComplete_ServerClick() > > > > > } > > > > > } > > > > > > > > > > > > > > > > > > > > <<<<<<<<<<<<<<<<<, the end > > > > > > > > > > > > > > > > > > > > now it's obvious this ain't gonna work, even with my wishful[/quote][/quote] > thinking,[quote][quote] > > > > > because there's no object btnComplete_ServerClick when the script > > > > function > > > > > is called... > > > > > > > > > > so how do you do it?!?!? > > > > > > > > > > thanks. > > > > > Dan. > > > > > > > > > > > > > > > > > > > > > > > >[/quote] > > > >[/quote] > >[/quote] [allowsmilie] => 1 [showsignature] => 0 [ipaddress] => [iconid] => 0 [visible] => 1 [attach] => 0 [infraction] => 0 [reportthreadid] => 0 [isusenetpost] => 1 [msgid] => [ref] => <#wpCmLrUDHA.2040@TK2MSFTNGP11.phx.gbl> <#EiSajrUDHA.3312@tk2msftngp13.phx.gbl> [htmlstate] => on_nl2br [postusername] => S. Justin Gengo [ip] => sjgengo@aboutfo [isdeleted] => 0 [usergroupid] => [membergroupids] => [displaygroupid] => [password] => [passworddate] => [email] => [styleid] => [parentemail] => [homepage] => [icq] => [aim] => [yahoo] => [msn] => [skype] => [showvbcode] => [showbirthday] => [usertitle] => [customtitle] => [joindate] => [daysprune] => [lastvisit] => [lastactivity] => [lastpost] => [lastpostid] => [posts] => [reputation] => [reputationlevelid] => [timezoneoffset] => [pmpopup] => [avatarid] => [avatarrevision] => [profilepicrevision] => [sigpicrevision] => [options] => [akvbghsfs_optionsfield] => [birthday] => [birthday_search] => [maxposts] => [startofweek] => [referrerid] => [languageid] => [emailstamp] => [threadedmode] => [autosubscribe] => [pmtotal] => [pmunread] => [salt] => [ipoints] => [infractions] => [warnings] => [infractiongroupids] => [infractiongroupid] => [adminoptions] => [profilevisits] => [friendcount] => [friendreqcount] => [vmunreadcount] => [vmmoderatedcount] => [socgroupinvitecount] => [socgroupreqcount] => [pcunreadcount] => [pcmoderatedcount] => [gmmoderatedcount] => [assetposthash] => [fbuserid] => [fbjoindate] => [fbname] => [logintype] => [fbaccesstoken] => [newrepcount] => [vbseo_likes_in] => [vbseo_likes_out] => [vbseo_likes_unread] => [temp] => [field1] => [field2] => [field3] => [field4] => [field5] => [subfolders] => [pmfolders] => [buddylist] => [ignorelist] => [signature] => [searchprefs] => [rank] => [icontitle] => [iconpath] => [avatarpath] => [hascustomavatar] => 0 [avatardateline] => [avwidth] => [avheight] => [edit_userid] => [edit_username] => [edit_dateline] => [edit_reason] => [hashistory] => [pagetext_html] => [hasimages] => [signatureparsed] => [sighasimages] => [sigpic] => [sigpicdateline] => [sigpicwidth] => [sigpicheight] => [postcount] => 8 [islastshown] => [isfirstshown] => [attachments] => [allattachments] => ) --> > > > > > > > > > > > > > > > > function OnComplete() > > > > > > > > { > > > > > > > > if ( confirm("Do you wish to complete this[/quote][/quote][/quote] order?") )[quote][quote][quote] > > > > > > > > { > > > > > > > > btnComplete_ServerClick() > > > > > > > > } > > > > > > > > } > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > <<<<<<<<<<<<<<<<<, the end > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > now it's obvious this ain't gonna work, even with my wishful > > > > thinking, > > > > > > > > because there's no object btnComplete_ServerClick when the[/quote] > > script[quote] > > > > > > > function > > > > > > > > is called... > > > > > > > > > > > > > > > > so how do you do it?!?!? > > > > > > > > > > > > > > > > thanks. > > > > > > > > Dan. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >[/quote] > > > >[/quote] > >[/quote] [allowsmilie] => 1 [showsignature] => 0 [ipaddress] => [iconid] => 0 [visible] => 1 [attach] => 0 [infraction] => 0 [reportthreadid] => 0 [isusenetpost] => 1 [msgid] => [ref] => <#wpCmLrUDHA.2040@TK2MSFTNGP11.phx.gbl> <#EiSajrUDHA.3312@tk2msftngp13.phx.gbl> [htmlstate] => on_nl2br [postusername] => Daniel Bass [ip] => danielbassNOJUN [isdeleted] => 0 [usergroupid] => [membergroupids] => [displaygroupid] => [password] => [passworddate] => [email] => [styleid] => [parentemail] => [homepage] => [icq] => [aim] => [yahoo] => [msn] => [skype] => [showvbcode] => [showbirthday] => [usertitle] => [customtitle] => [joindate] => [daysprune] => [lastvisit] => [lastactivity] => [lastpost] => [lastpostid] => [posts] => [reputation] => [reputationlevelid] => [timezoneoffset] => [pmpopup] => [avatarid] => [avatarrevision] => [profilepicrevision] => [sigpicrevision] => [options] => [akvbghsfs_optionsfield] => [birthday] => [birthday_search] => [maxposts] => [startofweek] => [referrerid] => [languageid] => [emailstamp] => [threadedmode] => [autosubscribe] => [pmtotal] => [pmunread] => [salt] => [ipoints] => [infractions] => [warnings] => [infractiongroupids] => [infractiongroupid] => [adminoptions] => [profilevisits] => [friendcount] => [friendreqcount] => [vmunreadcount] => [vmmoderatedcount] => [socgroupinvitecount] => [socgroupreqcount] => [pcunreadcount] => [pcmoderatedcount] => [gmmoderatedcount] => [assetposthash] => [fbuserid] => [fbjoindate] => [fbname] => [logintype] => [fbaccesstoken] => [newrepcount] => [vbseo_likes_in] => [vbseo_likes_out] => [vbseo_likes_unread] => [temp] => [field1] => [field2] => [field3] => [field4] => [field5] => [subfolders] => [pmfolders] => [buddylist] => [ignorelist] => [signature] => [searchprefs] => [rank] => [icontitle] => [iconpath] => [avatarpath] => [hascustomavatar] => 0 [avatardateline] => [avwidth] => [avheight] => [edit_userid] => [edit_username] => [edit_dateline] => [edit_reason] => [hashistory] => [pagetext_html] => [hasimages] => [signatureparsed] => [sighasimages] => [sigpic] => [sigpicdateline] => [sigpicwidth] => [sigpicheight] => [postcount] => 9 [islastshown] => [isfirstshown] => [attachments] => [allattachments] => ) --> > > > > > > > > > > > > > > > > > > function OnComplete() > > > > > > > > > { > > > > > > > > > if ( confirm("Do you wish to complete this[/quote][/quote] > order?") )[quote][quote] > > > > > > > > > { > > > > > > > > > btnComplete_ServerClick() > > > > > > > > > } > > > > > > > > > } > > > > > > > > > > > > > > > > > > [quote][quote][quote] > > > > > > > > > > > > > > > > > > <<<<<<<<<<<<<<<<<, the end > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > now it's obvious this ain't gonna work, even with my[/quote][/quote][/quote] wishful[quote][quote][quote] > > > > > thinking, > > > > > > > > > because there's no object btnComplete_ServerClick when[/quote][/quote][/quote] the[quote][quote][quote] > > > script > > > > > > > > function > > > > > > > > > is called... > > > > > > > > > > > > > > > > > > so how do you do it?!?!? > > > > > > > > > > > > > > > > > > thanks. > > > > > > > > > Dan. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >[/quote] > > > >[/quote] > >[/quote] [allowsmilie] => 1 [showsignature] => 0 [ipaddress] => [iconid] => 0 [visible] => 1 [attach] => 0 [infraction] => 0 [reportthreadid] => 0 [isusenetpost] => 1 [msgid] => <#dqR9#RVDHA.2040@TK2MSFTNGP11.phx.gbl> [ref] => <#wpCmLrUDHA.2040@TK2MSFTNGP11.phx.gbl> <#EiSajrUDHA.3312@tk2msftngp13.phx.gbl> [htmlstate] => on_nl2br [postusername] => S. Justin Gengo [ip] => sjgengo@aboutfo [isdeleted] => 0 [usergroupid] => [membergroupids] => [displaygroupid] => [password] => [passworddate] => [email] => [styleid] => [parentemail] => [homepage] => [icq] => [aim] => [yahoo] => [msn] => [skype] => [showvbcode] => [showbirthday] => [usertitle] => [customtitle] => [joindate] => [daysprune] => [lastvisit] => [lastactivity] => [lastpost] => [lastpostid] => [posts] => [reputation] => [reputationlevelid] => [timezoneoffset] => [pmpopup] => [avatarid] => [avatarrevision] => [profilepicrevision] => [sigpicrevision] => [options] => [akvbghsfs_optionsfield] => [birthday] => [birthday_search] => [maxposts] => [startofweek] => [referrerid] => [languageid] => [emailstamp] => [threadedmode] => [autosubscribe] => [pmtotal] => [pmunread] => [salt] => [ipoints] => [infractions] => [warnings] => [infractiongroupids] => [infractiongroupid] => [adminoptions] => [profilevisits] => [friendcount] => [friendreqcount] => [vmunreadcount] => [vmmoderatedcount] => [socgroupinvitecount] => [socgroupreqcount] => [pcunreadcount] => [pcmoderatedcount] => [gmmoderatedcount] => [assetposthash] => [fbuserid] => [fbjoindate] => [fbname] => [logintype] => [fbaccesstoken] => [newrepcount] => [vbseo_likes_in] => [vbseo_likes_out] => [vbseo_likes_unread] => [temp] => [field1] => [field2] => [field3] => [field4] => [field5] => [subfolders] => [pmfolders] => [buddylist] => [ignorelist] => [signature] => [searchprefs] => [rank] => [icontitle] => [iconpath] => [avatarpath] => [hascustomavatar] => 0 [avatardateline] => [avwidth] => [avheight] => [edit_userid] => [edit_username] => [edit_dateline] => [edit_reason] => [hashistory] => [pagetext_html] => [hasimages] => [signatureparsed] => [sighasimages] => [sigpic] => [sigpicdateline] => [sigpicwidth] => [sigpicheight] => [postcount] => 10 [islastshown] => [isfirstshown] => [attachments] => [allattachments] => ) --> > > > > > > > > > > > > > > > > > > > > function OnComplete() > > > > > > > > > > { > > > > > > > > > > if ( confirm("Do you wish to complete this[/quote] > > order?") )[quote] > > > > > > > > > > { > > > > > > > > > > btnComplete_ServerClick() > > > > > > > > > > } > > > > > > > > > > } > > > > > > > > > > > > > > > > > > > > [quote][quote] > > > > > > > > > > > > > > > > > > > > <<<<<<<<<<<<<<<<<, the end > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > now it's obvious this ain't gonna work, even with my[/quote][/quote] > wishful[quote][quote] > > > > > > thinking, > > > > > > > > > > because there's no object btnComplete_ServerClick when[/quote][/quote] > the[quote][quote] > > > > script > > > > > > > > > function > > > > > > > > > > is called... > > > > > > > > > > > > > > > > > > > > so how do you do it?!?!? > > > > > > > > > > > > > > > > > > > > thanks. > > > > > > > > > > Dan. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >[/quote] > > > >[/quote] > >[/quote] [allowsmilie] => 1 [showsignature] => 0 [ipaddress] => [iconid] => 0 [visible] => 1 [attach] => 0 [infraction] => 0 [reportthreadid] => 0 [isusenetpost] => 1 [msgid] => <#jtJPHSVDHA.1832@TK2MSFTNGP09.phx.gbl> [ref] => <#wpCmLrUDHA.2040@TK2MSFTNGP11.phx.gbl> <#EiSajrUDHA.3312@tk2msftngp13.phx.gbl> <#dqR9#RVDHA.2040@TK2MSFTNGP11.phx.gbl> [htmlstate] => on_nl2br [postusername] => Daniel Bass [ip] => danielbassNOJUN [isdeleted] => 0 [usergroupid] => [membergroupids] => [displaygroupid] => [password] => [passworddate] => [email] => [styleid] => [parentemail] => [homepage] => [icq] => [aim] => [yahoo] => [msn] => [skype] => [showvbcode] => [showbirthday] => [usertitle] => [customtitle] => [joindate] => [daysprune] => [lastvisit] => [lastactivity] => [lastpost] => [lastpostid] => [posts] => [reputation] => [reputationlevelid] => [timezoneoffset] => [pmpopup] => [avatarid] => [avatarrevision] => [profilepicrevision] => [sigpicrevision] => [options] => [akvbghsfs_optionsfield] => [birthday] => [birthday_search] => [maxposts] => [startofweek] => [referrerid] => [languageid] => [emailstamp] => [threadedmode] => [autosubscribe] => [pmtotal] => [pmunread] => [salt] => [ipoints] => [infractions] => [warnings] => [infractiongroupids] => [infractiongroupid] => [adminoptions] => [profilevisits] => [friendcount] => [friendreqcount] => [vmunreadcount] => [vmmoderatedcount] => [socgroupinvitecount] => [socgroupreqcount] => [pcunreadcount] => [pcmoderatedcount] => [gmmoderatedcount] => [assetposthash] => [fbuserid] => [fbjoindate] => [fbname] => [logintype] => [fbaccesstoken] => [newrepcount] => [vbseo_likes_in] => [vbseo_likes_out] => [vbseo_likes_unread] => [temp] => [field1] => [field2] => [field3] => [field4] => [field5] => [subfolders] => [pmfolders] => [buddylist] => [ignorelist] => [signature] => [searchprefs] => [rank] => [icontitle] => [iconpath] => [avatarpath] => [hascustomavatar] => 0 [avatardateline] => [avwidth] => [avheight] => [edit_userid] => [edit_username] => [edit_dateline] => [edit_reason] => [hashistory] => [pagetext_html] => [hasimages] => [signatureparsed] => [sighasimages] => [sigpic] => [sigpicdateline] => [sigpicwidth] => [sigpicheight] => [postcount] => 11 [islastshown] => 1 [isfirstshown] => [attachments] => [allattachments] => ) --> Server Side Confirmation pop-up... - ASP.NET

Server Side Confirmation pop-up... - ASP.NET

Hello, | function OnComplete() | { | if ( confirm("Do you wish to complete this order?") ) | { | btnComplete_ServerClick() | } | } You can't call server code from client code. The right way is to cancel form submitting at client. To cancel click, simply return false as value. Your function should be: function OnComplete(){ return confirm("Do you wish to complete this order?"); } -- Michal A. Valasek, Altair Communications, [url]http://www.altaircom.net[/url] Please do not reply to this e-mail, for contact see [url]http://www.rider.cz[/url]...

  1. #1

    Default Re: Server Side Confirmation pop-up...

    Hello,

    | function OnComplete()
    | {
    | if ( confirm("Do you wish to complete this order?") )
    | {
    | btnComplete_ServerClick()
    | }
    | }

    You can't call server code from client code. The right way is to cancel form
    submitting at client.

    To cancel click, simply return false as value. Your function should be:

    function OnComplete(){
    return confirm("Do you wish to complete this order?");
    }

    --
    Michal A. Valasek, Altair Communications, [url]http://www.altaircom.net[/url]
    Please do not reply to this e-mail, for contact see [url]http://www.rider.cz[/url]


    Michal A. Valasek Guest

  2. #2

    Default Re: Server Side Confirmation pop-up...

    Dan,

    You're just thinking about it too hard!

    Try this:

    WebControlButton.Attributes.Add("onClick", "javascript:if(!confirm('Do you
    wish to complete this order?')) return false;")

    Now if the confirmation goes through the WebControlButton's click event
    server side will be fired and your server side code can all go there.

    If the confirmation's cancel button is clicked note that the javascript
    function returns false. The form will not be posted back in that case.

    Is this what you want?


    --
    S. Justin Gengo, MCP
    Web Developer

    Free code library at:
    [url]www.aboutfortunate.com[/url]

    "Out of chaos comes order."
    Nietzche
    "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    news:urHxKGrUDHA.3972tk2msftngp13.phx.gbl...
    > I know I know, you can't have a server side pop up, even if you could it
    > would pop up on the servers monitor and not the client...
    >
    > but what i want to do is, when a button is clicked on a screen, launched
    the
    > confirm("...") message box, then call server side code on the code behind
    > page, depending on the result of the confirm box.
    >
    > I've got something like this at the moment:
    >
    > >>>> myPage.aspx.vb
    > ----------------------------
    > Public Class myClass
    > Inherits System.Web.UI.Page
    >
    > '...... other initialization stuff
    >
    > Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
    > System.EventArgs) Handles MyBase.Load
    > 'Put user code to initialize the page here
    >
    > If Not IsPostBack Then
    >
    > '.... someother code
    > btnRelease.Attributes.Add("onclick", "OnRelease();")
    >
    > End If
    >
    > End Sub
    >
    > Public Sub btnComplete_ServerClick()
    > ' ....my server side ADO.net code
    > End Sub
    >
    > '......... etc etc
    > End Class
    >
    >
    > >>>>> myPage.asp
    > -----------------------
    >
    > <!-- my head title tags and all that joy... -->
    >
    > function OnComplete()
    > {
    > if ( confirm("Do you wish to complete this order?") )
    > {
    > btnComplete_ServerClick()
    > }
    > }
    >
    > <!-- my body tags and rest of the code and all that joy -->
    >
    > <<<<<<<<<<<<<<<<<, the end
    >
    >
    >
    > now it's obvious this ain't gonna work, even with my wishful thinking,
    > because there's no object btnComplete_ServerClick when the script
    function
    > is called...
    >
    > so how do you do it?!?!?
    >
    > thanks.
    > Dan.
    >
    >

    S. Justin Gengo Guest

  3. #3

    Default Re: Server Side Confirmation pop-up...

    You can do that?? You da man!

    Only I'm getting and object doesn't exist error on this block in the HTML,
    the highlight in question sort of starts at the "a" in false and goes
    through to the "d" in __doPostBack... so I'm not sure which one it's
    complaining about.

    onclick="javascript:if(!confirm('Do you wish to complete this order?')) {
    return false; } __doPostBack('btnComplete','')"

    Thanks.

    Dan.



    "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    news:%23wpCmLrUDHA.2040TK2MSFTNGP11.phx.gbl...
    > Dan,
    >
    > You're just thinking about it too hard!
    >
    > Try this:
    >
    > WebControlButton.Attributes.Add("onClick", "javascript:if(!confirm('Do you
    > wish to complete this order?')) return false;")
    >
    > Now if the confirmation goes through the WebControlButton's click event
    > server side will be fired and your server side code can all go there.
    >
    > If the confirmation's cancel button is clicked note that the javascript
    > function returns false. The form will not be posted back in that case.
    >
    > Is this what you want?
    >
    >
    > --
    > S. Justin Gengo, MCP
    > Web Developer
    >
    > Free code library at:
    > [url]www.aboutfortunate.com[/url]
    >
    > "Out of chaos comes order."
    > Nietzche
    > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    > news:urHxKGrUDHA.3972tk2msftngp13.phx.gbl...
    > > I know I know, you can't have a server side pop up, even if you could it
    > > would pop up on the servers monitor and not the client...
    > >
    > > but what i want to do is, when a button is clicked on a screen, launched
    > the
    > > confirm("...") message box, then call server side code on the code
    behind
    > > page, depending on the result of the confirm box.
    > >
    > > I've got something like this at the moment:
    > >
    > > >>>> myPage.aspx.vb
    > > ----------------------------
    > > Public Class myClass
    > > Inherits System.Web.UI.Page
    > >
    > > '...... other initialization stuff
    > >
    > > Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
    > > System.EventArgs) Handles MyBase.Load
    > > 'Put user code to initialize the page here
    > >
    > > If Not IsPostBack Then
    > >
    > > '.... someother code
    > > btnRelease.Attributes.Add("onclick", "OnRelease();")
    > >
    > > End If
    > >
    > > End Sub
    > >
    > > Public Sub btnComplete_ServerClick()
    > > ' ....my server side ADO.net code
    > > End Sub
    > >
    > > '......... etc etc
    > > End Class
    > >
    > >
    > > >>>>> myPage.asp
    > > -----------------------
    > >
    > > <!-- my head title tags and all that joy... -->
    > >
    > > function OnComplete()
    > > {
    > > if ( confirm("Do you wish to complete this order?") )
    > > {
    > > btnComplete_ServerClick()
    > > }
    > > }
    > >
    > > <!-- my body tags and rest of the code and all that joy -->
    > >
    > > <<<<<<<<<<<<<<<<<, the end
    > >
    > >
    > >
    > > now it's obvious this ain't gonna work, even with my wishful thinking,
    > > because there's no object btnComplete_ServerClick when the script
    > function
    > > is called...
    > >
    > > so how do you do it?!?!?
    > >
    > > thanks.
    > > Dan.
    > >
    > >
    >
    >

    Daniel Bass Guest

  4. #4

    Default Re: Server Side Confirmation pop-up...

    Dan,

    Did you add the do post back stuff yourself?

    I run the code I gave you in my codebehind page's page load and it's
    produced in the html sent to the client like this:

    <input type="submit" name="Button1" value="Button" id="Button1"
    onClick="javascript:if(!confirm('Do you wish to complete this order?'))
    return false;" style="Z-INDEX: 101; LEFT: 8px; POSITION: absolute; TOP: 8px"
    />

    Where is the doPostBack routine of yours coming from?

    --
    S. Justin Gengo, MCP
    Web Developer

    Free code library at:
    [url]www.aboutfortunate.com[/url]

    "Out of chaos comes order."
    Nietzche
    "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    news:up8BTXrUDHA.2248TK2MSFTNGP10.phx.gbl...
    > You can do that?? You da man!
    >
    > Only I'm getting and object doesn't exist error on this block in the HTML,
    > the highlight in question sort of starts at the "a" in false and goes
    > through to the "d" in __doPostBack... so I'm not sure which one it's
    > complaining about.
    >
    > onclick="javascript:if(!confirm('Do you wish to complete this order?')) {
    > return false; } __doPostBack('btnComplete','')"
    >
    > Thanks.
    >
    > Dan.
    >
    >
    >
    > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    > news:%23wpCmLrUDHA.2040TK2MSFTNGP11.phx.gbl...
    > > Dan,
    > >
    > > You're just thinking about it too hard!
    > >
    > > Try this:
    > >
    > > WebControlButton.Attributes.Add("onClick", "javascript:if(!confirm('Do
    you
    > > wish to complete this order?')) return false;")
    > >
    > > Now if the confirmation goes through the WebControlButton's click event
    > > server side will be fired and your server side code can all go there.
    > >
    > > If the confirmation's cancel button is clicked note that the javascript
    > > function returns false. The form will not be posted back in that case.
    > >
    > > Is this what you want?
    > >
    > >
    > > --
    > > S. Justin Gengo, MCP
    > > Web Developer
    > >
    > > Free code library at:
    > > [url]www.aboutfortunate.com[/url]
    > >
    > > "Out of chaos comes order."
    > > Nietzche
    > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    > > news:urHxKGrUDHA.3972tk2msftngp13.phx.gbl...
    > > > I know I know, you can't have a server side pop up, even if you could
    it
    > > > would pop up on the servers monitor and not the client...
    > > >
    > > > but what i want to do is, when a button is clicked on a screen,
    launched
    > > the
    > > > confirm("...") message box, then call server side code on the code
    > behind
    > > > page, depending on the result of the confirm box.
    > > >
    > > > I've got something like this at the moment:
    > > >
    > > > >>>> myPage.aspx.vb
    > > > ----------------------------
    > > > Public Class myClass
    > > > Inherits System.Web.UI.Page
    > > >
    > > > '...... other initialization stuff
    > > >
    > > > Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
    > > > System.EventArgs) Handles MyBase.Load
    > > > 'Put user code to initialize the page here
    > > >
    > > > If Not IsPostBack Then
    > > >
    > > > '.... someother code
    > > > btnRelease.Attributes.Add("onclick", "OnRelease();")
    > > >
    > > > End If
    > > >
    > > > End Sub
    > > >
    > > > Public Sub btnComplete_ServerClick()
    > > > ' ....my server side ADO.net code
    > > > End Sub
    > > >
    > > > '......... etc etc
    > > > End Class
    > > >
    > > >
    > > > >>>>> myPage.asp
    > > > -----------------------
    > > >
    > > > <!-- my head title tags and all that joy... -->
    > > >
    > > > function OnComplete()
    > > > {
    > > > if ( confirm("Do you wish to complete this order?") )
    > > > {
    > > > btnComplete_ServerClick()
    > > > }
    > > > }
    > > >
    > > > <!-- my body tags and rest of the code and all that joy -->
    > > >
    > > > <<<<<<<<<<<<<<<<<, the end
    > > >
    > > >
    > > >
    > > > now it's obvious this ain't gonna work, even with my wishful thinking,
    > > > because there's no object btnComplete_ServerClick when the script
    > > function
    > > > is called...
    > > >
    > > > so how do you do it?!?!?
    > > >
    > > > thanks.
    > > > Dan.
    > > >
    > > >
    > >
    > >
    >
    >

    S. Justin Gengo Guest

  5. #5

    Default Re: Server Side Confirmation pop-up...

    As long as you're using a asp.net button then that button is associated with
    a server side event.

    It would look like this:

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
    System.EventArgs) Handles Button1.Click

    '---Put your code here

    End Sub


    --
    S. Justin Gengo, MCP
    Web Developer

    Free code library at:
    [url]www.aboutfortunate.com[/url]

    "Out of chaos comes order."
    Nietzche
    "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    news:eiF8iorUDHA.2204TK2MSFTNGP10.phx.gbl...
    > What do i do when the users clicked on OK?
    >
    > What I'd like to happen is for some server side code to run and process a
    > few bits...
    >
    > The code you gave me, I thought I'd be able to do this?
    >
    > my bad.
    >
    > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    > news:%23EiSajrUDHA.3312tk2msftngp13.phx.gbl...
    > > Dan,
    > >
    > > Did you add the do post back stuff yourself?
    > >
    > > I run the code I gave you in my codebehind page's page load and it's
    > > produced in the html sent to the client like this:
    > >
    > > <input type="submit" name="Button1" value="Button" id="Button1"
    > > onClick="javascript:if(!confirm('Do you wish to complete this order?'))
    > > return false;" style="Z-INDEX: 101; LEFT: 8px; POSITION: absolute; TOP:
    > 8px"
    > > />
    > >
    > > Where is the doPostBack routine of yours coming from?
    > >
    > > --
    > > S. Justin Gengo, MCP
    > > Web Developer
    > >
    > > Free code library at:
    > > [url]www.aboutfortunate.com[/url]
    > >
    > > "Out of chaos comes order."
    > > Nietzche
    > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    > > news:up8BTXrUDHA.2248TK2MSFTNGP10.phx.gbl...
    > > > You can do that?? You da man!
    > > >
    > > > Only I'm getting and object doesn't exist error on this block in the
    > HTML,
    > > > the highlight in question sort of starts at the "a" in false and goes
    > > > through to the "d" in __doPostBack... so I'm not sure which one it's
    > > > complaining about.
    > > >
    > > > onclick="javascript:if(!confirm('Do you wish to complete this
    order?'))
    > {
    > > > return false; } __doPostBack('btnComplete','')"
    > > >
    > > > Thanks.
    > > >
    > > > Dan.
    > > >
    > > >
    > > >
    > > > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    > > > news:%23wpCmLrUDHA.2040TK2MSFTNGP11.phx.gbl...
    > > > > Dan,
    > > > >
    > > > > You're just thinking about it too hard!
    > > > >
    > > > > Try this:
    > > > >
    > > > > WebControlButton.Attributes.Add("onClick",
    "javascript:if(!confirm('Do
    > > you
    > > > > wish to complete this order?')) return false;")
    > > > >
    > > > > Now if the confirmation goes through the WebControlButton's click
    > event
    > > > > server side will be fired and your server side code can all go
    there.
    > > > >
    > > > > If the confirmation's cancel button is clicked note that the
    > javascript
    > > > > function returns false. The form will not be posted back in that
    case.
    > > > >
    > > > > Is this what you want?
    > > > >
    > > > >
    > > > > --
    > > > > S. Justin Gengo, MCP
    > > > > Web Developer
    > > > >
    > > > > Free code library at:
    > > > > [url]www.aboutfortunate.com[/url]
    > > > >
    > > > > "Out of chaos comes order."
    > > > > Nietzche
    > > > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in
    message
    > > > > news:urHxKGrUDHA.3972tk2msftngp13.phx.gbl...
    > > > > > I know I know, you can't have a server side pop up, even if you
    > could
    > > it
    > > > > > would pop up on the servers monitor and not the client...
    > > > > >
    > > > > > but what i want to do is, when a button is clicked on a screen,
    > > launched
    > > > > the
    > > > > > confirm("...") message box, then call server side code on the code
    > > > behind
    > > > > > page, depending on the result of the confirm box.
    > > > > >
    > > > > > I've got something like this at the moment:
    > > > > >
    > > > > > >>>> myPage.aspx.vb
    > > > > > ----------------------------
    > > > > > Public Class myClass
    > > > > > Inherits System.Web.UI.Page
    > > > > >
    > > > > > '...... other initialization stuff
    > > > > >
    > > > > > Private Sub Page_Load(ByVal sender As System.Object, ByVal e
    As
    > > > > > System.EventArgs) Handles MyBase.Load
    > > > > > 'Put user code to initialize the page here
    > > > > >
    > > > > > If Not IsPostBack Then
    > > > > >
    > > > > > '.... someother code
    > > > > > btnRelease.Attributes.Add("onclick", "OnRelease();")
    > > > > >
    > > > > > End If
    > > > > >
    > > > > > End Sub
    > > > > >
    > > > > > Public Sub btnComplete_ServerClick()
    > > > > > ' ....my server side ADO.net code
    > > > > > End Sub
    > > > > >
    > > > > > '......... etc etc
    > > > > > End Class
    > > > > >
    > > > > >
    > > > > > >>>>> myPage.asp
    > > > > > -----------------------
    > > > > >
    > > > > > <!-- my head title tags and all that joy... -->
    > > > > >
    > > > > > function OnComplete()
    > > > > > {
    > > > > > if ( confirm("Do you wish to complete this order?") )
    > > > > > {
    > > > > > btnComplete_ServerClick()
    > > > > > }
    > > > > > }
    > > > > >
    > > > > > <!-- my body tags and rest of the code and all that joy -->
    > > > > >
    > > > > > <<<<<<<<<<<<<<<<<, the end
    > > > > >
    > > > > >
    > > > > >
    > > > > > now it's obvious this ain't gonna work, even with my wishful
    > thinking,
    > > > > > because there's no object btnComplete_ServerClick when the script
    > > > > function
    > > > > > is called...
    > > > > >
    > > > > > so how do you do it?!?!?
    > > > > >
    > > > > > thanks.
    > > > > > Dan.
    > > > > >
    > > > > >
    > > > >
    > > > >
    > > >
    > > >
    > >
    > >
    >
    >

    S. Justin Gengo Guest

  6. #6

    Default Re: Server Side Confirmation pop-up...

    I've got an confirmation box, which will have to be launched client side.
    I then need some server side code to be launched if there is a "yes" click
    on the confirmation screen...

    is this possible?

    you either have a server side event handler, or a onClick event handler in
    the client... this is what's causing me the problem.


    "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    news:eEdwWXvUDHA.1316TK2MSFTNGP12.phx.gbl...
    > As long as you're using a asp.net button then that button is associated
    with
    > a server side event.
    >
    > It would look like this:
    >
    > Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
    > System.EventArgs) Handles Button1.Click
    >
    > '---Put your code here
    >
    > End Sub
    >
    >
    > --
    > S. Justin Gengo, MCP
    > Web Developer
    >
    > Free code library at:
    > [url]www.aboutfortunate.com[/url]
    >
    > "Out of chaos comes order."
    > Nietzche
    > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    > news:eiF8iorUDHA.2204TK2MSFTNGP10.phx.gbl...
    > > What do i do when the users clicked on OK?
    > >
    > > What I'd like to happen is for some server side code to run and process
    a
    > > few bits...
    > >
    > > The code you gave me, I thought I'd be able to do this?
    > >
    > > my bad.
    > >
    > > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    > > news:%23EiSajrUDHA.3312tk2msftngp13.phx.gbl...
    > > > Dan,
    > > >
    > > > Did you add the do post back stuff yourself?
    > > >
    > > > I run the code I gave you in my codebehind page's page load and it's
    > > > produced in the html sent to the client like this:
    > > >
    > > > <input type="submit" name="Button1" value="Button" id="Button1"
    > > > onClick="javascript:if(!confirm('Do you wish to complete this
    order?'))
    > > > return false;" style="Z-INDEX: 101; LEFT: 8px; POSITION: absolute;
    TOP:
    > > 8px"
    > > > />
    > > >
    > > > Where is the doPostBack routine of yours coming from?
    > > >
    > > > --
    > > > S. Justin Gengo, MCP
    > > > Web Developer
    > > >
    > > > Free code library at:
    > > > [url]www.aboutfortunate.com[/url]
    > > >
    > > > "Out of chaos comes order."
    > > > Nietzche
    > > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    > > > news:up8BTXrUDHA.2248TK2MSFTNGP10.phx.gbl...
    > > > > You can do that?? You da man!
    > > > >
    > > > > Only I'm getting and object doesn't exist error on this block in the
    > > HTML,
    > > > > the highlight in question sort of starts at the "a" in false and
    goes
    > > > > through to the "d" in __doPostBack... so I'm not sure which one it's
    > > > > complaining about.
    > > > >
    > > > > onclick="javascript:if(!confirm('Do you wish to complete this
    > order?'))
    > > {
    > > > > return false; } __doPostBack('btnComplete','')"
    > > > >
    > > > > Thanks.
    > > > >
    > > > > Dan.
    > > > >
    > > > >
    > > > >
    > > > > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    > > > > news:%23wpCmLrUDHA.2040TK2MSFTNGP11.phx.gbl...
    > > > > > Dan,
    > > > > >
    > > > > > You're just thinking about it too hard!
    > > > > >
    > > > > > Try this:
    > > > > >
    > > > > > WebControlButton.Attributes.Add("onClick",
    > "javascript:if(!confirm('Do
    > > > you
    > > > > > wish to complete this order?')) return false;")
    > > > > >
    > > > > > Now if the confirmation goes through the WebControlButton's click
    > > event
    > > > > > server side will be fired and your server side code can all go
    > there.
    > > > > >
    > > > > > If the confirmation's cancel button is clicked note that the
    > > javascript
    > > > > > function returns false. The form will not be posted back in that
    > case.
    > > > > >
    > > > > > Is this what you want?
    > > > > >
    > > > > >
    > > > > > --
    > > > > > S. Justin Gengo, MCP
    > > > > > Web Developer
    > > > > >
    > > > > > Free code library at:
    > > > > > [url]www.aboutfortunate.com[/url]
    > > > > >
    > > > > > "Out of chaos comes order."
    > > > > > Nietzche
    > > > > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in
    > message
    > > > > > news:urHxKGrUDHA.3972tk2msftngp13.phx.gbl...
    > > > > > > I know I know, you can't have a server side pop up, even if you
    > > could
    > > > it
    > > > > > > would pop up on the servers monitor and not the client...
    > > > > > >
    > > > > > > but what i want to do is, when a button is clicked on a screen,
    > > > launched
    > > > > > the
    > > > > > > confirm("...") message box, then call server side code on the
    code
    > > > > behind
    > > > > > > page, depending on the result of the confirm box.
    > > > > > >
    > > > > > > I've got something like this at the moment:
    > > > > > >
    > > > > > > >>>> myPage.aspx.vb
    > > > > > > ----------------------------
    > > > > > > Public Class myClass
    > > > > > > Inherits System.Web.UI.Page
    > > > > > >
    > > > > > > '...... other initialization stuff
    > > > > > >
    > > > > > > Private Sub Page_Load(ByVal sender As System.Object, ByVal e
    > As
    > > > > > > System.EventArgs) Handles MyBase.Load
    > > > > > > 'Put user code to initialize the page here
    > > > > > >
    > > > > > > If Not IsPostBack Then
    > > > > > >
    > > > > > > '.... someother code
    > > > > > > btnRelease.Attributes.Add("onclick", "OnRelease();")
    > > > > > >
    > > > > > > End If
    > > > > > >
    > > > > > > End Sub
    > > > > > >
    > > > > > > Public Sub btnComplete_ServerClick()
    > > > > > > ' ....my server side ADO.net code
    > > > > > > End Sub
    > > > > > >
    > > > > > > '......... etc etc
    > > > > > > End Class
    > > > > > >
    > > > > > >
    > > > > > > >>>>> myPage.asp
    > > > > > > -----------------------
    > > > > > >
    > > > > > > <!-- my head title tags and all that joy... -->
    > > > > > >
    > > > > > > function OnComplete()
    > > > > > > {
    > > > > > > if ( confirm("Do you wish to complete this order?") )
    > > > > > > {
    > > > > > > btnComplete_ServerClick()
    > > > > > > }
    > > > > > > }
    > > > > > >
    > > > > > > <!-- my body tags and rest of the code and all that joy -->
    > > > > > >
    > > > > > > <<<<<<<<<<<<<<<<<, the end
    > > > > > >
    > > > > > >
    > > > > > >
    > > > > > > now it's obvious this ain't gonna work, even with my wishful
    > > thinking,
    > > > > > > because there's no object btnComplete_ServerClick when the
    script
    > > > > > function
    > > > > > > is called...
    > > > > > >
    > > > > > > so how do you do it?!?!?
    > > > > > >
    > > > > > > thanks.
    > > > > > > Dan.
    > > > > > >
    > > > > > >
    > > > > >
    > > > > >
    > > > >
    > > > >
    > > >
    > > >
    > >
    > >
    >
    >

    Daniel Bass Guest

  7. #7

    Default Re: Server Side Confirmation pop-up...

    the post back stuff is a result of me adding a server side handler for the
    button...
    if i don't have an event handler, then how can i get a server side method to
    run after this client side event?

    "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    news:%23EiSajrUDHA.3312tk2msftngp13.phx.gbl...
    > Dan,
    >
    > Did you add the do post back stuff yourself?
    >
    > I run the code I gave you in my codebehind page's page load and it's
    > produced in the html sent to the client like this:
    >
    > <input type="submit" name="Button1" value="Button" id="Button1"
    > onClick="javascript:if(!confirm('Do you wish to complete this order?'))
    > return false;" style="Z-INDEX: 101; LEFT: 8px; POSITION: absolute; TOP:
    8px"
    > />
    >
    > Where is the doPostBack routine of yours coming from?
    >
    > --
    > S. Justin Gengo, MCP
    > Web Developer
    >
    > Free code library at:
    > [url]www.aboutfortunate.com[/url]
    >
    > "Out of chaos comes order."
    > Nietzche
    > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    > news:up8BTXrUDHA.2248TK2MSFTNGP10.phx.gbl...
    > > You can do that?? You da man!
    > >
    > > Only I'm getting and object doesn't exist error on this block in the
    HTML,
    > > the highlight in question sort of starts at the "a" in false and goes
    > > through to the "d" in __doPostBack... so I'm not sure which one it's
    > > complaining about.
    > >
    > > onclick="javascript:if(!confirm('Do you wish to complete this order?'))
    {
    > > return false; } __doPostBack('btnComplete','')"
    > >
    > > Thanks.
    > >
    > > Dan.
    > >
    > >
    > >
    > > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    > > news:%23wpCmLrUDHA.2040TK2MSFTNGP11.phx.gbl...
    > > > Dan,
    > > >
    > > > You're just thinking about it too hard!
    > > >
    > > > Try this:
    > > >
    > > > WebControlButton.Attributes.Add("onClick", "javascript:if(!confirm('Do
    > you
    > > > wish to complete this order?')) return false;")
    > > >
    > > > Now if the confirmation goes through the WebControlButton's click
    event
    > > > server side will be fired and your server side code can all go there.
    > > >
    > > > If the confirmation's cancel button is clicked note that the
    javascript
    > > > function returns false. The form will not be posted back in that case.
    > > >
    > > > Is this what you want?
    > > >
    > > >
    > > > --
    > > > S. Justin Gengo, MCP
    > > > Web Developer
    > > >
    > > > Free code library at:
    > > > [url]www.aboutfortunate.com[/url]
    > > >
    > > > "Out of chaos comes order."
    > > > Nietzche
    > > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    > > > news:urHxKGrUDHA.3972tk2msftngp13.phx.gbl...
    > > > > I know I know, you can't have a server side pop up, even if you
    could
    > it
    > > > > would pop up on the servers monitor and not the client...
    > > > >
    > > > > but what i want to do is, when a button is clicked on a screen,
    > launched
    > > > the
    > > > > confirm("...") message box, then call server side code on the code
    > > behind
    > > > > page, depending on the result of the confirm box.
    > > > >
    > > > > I've got something like this at the moment:
    > > > >
    > > > > >>>> myPage.aspx.vb
    > > > > ----------------------------
    > > > > Public Class myClass
    > > > > Inherits System.Web.UI.Page
    > > > >
    > > > > '...... other initialization stuff
    > > > >
    > > > > Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
    > > > > System.EventArgs) Handles MyBase.Load
    > > > > 'Put user code to initialize the page here
    > > > >
    > > > > If Not IsPostBack Then
    > > > >
    > > > > '.... someother code
    > > > > btnRelease.Attributes.Add("onclick", "OnRelease();")
    > > > >
    > > > > End If
    > > > >
    > > > > End Sub
    > > > >
    > > > > Public Sub btnComplete_ServerClick()
    > > > > ' ....my server side ADO.net code
    > > > > End Sub
    > > > >
    > > > > '......... etc etc
    > > > > End Class
    > > > >
    > > > >
    > > > > >>>>> myPage.asp
    > > > > -----------------------
    > > > >
    > > > > <!-- my head title tags and all that joy... -->
    > > > >
    > > > > function OnComplete()
    > > > > {
    > > > > if ( confirm("Do you wish to complete this order?") )
    > > > > {
    > > > > btnComplete_ServerClick()
    > > > > }
    > > > > }
    > > > >
    > > > > <!-- my body tags and rest of the code and all that joy -->
    > > > >
    > > > > <<<<<<<<<<<<<<<<<, the end
    > > > >
    > > > >
    > > > >
    > > > > now it's obvious this ain't gonna work, even with my wishful
    thinking,
    > > > > because there's no object btnComplete_ServerClick when the script
    > > > function
    > > > > is called...
    > > > >
    > > > > so how do you do it?!?!?
    > > > >
    > > > > thanks.
    > > > > Dan.
    > > > >
    > > > >
    > > >
    > > >
    > >
    > >
    >
    >

    Daniel Bass Guest

  8. #8

    Default Re: Server Side Confirmation pop-up...

    You'll have to add an event handler.

    --
    S. Justin Gengo, MCP
    Web Developer

    Free code library at:
    [url]www.aboutfortunate.com[/url]

    "Out of chaos comes order."
    Nietzche
    "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    news:uT4ZaiOVDHA.2236TK2MSFTNGP12.phx.gbl...
    > the post back stuff is a result of me adding a server side handler for the
    > button...
    > if i don't have an event handler, then how can i get a server side method
    to
    > run after this client side event?
    >
    > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    > news:%23EiSajrUDHA.3312tk2msftngp13.phx.gbl...
    > > Dan,
    > >
    > > Did you add the do post back stuff yourself?
    > >
    > > I run the code I gave you in my codebehind page's page load and it's
    > > produced in the html sent to the client like this:
    > >
    > > <input type="submit" name="Button1" value="Button" id="Button1"
    > > onClick="javascript:if(!confirm('Do you wish to complete this order?'))
    > > return false;" style="Z-INDEX: 101; LEFT: 8px; POSITION: absolute; TOP:
    > 8px"
    > > />
    > >
    > > Where is the doPostBack routine of yours coming from?
    > >
    > > --
    > > S. Justin Gengo, MCP
    > > Web Developer
    > >
    > > Free code library at:
    > > [url]www.aboutfortunate.com[/url]
    > >
    > > "Out of chaos comes order."
    > > Nietzche
    > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    > > news:up8BTXrUDHA.2248TK2MSFTNGP10.phx.gbl...
    > > > You can do that?? You da man!
    > > >
    > > > Only I'm getting and object doesn't exist error on this block in the
    > HTML,
    > > > the highlight in question sort of starts at the "a" in false and goes
    > > > through to the "d" in __doPostBack... so I'm not sure which one it's
    > > > complaining about.
    > > >
    > > > onclick="javascript:if(!confirm('Do you wish to complete this
    order?'))
    > {
    > > > return false; } __doPostBack('btnComplete','')"
    > > >
    > > > Thanks.
    > > >
    > > > Dan.
    > > >
    > > >
    > > >
    > > > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    > > > news:%23wpCmLrUDHA.2040TK2MSFTNGP11.phx.gbl...
    > > > > Dan,
    > > > >
    > > > > You're just thinking about it too hard!
    > > > >
    > > > > Try this:
    > > > >
    > > > > WebControlButton.Attributes.Add("onClick",
    "javascript:if(!confirm('Do
    > > you
    > > > > wish to complete this order?')) return false;")
    > > > >
    > > > > Now if the confirmation goes through the WebControlButton's click
    > event
    > > > > server side will be fired and your server side code can all go
    there.
    > > > >
    > > > > If the confirmation's cancel button is clicked note that the
    > javascript
    > > > > function returns false. The form will not be posted back in that
    case.
    > > > >
    > > > > Is this what you want?
    > > > >
    > > > >
    > > > > --
    > > > > S. Justin Gengo, MCP
    > > > > Web Developer
    > > > >
    > > > > Free code library at:
    > > > > [url]www.aboutfortunate.com[/url]
    > > > >
    > > > > "Out of chaos comes order."
    > > > > Nietzche
    > > > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in
    message
    > > > > news:urHxKGrUDHA.3972tk2msftngp13.phx.gbl...
    > > > > > I know I know, you can't have a server side pop up, even if you
    > could
    > > it
    > > > > > would pop up on the servers monitor and not the client...
    > > > > >
    > > > > > but what i want to do is, when a button is clicked on a screen,
    > > launched
    > > > > the
    > > > > > confirm("...") message box, then call server side code on the code
    > > > behind
    > > > > > page, depending on the result of the confirm box.
    > > > > >
    > > > > > I've got something like this at the moment:
    > > > > >
    > > > > > >>>> myPage.aspx.vb
    > > > > > ----------------------------
    > > > > > Public Class myClass
    > > > > > Inherits System.Web.UI.Page
    > > > > >
    > > > > > '...... other initialization stuff
    > > > > >
    > > > > > Private Sub Page_Load(ByVal sender As System.Object, ByVal e
    As
    > > > > > System.EventArgs) Handles MyBase.Load
    > > > > > 'Put user code to initialize the page here
    > > > > >
    > > > > > If Not IsPostBack Then
    > > > > >
    > > > > > '.... someother code
    > > > > > btnRelease.Attributes.Add("onclick", "OnRelease();")
    > > > > >
    > > > > > End If
    > > > > >
    > > > > > End Sub
    > > > > >
    > > > > > Public Sub btnComplete_ServerClick()
    > > > > > ' ....my server side ADO.net code
    > > > > > End Sub
    > > > > >
    > > > > > '......... etc etc
    > > > > > End Class
    > > > > >
    > > > > >
    > > > > > >>>>> myPage.asp
    > > > > > -----------------------
    > > > > >
    > > > > > <!-- my head title tags and all that joy... -->
    > > > > >
    > > > > > function OnComplete()
    > > > > > {
    > > > > > if ( confirm("Do you wish to complete this order?") )
    > > > > > {
    > > > > > btnComplete_ServerClick()
    > > > > > }
    > > > > > }
    > > > > >
    > > > > > <!-- my body tags and rest of the code and all that joy -->
    > > > > >
    > > > > > <<<<<<<<<<<<<<<<<, the end
    > > > > >
    > > > > >
    > > > > >
    > > > > > now it's obvious this ain't gonna work, even with my wishful
    > thinking,
    > > > > > because there's no object btnComplete_ServerClick when the script
    > > > > function
    > > > > > is called...
    > > > > >
    > > > > > so how do you do it?!?!?
    > > > > >
    > > > > > thanks.
    > > > > > Dan.
    > > > > >
    > > > > >
    > > > >
    > > > >
    > > >
    > > >
    > >
    > >
    >
    >

    S. Justin Gengo Guest

  9. #9

    Default Re: Server Side Confirmation pop-up...

    Thanks for your patience, you must think i'm thick!!!

    to clarify... I add

    WebControlButton.Attributes.Add("onClick",
    "javascript:if(!confirm('Do you wish to complete this order?')) return
    false;")

    to the Page_Load method...
    I also double click on the button then, to write my server side stuff,
    getting this :-

    Public Sub WebControlButton_ServerClick(ByVal obj As Object, ByVal e
    As System.EventArgs) Handles btnRelease.ServerClick

    ...some server side stuff

    End Sub


    so this then executes the javascript, then if the user clicks okay,
    processes my WebControlButton_ServerClick method?

    but i get an object doesn't exist error when i do this,
    onclick="javascript:if(!confirm('Do you wish to complete this
    order?')) { return false; } __doPostBack('btnComplete','')"

    on the doPostBack which the compiler adds when the page is processed.





    "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    news:e0ltpJRVDHA.2012TK2MSFTNGP10.phx.gbl...
    > Daniel,
    >
    > The code I gave you attaches a javascript confirmation to a specific
    button.
    > When that button is clicked the form will only be posted back to the
    server
    > if a user clicks "OK". Once the form is submitted you place the code you
    > want to run inside of that buttons click event which occurrs server side.
    >
    > --
    > S. Justin Gengo, MCP
    > Web Developer
    >
    > Free code library at:
    > [url]www.aboutfortunate.com[/url]
    >
    > "Out of chaos comes order."
    > Nietzche
    > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    > news:O0AAKgOVDHA.1744TK2MSFTNGP12.phx.gbl...
    > > I've got an confirmation box, which will have to be launched client
    side.
    > > I then need some server side code to be launched if there is a "yes"
    click
    > > on the confirmation screen...
    > >
    > > is this possible?
    > >
    > > you either have a server side event handler, or a onClick event handler
    in
    > > the client... this is what's causing me the problem.
    > >
    > >
    > > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    > > news:eEdwWXvUDHA.1316TK2MSFTNGP12.phx.gbl...
    > > > As long as you're using a asp.net button then that button is
    associated
    > > with
    > > > a server side event.
    > > >
    > > > It would look like this:
    > > >
    > > > Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
    > > > System.EventArgs) Handles Button1.Click
    > > >
    > > > '---Put your code here
    > > >
    > > > End Sub
    > > >
    > > >
    > > > --
    > > > S. Justin Gengo, MCP
    > > > Web Developer
    > > >
    > > > Free code library at:
    > > > [url]www.aboutfortunate.com[/url]
    > > >
    > > > "Out of chaos comes order."
    > > > Nietzche
    > > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    > > > news:eiF8iorUDHA.2204TK2MSFTNGP10.phx.gbl...
    > > > > What do i do when the users clicked on OK?
    > > > >
    > > > > What I'd like to happen is for some server side code to run and
    > process
    > > a
    > > > > few bits...
    > > > >
    > > > > The code you gave me, I thought I'd be able to do this?
    > > > >
    > > > > my bad.
    > > > >
    > > > > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    > > > > news:%23EiSajrUDHA.3312tk2msftngp13.phx.gbl...
    > > > > > Dan,
    > > > > >
    > > > > > Did you add the do post back stuff yourself?
    > > > > >
    > > > > > I run the code I gave you in my codebehind page's page load and
    it's
    > > > > > produced in the html sent to the client like this:
    > > > > >
    > > > > > <input type="submit" name="Button1" value="Button" id="Button1"
    > > > > > onClick="javascript:if(!confirm('Do you wish to complete this
    > > order?'))
    > > > > > return false;" style="Z-INDEX: 101; LEFT: 8px; POSITION: absolute;
    > > TOP:
    > > > > 8px"
    > > > > > />
    > > > > >
    > > > > > Where is the doPostBack routine of yours coming from?
    > > > > >
    > > > > > --
    > > > > > S. Justin Gengo, MCP
    > > > > > Web Developer
    > > > > >
    > > > > > Free code library at:
    > > > > > [url]www.aboutfortunate.com[/url]
    > > > > >
    > > > > > "Out of chaos comes order."
    > > > > > Nietzche
    > > > > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in
    > message
    > > > > > news:up8BTXrUDHA.2248TK2MSFTNGP10.phx.gbl...
    > > > > > > You can do that?? You da man!
    > > > > > >
    > > > > > > Only I'm getting and object doesn't exist error on this block in
    > the
    > > > > HTML,
    > > > > > > the highlight in question sort of starts at the "a" in false and
    > > goes
    > > > > > > through to the "d" in __doPostBack... so I'm not sure which one
    > it's
    > > > > > > complaining about.
    > > > > > >
    > > > > > > onclick="javascript:if(!confirm('Do you wish to complete this
    > > > order?'))
    > > > > {
    > > > > > > return false; } __doPostBack('btnComplete','')"
    > > > > > >
    > > > > > > Thanks.
    > > > > > >
    > > > > > > Dan.
    > > > > > >
    > > > > > >
    > > > > > >
    > > > > > > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    > > > > > > news:%23wpCmLrUDHA.2040TK2MSFTNGP11.phx.gbl...
    > > > > > > > Dan,
    > > > > > > >
    > > > > > > > You're just thinking about it too hard!
    > > > > > > >
    > > > > > > > Try this:
    > > > > > > >
    > > > > > > > WebControlButton.Attributes.Add("onClick",
    > > > "javascript:if(!confirm('Do
    > > > > > you
    > > > > > > > wish to complete this order?')) return false;")
    > > > > > > >
    > > > > > > > Now if the confirmation goes through the WebControlButton's
    > click
    > > > > event
    > > > > > > > server side will be fired and your server side code can all go
    > > > there.
    > > > > > > >
    > > > > > > > If the confirmation's cancel button is clicked note that the
    > > > > javascript
    > > > > > > > function returns false. The form will not be posted back in
    that
    > > > case.
    > > > > > > >
    > > > > > > > Is this what you want?
    > > > > > > >
    > > > > > > >
    > > > > > > > --
    > > > > > > > S. Justin Gengo, MCP
    > > > > > > > Web Developer
    > > > > > > >
    > > > > > > > Free code library at:
    > > > > > > > [url]www.aboutfortunate.com[/url]
    > > > > > > >
    > > > > > > > "Out of chaos comes order."
    > > > > > > > Nietzche
    > > > > > > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in
    > > > message
    > > > > > > > news:urHxKGrUDHA.3972tk2msftngp13.phx.gbl...
    > > > > > > > > I know I know, you can't have a server side pop up, even if
    > you
    > > > > could
    > > > > > it
    > > > > > > > > would pop up on the servers monitor and not the client...
    > > > > > > > >
    > > > > > > > > but what i want to do is, when a button is clicked on a
    > screen,
    > > > > > launched
    > > > > > > > the
    > > > > > > > > confirm("...") message box, then call server side code on
    the
    > > code
    > > > > > > behind
    > > > > > > > > page, depending on the result of the confirm box.
    > > > > > > > >
    > > > > > > > > I've got something like this at the moment:
    > > > > > > > >
    > > > > > > > > >>>> myPage.aspx.vb
    > > > > > > > > ----------------------------
    > > > > > > > > Public Class myClass
    > > > > > > > > Inherits System.Web.UI.Page
    > > > > > > > >
    > > > > > > > > '...... other initialization stuff
    > > > > > > > >
    > > > > > > > > Private Sub Page_Load(ByVal sender As System.Object,
    ByVal
    > e
    > > > As
    > > > > > > > > System.EventArgs) Handles MyBase.Load
    > > > > > > > > 'Put user code to initialize the page here
    > > > > > > > >
    > > > > > > > > If Not IsPostBack Then
    > > > > > > > >
    > > > > > > > > '.... someother code
    > > > > > > > > btnRelease.Attributes.Add("onclick",
    > "OnRelease();")
    > > > > > > > >
    > > > > > > > > End If
    > > > > > > > >
    > > > > > > > > End Sub
    > > > > > > > >
    > > > > > > > > Public Sub btnComplete_ServerClick()
    > > > > > > > > ' ....my server side ADO.net code
    > > > > > > > > End Sub
    > > > > > > > >
    > > > > > > > > '......... etc etc
    > > > > > > > > End Class
    > > > > > > > >
    > > > > > > > >
    > > > > > > > > >>>>> myPage.asp
    > > > > > > > > -----------------------
    > > > > > > > >
    > > > > > > > > <!-- my head title tags and all that joy... -->
    > > > > > > > >
    > > > > > > > > function OnComplete()
    > > > > > > > > {
    > > > > > > > > if ( confirm("Do you wish to complete this
    order?") )
    > > > > > > > > {
    > > > > > > > > btnComplete_ServerClick()
    > > > > > > > > }
    > > > > > > > > }
    > > > > > > > >
    > > > > > > > > <!-- my body tags and rest of the code and all that joy -->
    > > > > > > > >
    > > > > > > > > <<<<<<<<<<<<<<<<<, the end
    > > > > > > > >
    > > > > > > > >
    > > > > > > > >
    > > > > > > > > now it's obvious this ain't gonna work, even with my wishful
    > > > > thinking,
    > > > > > > > > because there's no object btnComplete_ServerClick when the
    > > script
    > > > > > > > function
    > > > > > > > > is called...
    > > > > > > > >
    > > > > > > > > so how do you do it?!?!?
    > > > > > > > >
    > > > > > > > > thanks.
    > > > > > > > > Dan.
    > > > > > > > >
    > > > > > > > >
    > > > > > > >
    > > > > > > >
    > > > > > >
    > > > > > >
    > > > > >
    > > > > >
    > > > >
    > > > >
    > > >
    > > >
    > >
    > >
    >
    >

    Daniel Bass Guest

  10. #10

    Default Re: Server Side Confirmation pop-up...

    It took me quite a while to get the hang of this so, no, I don't think your
    thick!

    When I use this code there is no __DoPostBack

    I notice that the __DoPostBack is trying to fire a different button,
    btnComplete...

    Does this button exist? If not that is the cause of the object doesn't exist
    error.

    If it does exist try attaching the confirmation to the btnComplete Button
    instead:

    btnComplete.Attributes.Add("onClick", "javascript:if(!confirm('Do you wish
    to complete this order?')) return false;")

    --
    S. Justin Gengo, MCP
    Web Developer

    Free code library at:
    [url]www.aboutfortunate.com[/url]

    "Out of chaos comes order."
    Nietzche
    "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    news:OEDfQQRVDHA.2004TK2MSFTNGP10.phx.gbl...
    > Thanks for your patience, you must think i'm thick!!!
    >
    > to clarify... I add
    >
    > WebControlButton.Attributes.Add("onClick",
    > "javascript:if(!confirm('Do you wish to complete this order?')) return
    > false;")
    >
    > to the Page_Load method...
    > I also double click on the button then, to write my server side stuff,
    > getting this :-
    >
    > Public Sub WebControlButton_ServerClick(ByVal obj As Object, ByVal
    e
    > As System.EventArgs) Handles btnRelease.ServerClick
    >
    > ...some server side stuff
    >
    > End Sub
    >
    >
    > so this then executes the javascript, then if the user clicks okay,
    > processes my WebControlButton_ServerClick method?
    >
    > but i get an object doesn't exist error when i do this,
    > onclick="javascript:if(!confirm('Do you wish to complete this
    > order?')) { return false; } __doPostBack('btnComplete','')"
    >
    > on the doPostBack which the compiler adds when the page is processed.
    >
    >
    >
    >
    >
    > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    > news:e0ltpJRVDHA.2012TK2MSFTNGP10.phx.gbl...
    > > Daniel,
    > >
    > > The code I gave you attaches a javascript confirmation to a specific
    > button.
    > > When that button is clicked the form will only be posted back to the
    > server
    > > if a user clicks "OK". Once the form is submitted you place the code you
    > > want to run inside of that buttons click event which occurrs server
    side.
    > >
    > > --
    > > S. Justin Gengo, MCP
    > > Web Developer
    > >
    > > Free code library at:
    > > [url]www.aboutfortunate.com[/url]
    > >
    > > "Out of chaos comes order."
    > > Nietzche
    > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    > > news:O0AAKgOVDHA.1744TK2MSFTNGP12.phx.gbl...
    > > > I've got an confirmation box, which will have to be launched client
    > side.
    > > > I then need some server side code to be launched if there is a "yes"
    > click
    > > > on the confirmation screen...
    > > >
    > > > is this possible?
    > > >
    > > > you either have a server side event handler, or a onClick event
    handler
    > in
    > > > the client... this is what's causing me the problem.
    > > >
    > > >
    > > > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    > > > news:eEdwWXvUDHA.1316TK2MSFTNGP12.phx.gbl...
    > > > > As long as you're using a asp.net button then that button is
    > associated
    > > > with
    > > > > a server side event.
    > > > >
    > > > > It would look like this:
    > > > >
    > > > > Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
    > > > > System.EventArgs) Handles Button1.Click
    > > > >
    > > > > '---Put your code here
    > > > >
    > > > > End Sub
    > > > >
    > > > >
    > > > > --
    > > > > S. Justin Gengo, MCP
    > > > > Web Developer
    > > > >
    > > > > Free code library at:
    > > > > [url]www.aboutfortunate.com[/url]
    > > > >
    > > > > "Out of chaos comes order."
    > > > > Nietzche
    > > > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in
    message
    > > > > news:eiF8iorUDHA.2204TK2MSFTNGP10.phx.gbl...
    > > > > > What do i do when the users clicked on OK?
    > > > > >
    > > > > > What I'd like to happen is for some server side code to run and
    > > process
    > > > a
    > > > > > few bits...
    > > > > >
    > > > > > The code you gave me, I thought I'd be able to do this?
    > > > > >
    > > > > > my bad.
    > > > > >
    > > > > > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    > > > > > news:%23EiSajrUDHA.3312tk2msftngp13.phx.gbl...
    > > > > > > Dan,
    > > > > > >
    > > > > > > Did you add the do post back stuff yourself?
    > > > > > >
    > > > > > > I run the code I gave you in my codebehind page's page load and
    > it's
    > > > > > > produced in the html sent to the client like this:
    > > > > > >
    > > > > > > <input type="submit" name="Button1" value="Button" id="Button1"
    > > > > > > onClick="javascript:if(!confirm('Do you wish to complete this
    > > > order?'))
    > > > > > > return false;" style="Z-INDEX: 101; LEFT: 8px; POSITION:
    absolute;
    > > > TOP:
    > > > > > 8px"
    > > > > > > />
    > > > > > >
    > > > > > > Where is the doPostBack routine of yours coming from?
    > > > > > >
    > > > > > > --
    > > > > > > S. Justin Gengo, MCP
    > > > > > > Web Developer
    > > > > > >
    > > > > > > Free code library at:
    > > > > > > [url]www.aboutfortunate.com[/url]
    > > > > > >
    > > > > > > "Out of chaos comes order."
    > > > > > > Nietzche
    > > > > > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in
    > > message
    > > > > > > news:up8BTXrUDHA.2248TK2MSFTNGP10.phx.gbl...
    > > > > > > > You can do that?? You da man!
    > > > > > > >
    > > > > > > > Only I'm getting and object doesn't exist error on this block
    in
    > > the
    > > > > > HTML,
    > > > > > > > the highlight in question sort of starts at the "a" in false
    and
    > > > goes
    > > > > > > > through to the "d" in __doPostBack... so I'm not sure which
    one
    > > it's
    > > > > > > > complaining about.
    > > > > > > >
    > > > > > > > onclick="javascript:if(!confirm('Do you wish to complete this
    > > > > order?'))
    > > > > > {
    > > > > > > > return false; } __doPostBack('btnComplete','')"
    > > > > > > >
    > > > > > > > Thanks.
    > > > > > > >
    > > > > > > > Dan.
    > > > > > > >
    > > > > > > >
    > > > > > > >
    > > > > > > > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in
    message
    > > > > > > > news:%23wpCmLrUDHA.2040TK2MSFTNGP11.phx.gbl...
    > > > > > > > > Dan,
    > > > > > > > >
    > > > > > > > > You're just thinking about it too hard!
    > > > > > > > >
    > > > > > > > > Try this:
    > > > > > > > >
    > > > > > > > > WebControlButton.Attributes.Add("onClick",
    > > > > "javascript:if(!confirm('Do
    > > > > > > you
    > > > > > > > > wish to complete this order?')) return false;")
    > > > > > > > >
    > > > > > > > > Now if the confirmation goes through the WebControlButton's
    > > click
    > > > > > event
    > > > > > > > > server side will be fired and your server side code can all
    go
    > > > > there.
    > > > > > > > >
    > > > > > > > > If the confirmation's cancel button is clicked note that the
    > > > > > javascript
    > > > > > > > > function returns false. The form will not be posted back in
    > that
    > > > > case.
    > > > > > > > >
    > > > > > > > > Is this what you want?
    > > > > > > > >
    > > > > > > > >
    > > > > > > > > --
    > > > > > > > > S. Justin Gengo, MCP
    > > > > > > > > Web Developer
    > > > > > > > >
    > > > > > > > > Free code library at:
    > > > > > > > > [url]www.aboutfortunate.com[/url]
    > > > > > > > >
    > > > > > > > > "Out of chaos comes order."
    > > > > > > > > Nietzche
    > > > > > > > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote
    in
    > > > > message
    > > > > > > > > news:urHxKGrUDHA.3972tk2msftngp13.phx.gbl...
    > > > > > > > > > I know I know, you can't have a server side pop up, even
    if
    > > you
    > > > > > could
    > > > > > > it
    > > > > > > > > > would pop up on the servers monitor and not the client...
    > > > > > > > > >
    > > > > > > > > > but what i want to do is, when a button is clicked on a
    > > screen,
    > > > > > > launched
    > > > > > > > > the
    > > > > > > > > > confirm("...") message box, then call server side code on
    > the
    > > > code
    > > > > > > > behind
    > > > > > > > > > page, depending on the result of the confirm box.
    > > > > > > > > >
    > > > > > > > > > I've got something like this at the moment:
    > > > > > > > > >
    > > > > > > > > > >>>> myPage.aspx.vb
    > > > > > > > > > ----------------------------
    > > > > > > > > > Public Class myClass
    > > > > > > > > > Inherits System.Web.UI.Page
    > > > > > > > > >
    > > > > > > > > > '...... other initialization stuff
    > > > > > > > > >
    > > > > > > > > > Private Sub Page_Load(ByVal sender As System.Object,
    > ByVal
    > > e
    > > > > As
    > > > > > > > > > System.EventArgs) Handles MyBase.Load
    > > > > > > > > > 'Put user code to initialize the page here
    > > > > > > > > >
    > > > > > > > > > If Not IsPostBack Then
    > > > > > > > > >
    > > > > > > > > > '.... someother code
    > > > > > > > > > btnRelease.Attributes.Add("onclick",
    > > "OnRelease();")
    > > > > > > > > >
    > > > > > > > > > End If
    > > > > > > > > >
    > > > > > > > > > End Sub
    > > > > > > > > >
    > > > > > > > > > Public Sub btnComplete_ServerClick()
    > > > > > > > > > ' ....my server side ADO.net code
    > > > > > > > > > End Sub
    > > > > > > > > >
    > > > > > > > > > '......... etc etc
    > > > > > > > > > End Class
    > > > > > > > > >
    > > > > > > > > >
    > > > > > > > > > >>>>> myPage.asp
    > > > > > > > > > -----------------------
    > > > > > > > > >
    > > > > > > > > > <!-- my head title tags and all that joy... -->
    > > > > > > > > >
    > > > > > > > > > function OnComplete()
    > > > > > > > > > {
    > > > > > > > > > if ( confirm("Do you wish to complete this
    > order?") )
    > > > > > > > > > {
    > > > > > > > > > btnComplete_ServerClick()
    > > > > > > > > > }
    > > > > > > > > > }
    > > > > > > > > >
    > > > > > > > > > <!-- my body tags and rest of the code and all that
    joy -->
    > > > > > > > > >
    > > > > > > > > > <<<<<<<<<<<<<<<<<, the end
    > > > > > > > > >
    > > > > > > > > >
    > > > > > > > > >
    > > > > > > > > > now it's obvious this ain't gonna work, even with my
    wishful
    > > > > > thinking,
    > > > > > > > > > because there's no object btnComplete_ServerClick when
    the
    > > > script
    > > > > > > > > function
    > > > > > > > > > is called...
    > > > > > > > > >
    > > > > > > > > > so how do you do it?!?!?
    > > > > > > > > >
    > > > > > > > > > thanks.
    > > > > > > > > > Dan.
    > > > > > > > > >
    > > > > > > > > >
    > > > > > > > >
    > > > > > > > >
    > > > > > > >
    > > > > > > >
    > > > > > >
    > > > > > >
    > > > > >
    > > > > >
    > > > >
    > > > >
    > > >
    > > >
    > >
    > >
    >
    >

    S. Justin Gengo Guest

  11. #11

    Default Re: Server Side Confirmation pop-up...

    the html for the button in question is:

    <INPUT id=btnComplete type=button value=Complete name=btnComplete
    RUNAT="server">

    the aspx.vb Page_Load code is this:

    btnComplete.Attributes.Add("onclick", "javascript:if(!confirm('Do you
    wish to complete this order?')) return false;")

    the event handler looks like this:

    Private Sub btnComplete_ServerClick(ByVal sender As System.Object,
    ByVal e As System.EventArgs) Handles btnComplete.ServerClick
    Dim i = 0 ' break point here so i know it executes
    End Sub


    but i get this error...

    <input language="javascript" onclick="javascript:if(!confirm('Do you
    wish to complete this order?')) return false;
    __doPostBack('btnComplete','')" name="btnComplete" id="btnComplete"
    type="button" value="Complete" />



    the stupid thing is that btnComplete is only defined after it's used as a
    parameter in the postback method... how in the earth did that happen? You'll
    notice the HTML for my declaration puts the ID right at the front.

    Hmm... we get closer to the solution though.

    Thanks again.


    "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    news:%23dqR9%23RVDHA.2040TK2MSFTNGP11.phx.gbl...
    > It took me quite a while to get the hang of this so, no, I don't think
    your
    > thick!
    >
    > When I use this code there is no __DoPostBack
    >
    > I notice that the __DoPostBack is trying to fire a different button,
    > btnComplete...
    >
    > Does this button exist? If not that is the cause of the object doesn't
    exist
    > error.
    >
    > If it does exist try attaching the confirmation to the btnComplete Button
    > instead:
    >
    > btnComplete.Attributes.Add("onClick", "javascript:if(!confirm('Do you wish
    > to complete this order?')) return false;")
    >
    > --
    > S. Justin Gengo, MCP
    > Web Developer
    >
    > Free code library at:
    > [url]www.aboutfortunate.com[/url]
    >
    > "Out of chaos comes order."
    > Nietzche
    > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    > news:OEDfQQRVDHA.2004TK2MSFTNGP10.phx.gbl...
    > > Thanks for your patience, you must think i'm thick!!!
    > >
    > > to clarify... I add
    > >
    > > WebControlButton.Attributes.Add("onClick",
    > > "javascript:if(!confirm('Do you wish to complete this order?')) return
    > > false;")
    > >
    > > to the Page_Load method...
    > > I also double click on the button then, to write my server side stuff,
    > > getting this :-
    > >
    > > Public Sub WebControlButton_ServerClick(ByVal obj As Object,
    ByVal
    > e
    > > As System.EventArgs) Handles btnRelease.ServerClick
    > >
    > > ...some server side stuff
    > >
    > > End Sub
    > >
    > >
    > > so this then executes the javascript, then if the user clicks okay,
    > > processes my WebControlButton_ServerClick method?
    > >
    > > but i get an object doesn't exist error when i do this,
    > > onclick="javascript:if(!confirm('Do you wish to complete this
    > > order?')) { return false; } __doPostBack('btnComplete','')"
    > >
    > > on the doPostBack which the compiler adds when the page is processed.
    > >
    > >
    > >
    > >
    > >
    > > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    > > news:e0ltpJRVDHA.2012TK2MSFTNGP10.phx.gbl...
    > > > Daniel,
    > > >
    > > > The code I gave you attaches a javascript confirmation to a specific
    > > button.
    > > > When that button is clicked the form will only be posted back to the
    > > server
    > > > if a user clicks "OK". Once the form is submitted you place the code
    you
    > > > want to run inside of that buttons click event which occurrs server
    > side.
    > > >
    > > > --
    > > > S. Justin Gengo, MCP
    > > > Web Developer
    > > >
    > > > Free code library at:
    > > > [url]www.aboutfortunate.com[/url]
    > > >
    > > > "Out of chaos comes order."
    > > > Nietzche
    > > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in message
    > > > news:O0AAKgOVDHA.1744TK2MSFTNGP12.phx.gbl...
    > > > > I've got an confirmation box, which will have to be launched client
    > > side.
    > > > > I then need some server side code to be launched if there is a "yes"
    > > click
    > > > > on the confirmation screen...
    > > > >
    > > > > is this possible?
    > > > >
    > > > > you either have a server side event handler, or a onClick event
    > handler
    > > in
    > > > > the client... this is what's causing me the problem.
    > > > >
    > > > >
    > > > > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    > > > > news:eEdwWXvUDHA.1316TK2MSFTNGP12.phx.gbl...
    > > > > > As long as you're using a asp.net button then that button is
    > > associated
    > > > > with
    > > > > > a server side event.
    > > > > >
    > > > > > It would look like this:
    > > > > >
    > > > > > Private Sub Button1_Click(ByVal sender As System.Object, ByVal e
    As
    > > > > > System.EventArgs) Handles Button1.Click
    > > > > >
    > > > > > '---Put your code here
    > > > > >
    > > > > > End Sub
    > > > > >
    > > > > >
    > > > > > --
    > > > > > S. Justin Gengo, MCP
    > > > > > Web Developer
    > > > > >
    > > > > > Free code library at:
    > > > > > [url]www.aboutfortunate.com[/url]
    > > > > >
    > > > > > "Out of chaos comes order."
    > > > > > Nietzche
    > > > > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in
    > message
    > > > > > news:eiF8iorUDHA.2204TK2MSFTNGP10.phx.gbl...
    > > > > > > What do i do when the users clicked on OK?
    > > > > > >
    > > > > > > What I'd like to happen is for some server side code to run and
    > > > process
    > > > > a
    > > > > > > few bits...
    > > > > > >
    > > > > > > The code you gave me, I thought I'd be able to do this?
    > > > > > >
    > > > > > > my bad.
    > > > > > >
    > > > > > > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in message
    > > > > > > news:%23EiSajrUDHA.3312tk2msftngp13.phx.gbl...
    > > > > > > > Dan,
    > > > > > > >
    > > > > > > > Did you add the do post back stuff yourself?
    > > > > > > >
    > > > > > > > I run the code I gave you in my codebehind page's page load
    and
    > > it's
    > > > > > > > produced in the html sent to the client like this:
    > > > > > > >
    > > > > > > > <input type="submit" name="Button1" value="Button"
    id="Button1"
    > > > > > > > onClick="javascript:if(!confirm('Do you wish to complete this
    > > > > order?'))
    > > > > > > > return false;" style="Z-INDEX: 101; LEFT: 8px; POSITION:
    > absolute;
    > > > > TOP:
    > > > > > > 8px"
    > > > > > > > />
    > > > > > > >
    > > > > > > > Where is the doPostBack routine of yours coming from?
    > > > > > > >
    > > > > > > > --
    > > > > > > > S. Justin Gengo, MCP
    > > > > > > > Web Developer
    > > > > > > >
    > > > > > > > Free code library at:
    > > > > > > > [url]www.aboutfortunate.com[/url]
    > > > > > > >
    > > > > > > > "Out of chaos comes order."
    > > > > > > > Nietzche
    > > > > > > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk> wrote in
    > > > message
    > > > > > > > news:up8BTXrUDHA.2248TK2MSFTNGP10.phx.gbl...
    > > > > > > > > You can do that?? You da man!
    > > > > > > > >
    > > > > > > > > Only I'm getting and object doesn't exist error on this
    block
    > in
    > > > the
    > > > > > > HTML,
    > > > > > > > > the highlight in question sort of starts at the "a" in false
    > and
    > > > > goes
    > > > > > > > > through to the "d" in __doPostBack... so I'm not sure which
    > one
    > > > it's
    > > > > > > > > complaining about.
    > > > > > > > >
    > > > > > > > > onclick="javascript:if(!confirm('Do you wish to complete
    this
    > > > > > order?'))
    > > > > > > {
    > > > > > > > > return false; } __doPostBack('btnComplete','')"
    > > > > > > > >
    > > > > > > > > Thanks.
    > > > > > > > >
    > > > > > > > > Dan.
    > > > > > > > >
    > > > > > > > >
    > > > > > > > >
    > > > > > > > > "S. Justin Gengo" <sjgengoaboutfortunate.com> wrote in
    > message
    > > > > > > > > news:%23wpCmLrUDHA.2040TK2MSFTNGP11.phx.gbl...
    > > > > > > > > > Dan,
    > > > > > > > > >
    > > > > > > > > > You're just thinking about it too hard!
    > > > > > > > > >
    > > > > > > > > > Try this:
    > > > > > > > > >
    > > > > > > > > > WebControlButton.Attributes.Add("onClick",
    > > > > > "javascript:if(!confirm('Do
    > > > > > > > you
    > > > > > > > > > wish to complete this order?')) return false;")
    > > > > > > > > >
    > > > > > > > > > Now if the confirmation goes through the
    WebControlButton's
    > > > click
    > > > > > > event
    > > > > > > > > > server side will be fired and your server side code can
    all
    > go
    > > > > > there.
    > > > > > > > > >
    > > > > > > > > > If the confirmation's cancel button is clicked note that
    the
    > > > > > > javascript
    > > > > > > > > > function returns false. The form will not be posted back
    in
    > > that
    > > > > > case.
    > > > > > > > > >
    > > > > > > > > > Is this what you want?
    > > > > > > > > >
    > > > > > > > > >
    > > > > > > > > > --
    > > > > > > > > > S. Justin Gengo, MCP
    > > > > > > > > > Web Developer
    > > > > > > > > >
    > > > > > > > > > Free code library at:
    > > > > > > > > > [url]www.aboutfortunate.com[/url]
    > > > > > > > > >
    > > > > > > > > > "Out of chaos comes order."
    > > > > > > > > > Nietzche
    > > > > > > > > > "Daniel Bass" <danielbassNOJUNKMAILpostmaster.co.uk>
    wrote
    > in
    > > > > > message
    > > > > > > > > > news:urHxKGrUDHA.3972tk2msftngp13.phx.gbl...
    > > > > > > > > > > I know I know, you can't have a server side pop up, even
    > if
    > > > you
    > > > > > > could
    > > > > > > > it
    > > > > > > > > > > would pop up on the servers monitor and not the
    client...
    > > > > > > > > > >
    > > > > > > > > > > but what i want to do is, when a button is clicked on a
    > > > screen,
    > > > > > > > launched
    > > > > > > > > > the
    > > > > > > > > > > confirm("...") message box, then call server side code
    on
    > > the
    > > > > code
    > > > > > > > > behind
    > > > > > > > > > > page, depending on the result of the confirm box.
    > > > > > > > > > >
    > > > > > > > > > > I've got something like this at the moment:
    > > > > > > > > > >
    > > > > > > > > > > >>>> myPage.aspx.vb
    > > > > > > > > > > ----------------------------
    > > > > > > > > > > Public Class myClass
    > > > > > > > > > > Inherits System.Web.UI.Page
    > > > > > > > > > >
    > > > > > > > > > > '...... other initialization stuff
    > > > > > > > > > >
    > > > > > > > > > > Private Sub Page_Load(ByVal sender As System.Object,
    > > ByVal
    > > > e
    > > > > > As
    > > > > > > > > > > System.EventArgs) Handles MyBase.Load
    > > > > > > > > > > 'Put user code to initialize the page here
    > > > > > > > > > >
    > > > > > > > > > > If Not IsPostBack Then
    > > > > > > > > > >
    > > > > > > > > > > '.... someother code
    > > > > > > > > > > btnRelease.Attributes.Add("onclick",
    > > > "OnRelease();")
    > > > > > > > > > >
    > > > > > > > > > > End If
    > > > > > > > > > >
    > > > > > > > > > > End Sub
    > > > > > > > > > >
    > > > > > > > > > > Public Sub btnComplete_ServerClick()
    > > > > > > > > > > ' ....my server side ADO.net code
    > > > > > > > > > > End Sub
    > > > > > > > > > >
    > > > > > > > > > > '......... etc etc
    > > > > > > > > > > End Class
    > > > > > > > > > >
    > > > > > > > > > >
    > > > > > > > > > > >>>>> myPage.asp
    > > > > > > > > > > -----------------------
    > > > > > > > > > >
    > > > > > > > > > > <!-- my head title tags and all that joy... -->
    > > > > > > > > > >
    > > > > > > > > > > function OnComplete()
    > > > > > > > > > > {
    > > > > > > > > > > if ( confirm("Do you wish to complete this
    > > order?") )
    > > > > > > > > > > {
    > > > > > > > > > > btnComplete_ServerClick()
    > > > > > > > > > > }
    > > > > > > > > > > }
    > > > > > > > > > >
    > > > > > > > > > > <!-- my body tags and rest of the code and all that
    > joy -->
    > > > > > > > > > >
    > > > > > > > > > > <<<<<<<<<<<<<<<<<, the end
    > > > > > > > > > >
    > > > > > > > > > >
    > > > > > > > > > >
    > > > > > > > > > > now it's obvious this ain't gonna work, even with my
    > wishful
    > > > > > > thinking,
    > > > > > > > > > > because there's no object btnComplete_ServerClick when
    > the
    > > > > script
    > > > > > > > > > function
    > > > > > > > > > > is called...
    > > > > > > > > > >
    > > > > > > > > > > so how do you do it?!?!?
    > > > > > > > > > >
    > > > > > > > > > > thanks.
    > > > > > > > > > > Dan.
    > > > > > > > > > >
    > > > > > > > > > >
    > > > > > > > > >
    > > > > > > > > >
    > > > > > > > >
    > > > > > > > >
    > > > > > > >
    > > > > > > >
    > > > > > >
    > > > > > >
    > > > > >
    > > > > >
    > > > >
    > > > >
    > > >
    > > >
    > >
    > >
    >
    >

    Daniel Bass Guest

Similar Threads

  1. read server side file from clent side
    By sapna30 in forum Macromedia Flash Flashcom
    Replies: 3
    Last Post: February 12th, 11:49 PM
  2. Time Stamp (User Side/Server Side)
    By jtoevs32 in forum Coldfusion - Getting Started
    Replies: 1
    Last Post: July 13th, 09:47 PM
  3. Controls with a client side onLoad function or seting a cursor server side
    By Geoff Davis in forum ASP.NET Building Controls
    Replies: 3
    Last Post: January 15th, 03:54 AM
  4. Replies: 9
    Last Post: October 17th, 07:25 PM
  5. button evet ---- server side - client side ???
    By yaya coco in forum ASP.NET General
    Replies: 1
    Last Post: July 4th, 10:58 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •