www.webdeveloper.com
Results 1 to 6 of 6

Thread: Server.CreateObject Failed

  1. #1
    Join Date
    Aug 2005
    Posts
    6

    Server.CreateObject Failed

    Any idea why this is happening? The directory exists on the FS. It's an upload script to put files in a database directory. It errors out on the upload.

    Server object error 'ASP 0177 : 800401f3'

    Server.CreateObject Failed

    /ProspectTracking/alphatest/default/Upload/upload.asp, line 3

    800401f3

    SELECT.ASP
    Code:
          <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <html>
    <head>
    
    
    <script language="javascript" type="text/javascript">
    <!--
    function intOnly(i) {
    	if(i.value.length>0) {
    		i.value = i.value.replace(/[^\d]+/g, ''); 
    	}
    }
    //-->
    </script>
    
    <script language="javascript" type="text/javascript">
    <!--
    function inosemi(i) {
    	if(i.value.length>0) {
    		i.value = i.value.replace(/[;]+/g, ''); 
    	}
    }
    //-->
    </script>
    
    <script type="text/javascript">
    
    /***********************************************
    * Disable "Enter" key in Form script- By Nurul Fadilah(nurul@REMOVETHISvolmedia.com)
    * This notice must stay intact for use
    * Visit http://www.dynamicdrive.com/ for full source code
    ***********************************************/
                    
    function handleEnter (field, event) {
    		var keyCode = event.keyCode ? event.keyCode : event.which ? event.which : event.charCode;
    		if (keyCode == 13) {
    			var i;
    			for (i = 0; i < field.form.elements.length; i++)
    				if (field == field.form.elements[i])
    					break;
    			i = (i + 1) % field.form.elements.length;
    			field.form.elements[i].focus();
    			return false;
    		} 
    		else
    		return true;
    	}      
    
    </script>
    	<title></title>
    	<link href="../../../../style.css" rel="stylesheet" type="text/css">
    	<script language="JavaScript" src="../../../../main.js" type="text/javascript"></script>
    
    		
    	</head>
    <body class="content" leftmargin="0" topmargin="0" rightmargin="0" bottommargin="0" marginwidth="0" marginheight="0">
    				<form class="content" action="upload.asp" method="POST" enctype="multipart/form-data">
    			<strong>Select file #1:</strong><br>
    			<input type="file" size="22" name="FILE1">
    			<p><strong>Select file #2:</strong><br>
    				<input type="file" size="22" name="FILE2">
    			
    			<p><strong>Comments:</strong><br>
    				<input type="file" size="22" name="FILE3">
    			<p><strong>Select file #1:</strong><br>
    				<input type="file" size="22" name="FILE4">
    			<p><strong>Select file #2:</strong><br>
    				<input type="file" size="22" name="FILE5">
    			<p><strong>Comments:</strong><br>
    				<input type="file" size="22" name="FILE6">
    			<p><input type="submit" value="Upload!">
    			
    			  
    			
    			</form>
    	</body>
    </html>

    UPLOAD.ASP
    Code:
    <%
    ' Perform the upload
    Set Post = Server.CreateObject("ActiveFile.Post")
    Post.Upload "D:\WWWRoot\SITE.com\database\alphatest"
    
    
    ' Display a summary of the uploaded data
    For Each FormInput In Post.FormInputs
    
        If FormInput.ContentType <> "" Then
            ' Display uploaded file information
            Response.Write FormInput.Name & " = " & FormInput.File.FileName & _
                           ", size=" & FormInput.File.Size & "<BR>"
        Else
            ' Display form element name and value
            Response.Write FormInput.Name & " = " & FormInput.Value & "<BR>"
        End If
    
    Next
    %>
    Last edited by perrywsparrow; 04-12-2006 at 02:02 PM.

  2. #2
    Join Date
    Feb 2006
    Location
    Continental USA
    Posts
    68
    On possible problem is a firewall issue. Server.CreateObject will fail behind a firewall as it invokes MTS which cannot marshall the tx behind a firewall. Change your call to CreateObject instead because it goes straight thru and does not use MTS.

    Master Shake

    {edit} One other thing to check is to make sure you have the proper permissins to use the com object.
    Last edited by Master Shake; 04-12-2006 at 03:22 PM.
    Master Shake
    Question: Lived here all your life? Answer: No, not yet!

  3. #3
    Join Date
    Aug 2005
    Posts
    6
    Permissions are all checked and rechecked so that cant be it. Unless I'm doign somethign drastically wrong that didn't work either.


    <%
    ' Perform the upload
    Set Post = CreateObject("ActiveFile.Post")
    Post.Upload "D:\WWWRoot\Perabus.com\database\alphatest"

    gives...

    Microsoft VBScript runtime error '800a01ad'

    ActiveX component can't create object: 'ActiveFile.Post'

  4. #4
    Join Date
    Feb 2006
    Location
    Continental USA
    Posts
    68
    Not certain what is up with that. Only thing I can think of is to try and find an answer here:
    http://support.microsoft.com/kb/q194801/

    Good Luck!

    Master Shake
    Master Shake
    Question: Lived here all your life? Answer: No, not yet!

  5. #5
    Join Date
    Aug 2012
    Posts
    1
    Can you try making it work in VB.net ?

  6. #6
    Join Date
    Jan 2008
    Location
    Florida
    Posts
    1,227
    Guess I'm pointing out the obvious but have you verified the component is installed?

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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



Recent Articles