Welcome Guest! You need to login or register to make posts.

Notification

Icon
Error

Options
Go to last post Go to first unread
Andy_r_k  
#1 Posted : Tuesday, August 7, 2007 6:50:08 AM(UTC)
Andy_r_k

Rank: Member

Groups: Member
Joined: 8/7/2007(UTC)
Posts: 7

Hi There

I've encountered an issue running Image Uploader 4.5 on Firefox for PC and Safari for Mac. Everything works well but when uploading gets to the end the progress bar window displays the message 'Waiting for response from server' followed by a message window with the following message 'Image Uploader encountered some problem.....' . Image uploader works ok with IE7. The error dump is:
The server threw an exception.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.Runtime.InteropServices.COMException: The server threw an exception. Source Error:

Code:
Line 41: 	aurigma = Request.Form("aurigma")
Line 42:       
Line 43: 	IPTCInfo.SetField(7, approved)Line 44:         IPTCInfo.SetField(219, username)
Line 45:   
 Source File: C:\www\FW1\aurigmauploader\uploadfw.aspx    Line: 43  Stack Trace:  

[COMException (0x80010105): The server threw an exception.]
   FOTOWEB.IPTCBlockClass.SetField(Int32 FieldNumber, String Value) +0
   ASP.Uploadfw_aspx.Page_Load(Object sender, EventArgs e) in C:\www\FW1\aurigmauploader\uploadfw.aspx:43
   System.Web.UI.Control.OnLoad(EventArgs e) +67
   System.Web.UI.Control.LoadRecursive() +35
   System.Web.UI.Page.ProcessRequestMain() +750
  Version Information: Microsoft .NET Framework Version:1.1.4322.2407; ASP.NET Version:1.1.4322.2407


Can anyone help? Thanks

Andy

Edited by user Monday, December 17, 2007 1:04:28 PM(UTC)  | Reason: Not specified

Eugene Kosmin  
#2 Posted : Sunday, August 12, 2007 8:16:33 PM(UTC)
Eugene Kosmin

Rank: Advanced Member

Groups: Member, Administration, Moderator
Joined: 9/19/2006(UTC)
Posts: 438

Was thanked: 22 time(s) in 22 post(s)
Hello Andy,

As I guess, this is an upload script error, right? Upload POSTs from ActiveX and Java versions are not exactly the same due to different reasons.

So, try this:

1. Using our helper scripts, save upload contents from both uploaders into files.
2. Check the difference. Maybe there will be significant syntax distinctions, missing post data or anything else.

Edited by user Monday, February 25, 2008 4:20:26 PM(UTC)  | Reason: Not specified

Best regards,
Eugene Kosmin.
Aurigma Development Team
Andy_r_k  
#3 Posted : Wednesday, August 29, 2007 9:46:49 PM(UTC)
Andy_r_k

Rank: Member

Groups: Member
Joined: 8/7/2007(UTC)
Posts: 7

Hi Eugene,

I can't figure out what i need to change. So far I have been using the activex version and it has worked fine. I have only just started using the Java version. I would be grateful if you can point out to me what I need to change.

Here's my code for the HTML page and ASPX page:

HTML:

Code:
	
<script type="text/javascript">
//<![CDATA[

//Create JavaScript object that will embed Image Uploader to the page.
var iu = new ImageUploaderWriter("ImageUploader1", 620, 380);

// If you do not want to use ActiveX or Java version, set the appropriate
// property to false.
iu.activeXControlEnabled = true;
iu.javaAppletEnabled = true;

//For ActiveX control full path to CAB file (including file name) should be specified.
iu.activeXControlCodeBase = "/fotoweb/ImageUploader4.cab";
iu.activeXControlVersion = "4,5,4,0";

//For Java applet only path to directory with JAR files should be specified (without file name).
iu.javaAppletCodeBase = "/fotoweb/";
iu.javaAppletCached = true;
iu.javaAppletVersion = "2.5.4.0";

iu.addParam("LicenseKey", "xxxx-xxxx-xxxx");

iu.showNonemptyResponse = "off";

iu.addParam("MaxFileCount", "20");
iu.addParam("MaxTotalFileSize", "52428800");
iu.addParam("MessageMaxTotalFileSizeExceededText", "You are not allowed to upload more than 50 MB at a time.");


//Configure appearance.
iu.addParam("PaneLayout", "TwoPanes");
iu.addParam("ShowDebugWindow", "true");
iu.addParam("AllowRotate", "true");
iu.addParam("BackgroundColor", "#ffffff");
iu.addParam("TreePaneWidth", "205");

iu.addParam("Action", "http://www.xxx.co.uk/aurigmauploader/uploadfw.aspx");

//Configure upload settings.
iu.addParam("FilesPerOnePackageCount", "1");
iu.addParam("AutoRecoverMaxTriesCount", "0");
iu.addParam("AutoRecoverTimeOut", "10000");
iu.addParam("AllowAutoRotate", "false");
iu.addParam("AllowRotate", "false");
iu.addParam("TimeOut", "3600000"); // This equals 1 hour
iu.addParam("FolderPaneShowDescriptions", "false");
iu.addParam("AdditionalFormName", "Form1");

//Configure file mask to upload JPEG images only.
iu.addParam("FileMask", "*.jpg;*.jpeg;*.jpe;*.tif;*.tiff");

//Add event handlers.
iu.addEventListener("UploadFileCountChange", "ImageUploader_UploadFileCountChange");
iu.addEventListener("ViewChange", "ImageUploader_ViewChange");
iu.fullPageLoadListenerName = "fullPageLoad";

//Configure URL where to redirect after upload.
//iu.addParam("RedirectUrl", "/fotoweb/manage.fwx?rows=2&columns=3");


//Tell Image Uploader writer object to generate all necessary HTML code to embed 
//Image Uploader to the page.
iu.writeHtml();
//]]>
	</script>


	<form id="form1" name="form1">
	<input type="hidden" name="accesstoken" value="<%$ CreateUploadAccessToken /%>" />
	<input type="hidden" name="username" value="" />
	<input type="hidden" name="password" value="" />
	<input type="hidden" name="uploadsuccess" value="Yes" />
	<input type="hidden" name="user" value="<%$=currentUser.userName %>" />
	<input type="hidden" name="aurigma" value="Yes" />
	<input type="hidden" name="approved" value="approved" />
</form>



ASPX:

Code:

<%@ Page Language="vb" AutoEventWireup="false" %>
<%@ Import Namespace="System.IO" %>
<%@ Import Namespace="System.Data" %>
<%@ Import Namespace="FOTOWEB" %>

<script language="VB" runat="server">





'file upload post


'This variable specifies a relative path to the folder, where temp images is located.
Private strGalleryPath = "filez/"
'This is where CF will pick up files for processing
Private strCFPath = "CF/"

Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load


Dim uniqueDir as String
	'	uniqueDir = System.Guid.NewGuid().ToString()
	
	
	Dim filenames As String
        
        Dim y() As String
        Dim a As Short

       
	Dim username, approved, aurigma As String	
	Dim IPTCInfo As New FOTOWEB.IPTCBlock()
        Dim imageInfo As New FOTOWEB.ImageInformationCache()
        Dim imageIPTC As FOTOWEB.ImageInformation
		
	username = Request.Form("user")
	approved = Request.Form("approved")
	'response.write(approved)
	aurigma = Request.Form("aurigma")
      
	IPTCInfo.SetField(7, approved)
        IPTCInfo.SetField(219, username)
  
	
		'IPTCInfo.SetField(210, System.Guid.NewGuid().ToString())
         
Dim MyFileInfo As FileInfo
	Dim MyDirectory As DirectoryInfo
	'MyDirectory = New DirectoryInfo(Server.MapPath(strGalleryPath))
	'For Each MyFileInfo In MyDirectory.GetFiles
'		MyFileInfo.Delete
'	Next	
	
	'Create GUID Directory
	'Dim ud As DirectoryInfo = Directory.CreateDirectory(Server.MapPath(strGalleryPath) & "/" & uniqueDir)

	Dim SourceFile As HttpPostedFile


	Dim fileCount As Integer = Int32.Parse(Request.Form("FileCount"))


	'iterate through the uploaded files and save them and iptc data
	For i As Integer = 1 To fileCount

		'Get source image and save it to disk
		SourceFile = Request.Files("SourceFile_" & I)
		Dim strFileName As String = Path.GetFileName(SourceFile.FileName)
'response.write(SourceFile.FileName)
		'Check whether file with such name already exists and if so,
	  	'construct safe filename name (to avoid collision)
		Dim strNewFileName As String = strFileName
		Dim J As integer = 1
		While File.Exists(Server.MapPath(strGalleryPath & "/" & strNewFileName))
			strNewFileName = J & "_" & strFileName
			J = J + 1
		End While
		strFileName = strNewFileName
		'save the file on server
'CHECK FILE IS THERE

		SourceFile.SaveAs (Server.MapPath(strGalleryPath & "/"  & strFileName))
		'add iptc data to file
		imageInfo.SaveImageText(Server.MapPath(strGalleryPath & "/"  & strFileName), IPTCInfo)
		'move files / directory into CF channel
		File.Move(Server.MapPath(strGalleryPath & "/"  & strFileName), server.MapPath(strCFPath & strFileName))

'END CHECK FILE IS THERE
	Next
	SourceFile = Nothing
	imageInfo = Nothing

End Sub
</script>

	

Edited by user Tuesday, February 12, 2008 2:18:35 PM(UTC)  | Reason: Not specified

Eugene Kosmin  
#4 Posted : Thursday, August 30, 2007 4:29:29 PM(UTC)
Eugene Kosmin

Rank: Advanced Member

Groups: Member, Administration, Moderator
Joined: 9/19/2006(UTC)
Posts: 438

Was thanked: 22 time(s) in 22 post(s)
Replace this
Code:
iu.addParam("AdditionalFormName", "Form1");
for
Code:
iu.addParam("AdditionalFormName", "form1");
Additional form data doesn’t send because of different form names.

Edited by user Monday, February 25, 2008 4:22:52 PM(UTC)  | Reason: Not specified

Best regards,
Eugene Kosmin.
Aurigma Development Team
Andy_r_k  
#5 Posted : Thursday, August 30, 2007 6:58:52 PM(UTC)
Andy_r_k

Rank: Member

Groups: Member
Joined: 8/7/2007(UTC)
Posts: 7

Hi,

I have tried that and changed from "Form1" to "form1" but it still doesn't work. Is something done differently when using an additional form with the java version. As I said the activex version is working fine in IE7, problem is just with the java version not posting the additional form data.
Andy_r_k  
#6 Posted : Thursday, August 30, 2007 8:16:25 PM(UTC)
Andy_r_k

Rank: Member

Groups: Member
Joined: 8/7/2007(UTC)
Posts: 7

This problem does happen on Firefox 1.5 but only on the latest 2.0.0.x

Is this a compatiblity issue between aurigma java uploader and firefox 2.0.0.x? If so what is the estimated time for a fix?

* What is the version of Image Uploader?
Java 2.5.4.0

* Which OS were you using, when the problem occurred?
Windows XP

* Which browser were you using?
Firefox 2.0.0.4

* Was the problem reproducible? On which machines you were able to reproduce it?
Yes, on all machines such as PC and MAC running firefox.

* Does Image Uploader still work when you try our samples (both online and local)?
no
Eugene Kosmin  
#7 Posted : Thursday, August 30, 2007 8:47:42 PM(UTC)
Eugene Kosmin

Rank: Advanced Member

Groups: Member, Administration, Moderator
Joined: 9/19/2006(UTC)
Posts: 438

Was thanked: 22 time(s) in 22 post(s)
Could you give us the direct link to your page with Image Uploader and java console dump?
Best regards,
Eugene Kosmin.
Aurigma Development Team
Andy_r_k  
#8 Posted : Thursday, August 30, 2007 10:37:20 PM(UTC)
Andy_r_k

Rank: Member

Groups: Member
Joined: 8/7/2007(UTC)
Posts: 7

Hi Eugene,

I have PM'd you the URL. You can try it in both IE7 and Firefox 2.0.0.4

Here's the java console dump:

Code:
Aurigma ImageUploader version: 2.5.4.0
Current document URL: http://www.xxx.co.uk/fotoweb/upload_ftp.fwx?username=aurigma&password=test
Reading cookies
Cookies: FWFV=Fri, 13 Jul 2007 13:48:50 GMT; FWSession=1c511ce1b622eb126fef80e7edfc4131; fwAuthCookie=3720EAEFFBDEEEB45C83DB1F7FD300637AB05385C9070CFB611AB9505D7B52AA7C3785717EAB2931; FWToken=
Reading referer
Referer: http://www.xxx.co.uk/fotoweb/upload_ftp.fwx?username=aurigma&password=test
Reading additional form content
Additional form processing done
Uploading to http://www.xxx.co.uk/aurigmauploader/uploadfw.aspx
Setting HTTP params: Host=www.xxx.co.uk
Starting upload
Status =[500]
UploadException occured
/ by zero
###Error occured###
Status=[ERROR]
Progress=[0]
ValueMax=[0]
Value=[4]
[ErrorPage]
<html>
    <head>
        <title>The server threw an exception.</title>
        <style>
        	body {font-family:"Verdana";font-weight:normal;font-size: .7em;color:black;} 
        	p {font-family:"Verdana";font-weight:normal;color:black;margin-top: -5px}
        	b {font-family:"Verdana";font-weight:bold;color:black;margin-top: -5px}
        	H1 { font-family:"Verdana";font-weight:normal;font-size:18pt;color:red }
        	H2 { font-family:"Verdana";font-weight:normal;font-size:14pt;color:maroon }
        	pre {font-family:"Lucida Console";font-size: .9em}
        	.marker {font-weight: bold; color: black;text-decoration: none;}
        	.version {color: gray;}
        	.error {margin-bottom: 10px;}
        	.expandable { text-decoration:underline; font-weight:bold; color:navy; cursor:hand; }
        </style>
    </head>

    <body bgcolor="white">

            <span><H1>Server Error in '/aurigmauploader' Application.<hr width=100% size=1 color=silver></H1>

            <h2> <i>The server threw an exception.</i> </h2></span>

            <font face="Arial, Helvetica, Geneva, SunSans-Regular, sans-serif ">

            <b> Description: </b>An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

            



            <b> Exception Details: </b>System.Runtime.InteropServices.COMException: The server threw an exception.



            <b>Source Error:</b> 



            <table width=100% bgcolor="#ffffcc">
               <tr>
                  <td>
                      <code><pre>

Line 41: 	aurigma = Request.Form(&quot;aurigma&quot;)
Line 42:       
<font color=red>Line 43: 	IPTCInfo.SetField(7, approved)
</font>Line 44:         IPTCInfo.SetField(219, username)
Line 45:   </pre></code>

                  </td>
               </tr>
            </table>

            


            <b> Source File: </b> C:\www\FW1\aurigmauploader\uploadfw.aspx<b>  Line: </b> 43
            



            <b>Stack Trace:</b> 



            <table width=100% bgcolor="#ffffcc">
               <tr>
                  <td>
                      <code><pre>

[COMException (0x80010105): The server threw an exception.]
   FOTOWEB.IPTCBlockClass.SetField(Int32 FieldNumber, String Value) +0
   ASP.Uploadfw_aspx.Page_Load(Object sender, EventArgs e) in C:\www\FW1\aurigmauploader\uploadfw.aspx:43
   System.Web.UI.Control.OnLoad(EventArgs e) +67
   System.Web.UI.Control.LoadRecursive() +35
   System.Web.UI.Page.ProcessRequestMain() +750
</pre></code>

                  </td>
               </tr>
            </table>

            


            <hr width=100% size=1 color=silver>

            <b>Version Information:</b>Microsoft .NET Framework Version:1.1.4322.2407; ASP.NET Version:1.1.4322.2407

            </font>

    </body>
</html>
<!-- 
[COMException]: The server threw an exception.
   at FOTOWEB.IPTCBlockClass.SetField(Int32 FieldNumber, String Value)
   at ASP.Uploadfw_aspx.Page_Load(Object sender, EventArgs e) in C:\www\FW1\aurigmauploader\uploadfw.aspx:line 43
   at System.Web.UI.Control.OnLoad(EventArgs e)
   at System.Web.UI.Control.LoadRecursive()
   at System.Web.UI.Page.ProcessRequestMain()
[HttpUnhandledException]: Exception of type System.Web.HttpUnhandledException was thrown.
   at System.Web.UI.Page.HandleError(Exception e)
   at System.Web.UI.Page.ProcessRequestMain()
   at System.Web.UI.Page.ProcessRequest()
   at System.Web.UI.Page.ProcessRequest(HttpContext context)
   at System.Web.CallHandlerExecutionStep.System.Web.HttpApplication+IExecutionStep.Execute()
   at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
--><!-- 
This error page might contain sensitive information because ASP.NET is configured to show verbose error messages using &lt;customErrors mode="Off"/&gt;. Consider using &lt;customErrors mode="On"/&gt; or &lt;customErrors mode="RemoteOnly"/&gt; in production environments.-->
[EndOfErrorPage]


Edited by user Monday, December 17, 2007 1:14:31 PM(UTC)  | Reason: Not specified

Andy_r_k  
#9 Posted : Friday, August 31, 2007 8:01:45 AM(UTC)
Andy_r_k

Rank: Member

Groups: Member
Joined: 8/7/2007(UTC)
Posts: 7

Hi Eugene

Just a quick note to inform you that the form data is not being posted using any Java enabled browser. So works ok with IE6 & IE7 but not using Firefox, Opera and Safari for Windows XP nor with Firefox and Safari for MAC OSX10.3. The code looks ok so we are wondering if the issue is on the server side or with the server operating system which is Windows 2003 SP2.

It's the first time we are using Image Uploader with Java enabled browsers so we might be looking for an obvious error.

Andy
Eugene Kosmin  
#10 Posted : Sunday, September 2, 2007 12:34:34 PM(UTC)
Eugene Kosmin

Rank: Advanced Member

Groups: Member, Administration, Moderator
Joined: 9/19/2006(UTC)
Posts: 438

Was thanked: 22 time(s) in 22 post(s)
Hello Andy,

Try to remove event handlers from your IU page:
Code:
//Add event handlers.
iu.addEventListener("UploadFileCountChange", "ImageUploader_UploadFileCountChange");
iu.addEventListener("ViewChange", "ImageUploader_ViewChange");
iu.fullPageLoadListenerName = "fullPageLoad";

Edited by user Monday, February 25, 2008 4:23:07 PM(UTC)  | Reason: Not specified

Best regards,
Eugene Kosmin.
Aurigma Development Team
Andy_r_k  
#11 Posted : Sunday, September 2, 2007 6:10:45 PM(UTC)
Andy_r_k

Rank: Member

Groups: Member
Joined: 8/7/2007(UTC)
Posts: 7

HI Eugene

I have removed the code as advised and tested application OK. I will comprehensively check behaviour using all browers next but already looks very promising. Thank you.

Andy

:)
Eugene Kosmin  
#12 Posted : Sunday, September 2, 2007 8:37:01 PM(UTC)
Eugene Kosmin

Rank: Advanced Member

Groups: Member, Administration, Moderator
Joined: 9/19/2006(UTC)
Posts: 438

Was thanked: 22 time(s) in 22 post(s)
You are welcome.
Best regards,
Eugene Kosmin.
Aurigma Development Team
Oliver  
#13 Posted : Thursday, September 6, 2007 7:23:01 PM(UTC)
Oliver

Rank: Member

Groups: Member
Joined: 6/22/2006(UTC)
Posts: 3

Hi

I'm having the same problem; however, it only seems to affect Firefox on the Mac. No problem using IE5, 6, 7 or FireFox on PC or even Safari on Mac.

I have removed all the event handlers as mentioned in the previous post but with no luck, does anyone have any other suggestions?

Thanks

Oliver
Users browsing this topic
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.