473,597 Members | 2,375 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Find out the size of uploaded file on client side

54 New Member
Hi can anyone tell me how to find the size of an uploaded file on client side this should be done without using ActiveX controls
Sep 10 '07 #1
5 2077
acoder
16,027 Recognized Expert Moderator MVP
If the file is already uploaded, the server-side script should have the uploaded file size. How are you uploading the file?
Sep 10 '07 #2
acoder
16,027 Recognized Expert Moderator MVP
Removed "urgent" from the thread title. This makes it less urgent and less likely that someone will answer it.
Sep 10 '07 #3
ramadeviirrigireddy
54 New Member
Removed "urgent" from the thread title. This makes it less urgent and less likely that someone will answer it.

sorry i have'nt noticed that thanks for remaining
Sep 10 '07 #4
ramadeviirrigireddy
54 New Member
If the file is already uploaded, the server-side script should have the uploaded file size. How are you uploading the file?

using jsp servlet the file is uploaded.
Sep 10 '07 #5
acoder
16,027 Recognized Expert Moderator MVP
using jsp servlet the file is uploaded.
The JSP servlet should have code that determines the file size. When the page is loaded, generate Javascript code with a variable which contains the file size.
Sep 10 '07 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

2
3855
by: vishal | last post by:
hi is there anyway that i can check the size of file on client side before uploading file to server???? suppose the user uploads file of 10 mb then the server will know the size is 10 mb after the file is uploaded to server which wastes the bandwidth so what i want to check is that the server first checks the size of file to upload and if it is o.k. then and then only the file will be uploaded..
1
5185
by: Antonie C Malan Snr | last post by:
Dear All, I tried posting this before, but it seems to have disappeared. I need to check image sizes before the user uploads them. This works in the Mozilla family on second and subsequent iterations: if(form.photo1.value != ""){ var piccie = new Image(); piccie.src = "file://" + form.photo1.value;
4
2584
by: msuk | last post by:
All, I have a ASP.NET page using C# to upload a file to a server via the filefield control. I would like to restrict the size of the file a user can upload to say 1mb but would like to check the size of the file on the client computers and not when the file has been uploaded. I am guessing I need to use some client script can someone help me out? Thanks Msuk
12
15651
by: Phil Z. | last post by:
After migrating an ASP.NET 1.1 application to 2.0 we were getting "Cannot access a closed file" errors when uploading. I found a number of post on the subject and have since moved from using an Html File Input control to using the new FileUpload control. Previously, I had set the maxRequestLength attribute in the machine.config file to allow 100MB uploads with success. In the v2.0 application I have added an httpRuntime node to the...
19
9263
by: jeremyz | last post by:
Hi all, I am not a developer, but I work with several and am posting this for them. We are trying to determine whether it is possible to check the size of a file before a user uploads it. Everything I've read suggests that this is impossible (or at least very difficult) in PHP, and this makes sense for a server-side language. What gives me pause, however, is the fact that when a user tries to upload a file larger than the max file...
2
1820
by: asiva | last post by:
I am using <INPUT id="File1" type="file" name="File1" runat="server"to upload file to the server. My Questions: 1. Is it possible to check the file size before the file is uploaded other than using Scripting.FileSystemObject ? 2. If answer to 1 is no, is it possible to check in the server side the Request.ContentLength and prevent the exception/ blank page if the file size
4
1196
by: ramadeviirrigireddy | last post by:
Hi can anyone tell me how to find the size of an uploaded file on client side this should be done without using ActiveX controls
2
2463
by: =?Utf-8?B?TWlrZSBLcmFsZXk=?= | last post by:
In my ASP.NET application, I'd like to set limits on the maximum size of an uploaded file. Normally I'd just set the maxRequestLength of the httpRuntime element in web.config. But in this case, I have a few different aspx pages and I want the limit set differently for each. Yes, I could put each in its own folder, each with its own web.config, but that is rather awkward for this application.
6
2325
by: rodmc | last post by:
Hi, Is there a way to get the size of a file on a remote machine before it is uploaded? I would like to write some form of status counter which is updated as a fie is uploaded, and also to use this feature to prevent files which are too big from being uploaded. Best, rod
0
7959
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8379
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8021
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8254
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
6677
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5421
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
3876
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
3917
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2393
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.