SlickUpload
Welcome Guest Search | Active Topics | Log In | Register

Conflict between ProgressDisplay control and client-side javascript validation Options
cory123
#1 Posted : Thursday, March 20, 2008 10:14:30 AM
Rank: Newbie

Groups: Registered

Joined: 3/20/2008
Posts: 2

We are moving from v2 to v3 and experiencing an issue with the new ProgressDisplay control. Our forms all use client-side javascript validation (in the form onsubmit event). The issue is that the ProgressDisplay control automatically fires before our onsubmit event instead of after (part of the binding to the submit buttons I presume), which basically renders our validation useless. 

My question is: How can i fire my form validation javascript routine for onsubmit prior to the firing of the SlickUpload_Submit() that is added by the ProgressDisplay control?  I would definitely prefer to leave my buttons as submit buttons rather than changing them to type=button and handling this all manually.

ChrisHynes
#2 Posted : Monday, March 24, 2008 7:39:58 PM
Rank: Administration


Groups:

Joined: 7/7/2005
Posts: 1,586
Location: Scottsdale, AZ
You should use the UploadManager control. Set AutoUploadOnPostback to false on the control, and then after your validations are complete, call SlickUpload_Submit() to actually submit the page and start the upload.
cory123
#3 Posted : Thursday, March 27, 2008 10:24:20 AM
Rank: Newbie

Groups: Registered

Joined: 3/20/2008
Posts: 2

There are several file upload fields in this form that need to remain where they are.  In this case, should I be using the ProgressDisplay control for a more customized approach?  The UploadManager control automatically generates a file upload form control that I don't want to appear.  My goal is to have a single progress display for the 4 file upload fields on the form - without moving them and after javascript form validation is run.

Ideally, I could set AutoUploadOnPostBack to false for the ProgressDisplay control, and follow your previous suggestion?  I don't believe this control supports this property, however.

Thanks much!

ChrisHynes
#4 Posted : Thursday, March 27, 2008 11:23:51 AM
Rank: Administration


Groups:

Joined: 7/7/2005
Posts: 1,586
Location: Scottsdale, AZ
Can you email a screenshot of the page in action with a copy of the source and codebehind? That way I can get a better idea of your scenario and suggest the best alternative. chrish at krystalware dot com.
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.