Error when instantiating a Com( EXCEL.APPLICATION) object in WINDOWS XP
Hi,
I am using coldfusion MX7 and OS is WindowXP. I am using COM
object with Excel.Application for my program. but it is giving the
below error. But same program is working in Window Profesional.
ERROR IS:
An exception occurred when instantiating a Com object.
The cause of this exception was that: AutomationException:
0x80080005 - Server execution failed. Note that Windows 95 does not
support automatic launch of a server, it must be running already.
The error occurred in
C:\CFusionMX7\wwwroot\XXX\report_top20.cfm: line 15
13 : t1=now();
14 : path=GetDirectoryFromPath(ExpandPath("*.*"));
15 : xl=CreateObject("COM", "Excel.Application");
16 : wbks=xl.workbooks;
17 : tmp=wbks.open(path & "top20_template.xls");
Plz help me.
Reagrds,
DRA.
Hi,
If possible, would you please share your Excel file with us, you can upload it to a file sharing site(Like OneDrive), and then share the link with us. Also please take a look of this article:
http://support.microsoft.com/kb/178510
For the warning message, It means that in Excel 2010 and Excel 2007, you can use special effects, such as transparent shadows that are not supported in Excel 97-2003. The special effects will be removed. In the Compatibility Checker, click
Find to locate the objects that have special effects applied so that you can remove those effects as needed.
Wind Zhang
TechNet Community Support
Similar Messages
-
Cfobject - An exception occurred when instantiating a COM object
I'm getting the following error:
An exception occurred when instantiating a COM object.
The cause of this exception was that: java.lang.RuntimeException: Can not use native code: Initialisation failed.
1 :
2 : <cfscript>
3 : oLoader = CreateObject("com", "easyPDF.Loader.6");
4 : </cfscript>
This is on a dedicated server with 64bit Windows Server 8 and 64bit ColdFusion 9. easyPDF is a program that will convert files into PDF on the server, it is also the 64 bit version.
I'm not even trying to do anything but load the object and am getting the error. I took a peek inside the registry and searched for "easyPDF.Loader" and it was found.
Any ideas what could be going wrong? Is there something I need to do with the CF setup or IIS to get this working? It gives the same error with the following line of code as well.
<cftry>
<cfobject type="com" action="connect" class="Word.application" name="this.wordCom" context="local">
<cfcatch>
<cfobject type="com" action="create" class="Word.application" name="this.wordCom" context="local">
</cfcatch>
</cftry>
Any help or guidance would be great. Is there a basic <cfobject type="com"> that should work on ANY computer without installing something that I could use to test?
Thanks!Just to give everyone some closure in this matter:
I've opened a case with Adobe Support. Their reply was:
COM interoperability with CF9 is not supported on 64 bit Windows OS. This is due to the limitations imposed by JIntergra. You can find a reference for this in the following tech-note:http://helpx.adobe.com/coldfusion/kb/coldfusion-limitations-running-coldfusion-64.html
It seems that J-Integra (http://j-integra.intrinsyc.com/support/kb/article.aspx?id=30963) won't update their code libraries for 64-bit support due to lack of customer demand for this functionality. Mind you this is the newest technot I could find on the matter but it was last update in 2010. I've also emailed j-Integra sales (http://j-integra.intrinsyc.com/contact.asp) to inquire about any progress in porting over their libraries to 64-bit. Who knows, if they get enough requests...
I will now try to access my COM libraries from a .NET dll and call it using cfexecute. -
An exception occurred when instantiating a COM object
I have installed ColdFusion 9.1 on a 64-bit server running Windows 2008 R2. I am using IIS 7.5.
When I try to access the following URL http://localhost/myhousing/security/login_admin.cfm I get the following error. Is there a patch available for CF 9 to resolve this error?
The web site you are accessing has experienced an unexpected error.
Please contact the website administrator.
The following information is meant for the website developer for debugging purposes.
Error Occurred While Processing Request
An exception occurred when instantiating a COM object.
The cause of this exception was that: java.lang.RuntimeException: Can not use native code: Initialisation failed.
The error occurred in C:/inetpub/wwwroot/MyHousing/Application.cfm: line 22
20 : <CFINCLUDE template="lib/housing_functions.cfm">
21 : <CFSET Application.obj_name = "UserInfo325DLL.UserClass">
22 : <CFOBJECT name="obj" action="create" type="com" class="#Application.obj_name#">
23 : <!------------------------------------------------------------------->
24 : <!--- END OF CONFIGURATION FILE --->
Resources:
Check the ColdFusion documentation to verify that you are using the correct syntax.
Search the Knowledge Base to find a solution to your problem.
Browser Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64; Trident/5.0)
Remote Address ::1
Referrer
Date/Time 08-May-13 01:49 PM
Stack Trace (click to expand)
at cfApplication2ecfm293894775.runPage(C:/inetpub/wwwroot/MyHousing/Application.cfm:22) at cfApplication2ecfm293894775.runPage(C:/inetpub/wwwroot/MyHousing/Application.cfm:22)
java.lang.RuntimeException: Can not use native code: Initialisation failed
at com.linar.jintegra.NativeObjRef.<init>(Unknown Source)
at com.linar.jintegra.Dispatch.createDispatch(Unknown Source)
at com.linar.jintegra.Dispatch.<init>(Unknown Source)
at com.intrinsyc.typeInfo.IMacroViewerProxy.<init>(IMacroViewerProxy.java:32)
at com.intrinsyc.typeInfo.MacroViewer.<init>(MacroViewer.java:90)
at com.intrinsyc.typeInfo.MacroViewer.<init>(MacroViewer.java:69)
at com.intrinsyc.typeInfo.InterfaceInfoFactory.getInfoGivenPROGID(InterfaceInfoFactory.java: 50)
at coldfusion.runtime.com.ComProxy.<init>(ComProxy.java:114)
at coldfusion.runtime.com.ComProxyFactory.getProxy(ComProxyFactory.java:41)
at coldfusion.runtime.ProxyFactory.getProxy(ProxyFactory.java:65)
at coldfusion.runtime.CFPage.createObjectProxy(CFPage.java:4947)
at coldfusion.tagext.lang.ObjectTag.doStartTag(ObjectTag.java:427)
at coldfusion.runtime.CfJspPage._emptyTcfTag(CfJspPage.java:2722)
at cfApplication2ecfm293894775.runPage(C:\inetpub\wwwroot\MyHousing\Application.cfm:22)
at coldfusion.runtime.CfJspPage.invoke(CfJspPage.java:231)
at coldfusion.tagext.lang.IncludeTag.doStartTag(IncludeTag.java:416)
at coldfusion.filter.CfincludeFilter.invoke(CfincludeFilter.java:65)
at coldfusion.filter.CfincludeFilter.include(CfincludeFilter.java:33)
at coldfusion.filter.ApplicationFilter.invoke(ApplicationFilter.java:279)
at coldfusion.filter.RequestMonitorFilter.invoke(RequestMonitorFilter.java:48)
at coldfusion.filter.MonitoringFilter.invoke(MonitoringFilter.java:40)
at coldfusion.filter.PathFilter.invoke(PathFilter.java:94)
at coldfusion.filter.ExceptionFilter.invoke(ExceptionFilter.java:70)
at coldfusion.filter.ClientScopePersistenceFilter.invoke(ClientScopePersistenceFilter.java:2 8)
at coldfusion.filter.BrowserFilter.invoke(BrowserFilter.java:38)
at coldfusion.filter.NoCacheFilter.invoke(NoCacheFilter.java:46)
at coldfusion.filter.GlobalsFilter.invoke(GlobalsFilter.java:38)
at coldfusion.filter.DatasourceFilter.invoke(DatasourceFilter.java:22)
at coldfusion.filter.CachingFilter.invoke(CachingFilter.java:62)
at coldfusion.CfmServlet.service(CfmServlet.java:200)
at coldfusion.bootstrap.BootstrapServlet.service(BootstrapServlet.java:89)
at jrun.servlet.FilterChain.doFilter(FilterChain.java:86)
at coldfusion.monitor.event.MonitoringServletFilter.doFilter(MonitoringServletFilter.java:42 )
at coldfusion.bootstrap.BootstrapFilter.doFilter(BootstrapFilter.java:46)
at jrun.servlet.FilterChain.doFilter(FilterChain.java:94)
at jrun.servlet.FilterChain.service(FilterChain.java:101)
at jrun.servlet.ServletInvoker.invoke(ServletInvoker.java:106)
at jrun.servlet.JRunInvokerChain.invokeNext(JRunInvokerChain.java:42)
at jrun.servlet.JRunRequestDispatcher.invoke(JRunRequestDispatcher.java:286)
at jrun.servlet.ServletEngineService.dispatch(ServletEngineService.java:543)
at jrun.servlet.jrpp.JRunProxyService.invokeRunnable(JRunProxyService.java:203)
at jrunx.scheduler.ThreadPool$DownstreamMetrics.invokeRunnable(ThreadPool.java:320)
at jrunx.scheduler.ThreadPool$ThreadThrottle.invokeRunnable(ThreadPool.java:428)
at jrunx.scheduler.ThreadPool$UpstreamMetrics.invokeRunnable(ThreadPool.java:266)
at jrunx.scheduler.WorkerThread.run(WorkerThread.java:66)Let's narrow down the problem by substituting the variable with the value directly on the cfobject tag.
<CFOBJECT name="obj" action="create" type="com" class="UserInfo325DLL.UserClass">
... and see if that works.
Another thing you might want to check if this is correct, UserInfo325DLL.UserClass. -
I need to get the Excel.application object from a window handle using AccessibleObjectFromWindow. I can't seem to make the code work. First, I successfully search for the XLMAIN windows. Then, when I get a handle, I execute the AccessibleObjectFromWindow
function. It seems to return a value of -2147467262 in all cases. Therefore, I believe that it is returning an error value. I can't figure out how to determine the meaning of this value.
If it is an error value, I believe that one or more arguments are in error. My best guess at present is that the GUID argument is incorrect. I have tried two GUID values: {00020400-0000-0000-C000-000000000046} and {90140000-0016-0409-0000-0000000FF1CE}.
I have seen both used in conjunction with OBJID_NATIVEOM. Neither one seems to work. I really would prefer not to use the second one as it has an Excel major and minor version number. I would hate to have to change this code, if a new minor version appeared.
The attached code has been commented to show which parts have been shown to work and which not. I'm at my wits end and really need help.
Thanks
'This module is located in Access 2010, but this is an Excel question.
Option Compare Database
Option Explicit
' Module-Level Declarations
'The GetDesktopWindow function and FindWindowEx function work just fine.
Public Declare Function GetDesktopWindow Lib "user32" () As Long
Public Declare Function FindWindowEx Lib "user32" Alias "FindWindowExA" _
(ByVal hWnd1 As Long, _
ByVal hWnd2 As Long, _
ByVal lpsz1 As String, _
ByVal lpsz2 As String) _
As Long
'I'm not getting the expected output from this function (see below)
Private Declare Function AccessibleObjectFromWindow& Lib "oleacc.dll" _
(ByVal hwnd&, _
ByVal dwId&, _
riid As GUID, _
xlwb As Object)
Type GUID
lData1 As Long
iData2 As Integer
iData3 As Integer
aBData4(0 To 7) As Byte
End Type
Function ExcelInstances() As Long
' Procedure-Level Declarations
' Value of OBJID_NATIVEOM verified by checking list of Windows API constants _
on this site: http://www.lw-tech.com/q1/base.htm
Const OBJID_NATIVEOM = &HFFFFFFF0
Dim hWndDesk As Long 'Desktop window
Dim hWndXL As Long 'Child window
Dim objExcelApp As Object 'Final result wanted: Excel application object
'Following variable (xlapp) to be set by AccessibleObjectFromWindow function
Dim xlapp As Object
Dim IDispatch As GUID 'GUID used in call to AccessibleObjectFrom Window function
'Set up GUID to be used for all instances of Excel that are found
Dim tmp1 As Variant 'Return value from AccessibleObjectFromWindow
' Executable Statements
SetIDispatch IDispatch
IDispatch = IDispatch
'Get a handle to the desktop
hWndDesk = GetDesktopWindow 'This seems to work
Do
'Get the next Excel window
'The following statement seems to work. We are finding and counting _
correctly all the instances of Excel. hWndXL is non-zero for each _
instance of Excel
hWndXL = FindWindowEx(GetDesktopWindow, hWndXL, "XLMAIN", vbNullString)
'If we got one, increment the count
If hWndXL > 0 Then
'This works. We correctly count all _
instances of Excel
ExcelInstances = ExcelInstances + 1
'Here is the problem. The following statement executes and returns a value of _
-2147467262. xlapp, which is passed by reference to AccessibleObjectFromWindow, _
is set to nothing. It should be set to the object for Excel.application. _
I believe that this value is not an object. I tried to reference tmp1. in the _
immediate window. There was no Intellisense.
'I think that the function in returning an error value, but I can't figure _
out what it is. I believe that AccessibleObjectFromWindow returns error _
values, but I don't know where to find their values so I can interpret the _
function's results.
'As best I can tell, the hWndXL parameter is correct. It is the handle for _
an instance of Excel. OBJID_NATIVEOM is set correctly (see constant declaration _
above). xlapp is passed by reference as a non-initialized object variable, which _
will be set by AccessiblObjectFromWindow. IDispatch may be the problem. It is set _
as shown below in the procedure SetIDispatch(ByRef ID As GUID). This procedure _
appears to work. I can see that IDispatch is set as I intended and correctly _
passed to AccessibleObjectFromWindow.
tmp1 = AccessibleObjectFromWindow(hWndXL, OBJID_NATIVEOM, IDispatch, xlapp)
'Need to write code to test tmp1 for error. If none, then set objExcelApp = _
object. Also, I exect xlapp to be set to Excel.application
End If
'Loop until we've found them all
Loop Until hWndXL = 0
End Function
Private Sub SetIDispatch(ByRef ID As GUID)
'Defines the IDispatch variable. The interface _
ID is {90140000-0016-0409-0000-0000000FF1CE}.
'NOT USING {00020400-0000-0000-C000-000000000046}, _
which could be the problem
'9 is release version - first version shipped (initial release)
'0 is release type - retail/oem
'14 is major version
'0000 is minor version
'0016 is product ID - MS Excel 2010
'0409 is language identifier - English
'0 is x86 or x64 - this is x86
'000 reserved
'0 is debug/ship
'000000FF1CE is office family ID
With ID
.lData1 = &H90140000
.iData2 = &H16
.iData3 = &H409
.aBData4(0) = &H0
.aBData4(1) = &H0
.aBData4(2) = &H0
.aBData4(3) = &H0
.aBData4(4) = &H0
.aBData4(5) = &HF
.aBData4(6) = &HF1
.aBData4(7) = &HCE
End With
End Sub
DaveInCalabasasI don't think you can return a reference to Excel's main window like that as you are attempting to do.
Ref:
http://msdn.microsoft.com/en-us/library/windows/desktop/dd317978(v=vs.85).aspx
It's relatively straightforward to return any workbook's window in any given instance, and in turn it's parent Excel app. Try the following and adapt as required (and include error handling) -
Option Explicit
Private Declare Function FindWindowEx Lib "User32" Alias "FindWindowExA" _
(ByVal hWnd1 As Long, ByVal hWnd2 As Long, ByVal lpsz1 As String, _
ByVal lpsz2 As String) As Long
Private Declare Function IIDFromString Lib "ole32" _
(ByVal lpsz As Long, ByRef lpiid As GUID) As Long
Private Declare Function AccessibleObjectFromWindow Lib "oleacc" _
(ByVal hWnd As Long, ByVal dwId As Long, ByRef riid As GUID, _
ByRef ppvObject As Object) As Long
Private Type GUID
Data1 As Long
Data2 As Integer
Data3 As Integer
Data4(7) As Byte
End Type
Private Const S_OK As Long = &H0
Private Const IID_IDispatch As String = "{00020400-0000-0000-C000-000000000046}"
Private Const OBJID_NATIVEOM As Long = &HFFFFFFF0
Sub test()
Dim i As Long
Dim hWinXL As Long
Dim xlApp As Object ' Excel.Application
Dim wb As Object ' Excel.Workbook
hWinXL = FindWindowEx(0&, 0&, "XLMAIN", vbNullString)
While hWinXL > 0
i = i + 1
Debug.Print "Instance_" & i; hWinXL
If GetXLapp(hWinXL, xlApp) Then
For Each wb In xlApp.Workbooks
Debug.Print , wb.Name
Next
End If
hWinXL = FindWindowEx(0, hWinXL, "XLMAIN", vbNullString)
Wend
End Sub
'Function GetXLapp(hWinXL As Long, xlApp As Excel.Application) As Boolean
Function GetXLapp(hWinXL As Long, xlApp As Object) As Boolean
Dim hWinDesk As Long, hWin7 As Long
Dim obj As Object
Dim iid As GUID
Call IIDFromString(StrPtr(IID_IDispatch), iid)
hWinDesk = FindWindowEx(hWinXL, 0&, "XLDESK", vbNullString)
hWin7 = FindWindowEx(hWinDesk, 0&, "EXCEL7", vbNullString)
If AccessibleObjectFromWindow(hWin7, OBJID_NATIVEOM, iid, obj) = S_OK Then
Set xlApp = obj.Application
GetXLapp = True
End If
End Function
Note as written if an instance does not have any loaded workbooks a reference will not be returned (though a workbook can be added using DDE, but convoluted!)
FWIW there are two other very different approaches to grab all running Excel instances though something along the lines of the above is simplest.
Peter Thornton -
Invalid method "Save As" from Excel application object
I have Windows 2000 and Excel 2002 installed on my machine.
I down loaded "renamed Excel 2000 workbook.vi" from NI website. Relinked ref num to Excel application object but get the error of invalid method (Save As). Tried to relink invoke node to Save As by selecting method from drop down menu. However this method is not on the list. Tried other excel objects but can not find "Save As" method. Has this been removed/moved?I was able to correct the error by relinking the Workbooks->Open to Open. This changes the subsequent Invoke Node from IAppEvents to _Workbook. There you will find the Save As method.
Michael
www.abcdefirm.com
Michael Munroe, ABCDEF
Certified LabVIEW Developer, MCP
Find and fix bad VI Properties with Property Inspector -
Getting Error :Error when instantiating WebService runtime
Hello All,
I am a new to Webservices and writing a test program .I am using the ECC 5.0 .I am calling a Webservice from R/3 .I am trying to call this webservice :[http://webservices.daehosting.com/services/isbnservice.wso?WSDL].
I am getting the following exception
{<?xml version="1.0" encoding="utf-8" ?>
- <asx:abap xmlns:asx="http://www.sap.com/abapxml" version="1.0">
- <asx:values>
<SYSTEMFAULT href="#o68" />
</asx:values>
- <asx:heap xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:abap="http://www.sap.com/abapxml/types/built-in" xmlns:cls="http://www.sap.com/abapxml/classes/global" xmlns:dic="http://www.sap.com/abapxml/types/dictionary">
- <cls:CX_AI_SYSTEM_FAULT id="o68">
- <CX_ROOT>
<TEXTID>F63AFF63DBE4BB4786A7F52CC4167145</TEXTID>
<PREVIOUS href="#o55" />
<KERNEL_ERRID />
- <INTERNAL_SOURCE_POS>
<PROGID>191</PROGID>
<CONTID>558</CONTID>
</INTERNAL_SOURCE_POS>
</CX_ROOT>
<CX_STATIC_CHECK />
- <CX_AI_SYSTEM_FAULT>
<CODECONTEXT>Local</CODECONTEXT>
<CODE>ERROR_WEBSERVICE_RUNTIME_INIT</CODE>
<ERRORTEXT>Error when instantiating WebService runtime (Error when initializing SOAP client application )</ERRORTEXT>
<LANGUAGE />
</CX_AI_SYSTEM_FAULT>
</cls:CX_AI_SYSTEM_FAULT>
- <cls:CX_XMS_SYSERR_PROXY id="o55">
- <CX_ROOT>
<TEXTID>3F829CAF9A45633CE10000000A155117</TEXTID>
<PREVIOUS />
<KERNEL_ERRID />
- <INTERNAL_SOURCE_POS>
<PROGID>0</PROGID>
<CONTID>0</CONTID>
</INTERNAL_SOURCE_POS>
</CX_ROOT>
<CX_STATIC_CHECK />
- <CX_XMS_SYSTEM_ERROR>
<ID>ERROR_WEBSERVICE_RUNTIME_INIT</ID>
<P1>Error when initializing SOAP client application</P1>
<P2 />
<P3 />
<P4 />
<INFO />
<CATEGORY>XIProxy</CATEGORY>
<AREA>ABAP</AREA>
<RETRY>M</RETRY>
</CX_XMS_SYSTEM_ERROR>
- <CX_XMS_SYSERR_PROXY>
<CO_AREA_ABAP>ABAP</CO_AREA_ABAP>
</CX_XMS_SYSERR_PROXY>
</cls:CX_XMS_SYSERR_PROXY>
</asx:heap>
</asx:abap>}
This is what i have given in LPCONFIG Tcode
LPCONFIG->General setting-> Call parameters->
URL->http://webservices.daehosting.com/services/isbnservice.wso?WSDL
Please help out what I am missing here
Thanks
KrishnaI had the same error, while implementing a new client webservice.
The Error ERROR_WEBSERVICE_RUNTIME_INIT was in my case solved by:
1. regenerating the CL_SOAP_APPLICATION_CLIENT class.
and
2. deleting the LPCONFIG setting and creating a new one.
Edwin. -
I get an error when trying to open "The application Creative Cloud can't be opened. -1712
I get an error when trying to open "The application Creative Cloud can't be opened. -1712
The application Install.app can't be opened. -1712
-
Error when trying to run an application that worked when built with 8.6
I have a simple program that I wrote in version 8.6 that I never had a problem building and running applications built with it in 8.6. Two weeks ago I got 2009 in the mail because we had very recently purchased 8.6 and I am getting errors when trying to run an application built with the same code using 2009. The error has to do with the Mean.vi. It claims it cannot find it. The error I get reads as follows:
An error occurred loading VI 'NI_AALBase.lvlib:Mean.vi'. LabVIEW load error code 3: Could not load front panel. I don't need access to this vi's front panel, so I am wondering if it is a problem with the runtime engine and not my code. Please respond as soon as possible as this will quickly start to impact my testing schedule. Thank You.
Solved!
Go to Solution.Hi!
The same problem ???
I discussed it with my local NI technical support team. The application works without any problems now.
Basic rule: when creating an installer be sure that option "Run Time Engine xxxx" in "Additional Installers" category is checked in spite of the fact that Run Time Engine is already installed.
Best regards.
Attachments:
ADDINST.png 13 KB -
There is always an error when I try to make an object
I could setup 6i, then make a repositori succesfuly. (Win2000/db8i)
I always get an error when I try to make an object in somewhere a diagram.
ORA-01400: cannot insert NULL into ("DES_REPOS_OWNER"."I$SDD_DIAGRAM_SEGMENTS"."IRID")
ORA-01400: cannot insert NULL into ("DES_REPOS_OWNER"."I$SDD_DIAGRAM_SEGMENTS"."IRID")
RME-02124: Failed to execute SQL statement: insert into I$SDD_DIAGRAM_SEGMENTS (DIAGRAM_REF, SEQUENCE, GRAPHICAL_DATA, PARENT_IVID, PAC_REF) values (:diag_id, :seq, :data, :diag_ivid, :diag_id)
Could somebody help me?
ViktorWhat sort of error? The update and activation servers are crazy busy right now, so some glitchiness is to be expected. Might just want to give it a couple hours and try again.
= L.I. -
Error when creating interval for number range object
Hi,
I am trying to transport my BW stuff from QA to Production and I am getting the following error in the transport logs. The info objects are inactive in RSA1.
Start of the after-import method RS_IOBJ_AFTER_IMPORT for object type(s) IOBJ (Activation Mode)
Characteristic YRESD: Error when creating interval for number range object BIM0000396
Can some body advise me what's wrong? Is something need to be maintained in number ranges?
Also when I am checking the objects in RSA1, I am getting a message saying "source system WD110 does not exist", WD110 is our dev system. How can I change the source system after transport?
Thanks.
Edited by: Raj G on Mar 20, 2008 11:38 AMAlso when I am checking the objects in RSA1, I am getting a message saying "source system WD110 does not exist", WD110 is our dev system. How can I change the source system after transport?
Which system are you checking this?
refer: Re: Transport Source Systems from DEV to Testing for step to map the source systems for transport -
Error when select sheet for Excel file from Excel 2013 with visual basic
Dim AppXL As Object
Dim MyWorkBook as Object
Set AppXL = CreateObject("Excel.Application")
Set MyWorkBook = AppXL.Workbooks.Open("E:\MyFile.xls)
AppXL.Sheets("Sheet1").Select
The above code run with no problem when use in machines with Excel 2007 and Excel 2010.
But when run in machine with Excel 2013, error with "Out of Range" occur. Kindly advise for any solution.
TS LimWith your highlight on the AppXL.Workbooks.Open, I have solved the problem by re-position the statements.
Below are the 2 situation which works in for Outlook 2007, 2010 and 2013
Situation 1, work for Outlook 2007 and 2010 but d not 2013
With AppXL
Set WorkBookFrom = AppXL.Workbooks.Open("E:\MyFile.xls")
Set WorkBookTo = AppXL.Workbooks.Open("E:\MyFile2.xls")
WorkBookFrom.Activate
.Sheets("Sheet1").Select
.Range("A1:IV65536").Select
.Selection.Copy
WorkBookTo.Activate
.Sheets("Sheet1").Select
.Selection.PasteSpecial Paste:=-4163, Operation:=-4142, SkipBlanks:=False, Transpose:=False
.Range("A1").Select
WorkBookTo.Save
End With
Situation 2, work for Outlook 2007 and 2010 and 2013
With AppXL
Set WorkBookFrom = AppXL.Workbooks.Open("E:\MyFiel.xls")
WorkBookFrom.Activate
.Sheets("Sheet1").Select
.Range("A1:IV65536").Select
.Selection.Copy
Set WorkBookTo = AppXL.Workbooks.Open("E:\MyFile2.xls")
WorkBookTo.Activate
.Sheets("Sheet1").Select
.Range("A1").Select
.Selection.PasteSpecial Paste:=-4163, Operation:=-4142, SkipBlanks:=False, Transpose:=False
WorkBookTo.Save
End With
Thank you for indirectly help me to solve the problem.
TS Lim -
Error when trying to export excel from Chrom
Hi,
I get the following error message when i try to export the excel from Chrome browser. Has anyone encountered this error when trying to export from Chrome ? can you please give me the solution.
Thanks.
Error message:
To export a list, you must have a Microsoft SharePoint Foundation-compatible applicationHi,
From your description, when you export a SharePoint list to excel from chrome, you get an error.
In my SharePoint 2013, when I export a SharePoint list to excel from chrome, it works fine.
For your issue, make sure the excel client have been installed in your environment.
To narrow down the issue, I would like to confirm the following information:
To check whether the issue is related to the browser, I suggest you to do a test in other browsers, such as IE and compare the results.
What version is your office client? office 2013 or 2010? 32bit or 64 bit?
Besides, here are some similar posts, you can take a look at:
http://community.office365.com/en-us/f/172/t/160015.aspx
https://social.technet.microsoft.com/Forums/office/en-US/5ffbeb9e-6eb1-41c2-8141-edab6039bbde/to-export-a-list-you-must-have-a-microsoft-sharepoint-foundationcompatible-application?forum=sharepointadminprevious
I am looking forward to your reply back.
Best regards,
Lisa Chen
TechNet Community Support
Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact
[email protected] -
Truncation of leading Zeros when Down Loading into Excel - OLE Objects
Hi,
Can any one help me on this.
I am using <b>OLE Objects</b> to download Data into Excel Sheet. Data with leading Zeros is getting truncated in Excel.
Ex: Report Output is showing Plant Number as 0002. But when i am downloading to Excel Plant value will become 2 .
I would like to have it as 0002 in Excel.
I have declared Werks as CHAR of 4.I am using OLE Obects for Downloading into Excel Sheet.
I am using "OLE2_OBJECT" I can not use any other FMs to down load to Excel.As i am modifying this program not creating.
Thanks In Advance.
K.Nirmala
Message was edited by: Nirmala ReddyHi Nirmala,
While downloading to excel sheet, u need to change the number format of cell from General to Text, then leading zero's won't get deleted. For that u need to set the property of the cell. Please check this sample code,
INCLUDE OLE2INCL.
tables : zobrent.
data : it_kna1 type table of zobrent with header line.
handles for OLE objects
DATA: H_EXCEL TYPE OLE2_OBJECT, " Excel object
H_MAPL TYPE OLE2_OBJECT, " list of workbooks
H_MAP TYPE OLE2_OBJECT, " workbook
H_ZL TYPE OLE2_OBJECT, " cell
H_F TYPE OLE2_OBJECT. " font
DATA H TYPE I.
DATA: cell1 TYPE ole2_object.
*& Event START-OF-SELECTION
START-OF-SELECTION.
select * from zobrent into table it_kna1
where zopanid = '10001'
and zo_brent = '050'.
start Excel
CREATE OBJECT H_EXCEL 'EXCEL.APPLICATION'.
PERFORM ERR_HDL.
SET PROPERTY OF H_EXCEL 'Visible' = 1.
get list of workbooks, initially empty
CALL METHOD OF H_EXCEL 'Workbooks' = H_MAPL.
PERFORM ERR_HDL.
add a new workbook
CALL METHOD OF H_MAPL 'Add' = H_MAP.
PERFORM ERR_HDL.
output column headings to active Excel sheet
PERFORM FILL_CELL USING 1 1 1 'EDate'.
PERFORM FILL_CELL USING 1 2 1 'Brent'.
PERFORM FILL_CELL USING 1 3 1 'Zopanid'.
PERFORM FILL_CELL USING 1 4 1 'Contract Type'.
PERFORM FILL_CELL USING 1 5 1 'Price Type'.
PERFORM FILL_CELL USING 1 6 1 'Installation Type'.
PERFORM FILL_CELL USING 1 7 1 'Volume'.
PERFORM FILL_CELL USING 1 8 1 'AQ'.
PERFORM FILL_CELL USING 1 9 1 '00000123'.
LOOP AT IT_KNA1.
copy values to active EXCEL sheet
H = SY-TABIX + 1.
PERFORM FILL_CELL USING H 1 0 IT_KNA1-zo_effdat.
PERFORM FILL_CELL USING H 2 0 IT_KNA1-zo_brent.
PERFORM FILL_CELL USING H 3 0 IT_KNA1-zopanid.
ENDLOOP.
CALL METHOD OF h_excel 'Cells' = cell1
EXPORTING
#1 = 1
#2 = 1.
FREE OBJECT H_EXCEL.
PERFORM ERR_HDL.
if sy-subrc eq 0.
write : / 'year'(001).
endif.
FORM FILL_CELL
sets cell at coordinates i,j to value val boldtype bold
FORM FILL_CELL USING I J BOLD VAL.
CALL METHOD OF H_EXCEL 'Cells' = H_ZL EXPORTING #1 = I #2 = J.
PERFORM ERR_HDL.
GET PROPERTY OF H_ZL 'Font' = H_F.
PERFORM ERR_HDL.
SET PROPERTY OF H_F 'Bold' = BOLD .
PERFORM ERR_HDL.
***Changing the format of the cell from General to Text
<b>SET PROPERTY OF H_ZL 'NumberFormat' = '@'.</b>
PERFORM ERR_HDL.
SET PROPERTY OF H_ZL 'Value' = VAL .
PERFORM ERR_HDL.
ENDFORM.
*& Form ERR_HDL
FORM ERR_HDL.
IF SY-SUBRC <> 0.
WRITE: / 'Fehler bei OLE-Automation:'(010), SY-SUBRC.
STOP.
ENDIF.
ENDFORM. " ERR_HDL
U just paste this code in a sample program & see.
Please reward, if found helpful. -
Error when deploying new EPMA Planning Application
Hello All!
I've created new Application View via EPMA. Validate is OK. I've created correct Datasource (as I usually do it). But when trying to Deploy new Application View strange error occurs.
There are some logs.
From Library Job Console:
Detail : App Creation failed with Exceptionjava.lang.RuntimeException: Exception occurred while creating the application. Check log for details at com.hyperion.planning.appdeploy.HspAppDefinition.deployAppFromXML(Unknown Source) at com.hyperion.planning.appdeploy.HspAppDefinition.access$000(Unknown Source) at com.hyperion.planning.appdeploy.HspAppDefinition$1.run(Unknown Source)
From BPMA log-file:
2008-02-28 17:13:44,380 [TP-Processor5] ERROR com.hyperion.awb.web.appmanager.Action - Error finding project for application HP:etapp
com.hyperion.interop.lib.OperationFailedException: Application does not exists by this Id 'HP:etapp'.
at com.hyperion.interop.lib.helper.ApplicationHelper.getProjectForApplication(Unknown Source)
at com.hyperion.interop.lib.CMSClient.getProjectForApplication(Unknown Source)
at com.hyperion.awb.web.util.HSSRegistrationUtil.getHubProjectForApp(HSSRegistrationUtil.java:116)
at com.hyperion.awb.web.appmanager.Action.deployValidate(Action.java:260)
at sun.reflect.GeneratedMethodAccessor617.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.struts.actions.DispatchAction.dispatchMethod(DispatchAction.java:276)
at org.apache.struts.actions.DispatchAction.execute(DispatchAction.java:196)
at org.apache.struts.actions.MappingDispatchAction.execute(MappingDispatchAction.java:171)
at com.hyperion.bpm.web.common.BaseAction.execute(BaseAction.java:69)
at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:421)
at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:226)
at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1158)
at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:415)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:300)
at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:374)
at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:743)
at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:675)
at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:866)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
at java.lang.Thread.run(Unknown Source)
What kind of problem is it?
Thank's in advance!Hi,
There are many issues with EPMA 9.3.1 and the patches address these issues, so you really need to install them before using it.
Cheers
John
http://john-goodwin.blogspot.com/ -
I am getting this error when i run the webdynpro application
I am getting follwoing error, when i click on the link available in the webdypro application. Please tell me what is the reason,
Error stacktrace:
com.sap.tc.webdynpro.services.exceptions.WDRuntimeException: is.eimskip.pdfmodel.Zmulti_Pdf
Found in negative cache
Loader Info -
ClassLoader name: [local/SalesOrder]
Parent loader name: [Frame ClassLoader]
References:
common:service:http;service:servlet_jsp
service:ejb
common:service:iiop;service:naming;service:p4;service:ts
service:jmsconnector
library:jsse
library:servlet
common:library:IAIKSecurity;library:activation;library:mail;library:tcsecssl
library:ejb20
library:j2eeca
library:jms
library:opensql
common:library:com.sap.security.api.sda;library:com.sap.security.core.sda;library:security.class;library:webservices_lib;service:com.sap.security.core.ume.service;service:connector;service:dbpool;service:keystore;service:security;service:userstore
interface:resourcecontext_api
interface:webservices
interface:ejbserialization
sap.com/tcwddispwda
sap.com/tcwdcorecomp
service:webdynpro
service:sld
library:tcddicddicservices
library:com.sap.aii.proxy.framework
library:tcgraphicsigs
library:com.sap.mw.jco
library:com.sap.lcr.api.cimclient
library:sapxmltoolkit
library:com.sap.aii.util.rb
library:com.sap.util.monitor.jarm
library:tcddicddicruntime
library:com.sap.aii.util.xml
library:tccolapi
library:com.sap.aii.util.misc
library:tc~cmi
library:tccolruntime
Resources:
D:\usr\sap\EPD\JC01\j2ee\cluster\server0\apps\local\SalesOrder\webdynpro\public\lib\app.jar
Loading model: {parent,references,local}
at com.sap.tc.webdynpro.modelimpl.dynamicrfc.AiiModelClass.createNewBaseTypeDescriptor(AiiModelClass.java:378)
at com.sap.tc.webdynpro.modelimpl.dynamicrfc.AiiModelClass.descriptor(AiiModelClass.java:186)
at is.eimskip.pdfmodel.Zbapi_Salesorder_Getpdf_Output_Input.<init>(Zbapi_Salesorder_Getpdf_Output_Input.java:51)
at is.eimskip.comp.PDFCust.GetPdfFileName(PDFCust.java:145)
at is.eimskip.comp.wdp.InternalPDFCust.GetPdfFileName(InternalPDFCust.java:171)
at is.eimskip.comp.ResultView.onActionShowBL(ResultView.java:409)
at is.eimskip.comp.wdp.InternalResultView.wdInvokeEventHandler(InternalResultView.java:365)
at com.sap.tc.webdynpro.progmodel.generation.DelegatingView.invokeEventHandler(DelegatingView.java:87)
at com.sap.tc.webdynpro.progmodel.controller.Action.fire(Action.java:67)
at com.sap.tc.webdynpro.clientserver.task.WebDynproMainTask.handleAction(WebDynproMainTask.java:100)
at com.sap.tc.webdynpro.clientserver.task.WebDynproMainTask.handleActionEvent(WebDynproMainTask.java:299)
at com.sap.tc.webdynpro.clientserver.task.WebDynproMainTask.execute(WebDynproMainTask.java:640)
at com.sap.tc.webdynpro.clientserver.cal.AbstractClient.executeTasks(AbstractClient.java:59)
at com.sap.tc.webdynpro.clientserver.cal.ClientManager.doProcessing(ClientManager.java:251)
at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doWebDynproProcessing(DispatcherServlet.java:154)
at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doContent(DispatcherServlet.java:116)
at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doPost(DispatcherServlet.java:55)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:391)
at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:265)
at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:345)
at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:323)
at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:865)
at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:240)
at com.sap.engine.services.httpserver.server.Client.handle(Client.java:92)
at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:148)
at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:37)
at com.sap.engine.core.cluster.impl6.session.UnorderedChannel$MessageRunner.run(UnorderedChannel.java:71)
at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
at java.security.AccessController.doPrivileged(Native Method)
at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:94)
at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:162)
Caused by: java.lang.ClassNotFoundException: is.eimskip.pdfmodel.Zmulti_Pdf
Found in negative cache
Loader Info -
ClassLoader name: [local/SalesOrder]
Parent loader name: [Frame ClassLoader]
References:
common:service:http;service:servlet_jsp
service:ejb
common:service:iiop;service:naming;service:p4;service:ts
service:jmsconnector
library:jsse
library:servlet
common:library:IAIKSecurity;library:activation;library:mail;library:tcsecssl
library:ejb20
library:j2eeca
library:jms
library:opensql
common:library:com.sap.security.api.sda;library:com.sap.security.core.sda;library:security.class;library:webservices_lib;service:com.sap.security.core.ume.service;service:connector;service:dbpool;service:keystore;service:security;service:userstore
interface:resourcecontext_api
interface:webservices
interface:ejbserialization
sap.com/tcwddispwda
sap.com/tcwdcorecomp
service:webdynpro
service:sld
library:tcddicddicservices
library:com.sap.aii.proxy.framework
library:tcgraphicsigs
library:com.sap.mw.jco
library:com.sap.lcr.api.cimclient
library:sapxmltoolkit
library:com.sap.aii.util.rb
library:com.sap.util.monitor.jarm
library:tcddicddicruntime
library:com.sap.aii.util.xml
library:tccolapi
library:com.sap.aii.util.misc
library:tc~cmi
library:tccolruntime
Resources:
D:\usr\sap\EPD\JC01\j2ee\cluster\server0\apps\local\SalesOrder\webdynpro\public\lib\app.jar
Loading model: {parent,references,local}
at com.sap.engine.frame.core.load.ReferencedLoader.loadClass(ReferencedLoader.java:348)
at com.sap.tc.webdynpro.modelimpl.dynamicrfc.AiiModelClass.createNewBaseTypeDescriptor(AiiModelClass.java:373)
... 32 moreFound in negative cache.... very strange.
RFC found in negative cache
What is the negative cache?
Maybe you are looking for
-
Powerbook will not network with PC
I have spent the last 4 hours in the Apple Discussions forums trying to find a solution to my problem with no avail. Please forgive me if I have alot of links to explain my issue, I'm just too exhausted to re-iterate. So here's the jist... I wanted t
-
Hello: I have installed a Secure Global Desktop 4.50.933 After tarantella start I get the next java error: Secure Global Desktop services are now available on this host. # javax.naming.NoPermissionException [Root exception is java.io.FileNotFoundExce
-
Can you enable Numbers, Pages, or Keynote to automatically save every ...(desired time intervals) like Microsoft Office does?
-
Hi, does someone know, if it's possible to change the font of a matrix column title in SAP Business One. I want to change the column title of the invoice matrix, where i put in the order details, like article, article description, amount and so on. I
-
Hi, I'm using this tip from MacOSXHints to try to recover data from an external drive attached by FireWire. It essential involves using "dd" in the terminal to perform a bit-by-bit transfer of data from a failing disk to a disk image on a healthy one