Calling a CFC in a subdirectory
I'm trying to figure out how to use cfinvoke to call a cfc sitting in a subdirectory...
It's apache with userdir turned on (so each user that has a public_html directory in their homedir can have a site)
The resulting logical path looks something like this:
/~user/CFC/component.cfc
/~user/test.cfm
I don't know what to put in test.cfm for it to see component cfc... Usually we would have the CFC directory in document root, so I would just be able to put <cfinvoke component='cfc.component'> but that's not the case now...
Thanks
Thanks for the response. Web root is still /. Each user just gets a subdirectory off web root when UserDir is enabled, so /CFC did not work... Neither did ../CFC/ unfortunately, not even ./CFC/
The only way I can make it work is if I put the .cfc in the same dir as the script, which is OK for now but will not be practical once I have a whole list of them.
Similar Messages
-
RPC fault when calling a CFC from flex
Hello there,
I'm having some startup problems getting Flex and Colfusion 8
to play nice with FDS. I'm using Flexbuilder 2.0.1 and Coldfusion 8
developer edition on IIS on a windows box (XP professional).
I use a very simple test CFC in my coldfusion site with just
one function called 'getstring' which, surprise, surprise returns a
string. I want to show this string on a label in my Flex frontend
by using <mx:remoteobject>, the whole thing compiles
perfectly, I use this mxml:
<mx:RemoteObject id="TestService"
source="cfc.DataTest"
destination="ColdFusion"
concurrency="multiple"
makeObjectsBindable="true"
showBusyCursor="true">
<mx:method name="getString"
result="doResult(event.result)" fault="doFault(event.fault)"/>
</mx:RemoteObject>
but after calling the remote method I get this error back:
[RPC Fault faultString="coldfusion.xml.rpc.CFCServlet cannot
be cast to coldfusion.runtime.CFPage" faultCode="Server.Processing"
faultDetail="null"]
Which is the same type of error I get when I call a CFC
directly through the address bar in my browser, for example
http://localhost/cfc/datatest.cfc
I tried googling the error message but so far found nothing
that indicated what I'm doing wrong...
I'd really appreciate some help here, if you need more info
let me know...
thanx in advanceOk, nevermind, I figured out what I was doing wrong. I had
accidentally setup my application.cfc in a wrong way, I had set all
of the onrequest en onapplication event handlers to
access="package" instead of "public", this generated an error
ofcourse...
I'll just go bang my head against a wall for a while
now.... -
is there a way to find out who invoked a CFC? I would like to
check and log who the calling .CFM or .CFC file is from within the
CFC being invoked. Sort of like back in the Custom Tag days, I need
to know which templated called me. I am looking at the
GetMetaData() and GetPageContext() functions but nothing stands out
yet as how to do what I need to do.
Thanks All for the Posts below,
This is a pretty tough one, and I wish I could diagram it to
help explain.
cfc1
cfc2
cfc55
In any of these CFC's, we have code wraped in try/catch
statements. When an exception is thrown, the catch statements kick
in. in the catch blocks, I invoke a cfc called myErrorCFC.cfc..
err = createObject("component", "myError");
From there inside of the catch block I am invoking a method
(see below) which performs legancy handling/logging.
err.parseException(cfcatch.Message);
What I now need to do is extend that method to log who thrown
the exception. Yes the simple way is to pass the name of the cfc or
cfm page as an argument, but changing the code which invokes the
err cfc is out of my control. So I am left with trying to solve
this the hard way.
So far this is where I am at (in my "myErrorCFC.cfc", invoked
from within the catch blocks) which is not currently working:
tmp = getPageContext().getException();
This does not work but it may clearify the approach I am
taking. Does anyone have any good ideas on how to return the error
object from the JRun/jsp/java side of things. "getPageContext()"
returns a "coldfusion.runtime.NeoPageContext" object. The end
result I am trying to achieve is simply (ha ha) to find out which
cfc or cfm page that the exception was thrown and having access to
any additional info would be benificial as well.
Any help will be appriciated greatly.
Thank you,
ErikThx for your response, passing an argument would idealy be
the simplest approach but in the context of the problem it would
not be posible. I am working with a VERY large application and to
do so would mean modifying hundreds of lines of code where the CFC
I'm invoking is called from throughout the system. With large
legancy systems as you know, it's always exceptable to make
sweeping changes through sensitive code. If I end up not being able
to find a method in which to find who invoked the CFC I am
modifying I will just have to live with the fact. Idealy I want to
be able to track and log who it was that initiated the CFC. That
can come from a number of model cfm files or cfc's. -
Is it possible to call a cfc function through a udf, or maybe im just looking at this the wrong way but here is what im ultimately trying to do.
I have the following table:
tbl_users
=====================
uid name
=====================
1 John
2 Steve
3 Joe
4 Bob
Then throughout the program i am given a few of the uid, and i have to loop through them and get the names, so im trying to figure out a way to make a function so i can call it like this and it checks the db and gives me the name:
getName(uid) = returns name
Is there any easy way of doing something like this?case 1: user-defined function alone
<cffunction name="getNameFromId">
<cfargument name="id" default="1">
<cfset var selectedUser = "">
<cfset user = arrayNew(1)>
<cfset user[1] = "John">
<cfset user[2] = "Steve">
<cfset user[3] = "Joe">
<cfset user[4] = "Bob">
<cfset selectedUser = user[arguments.id]>
<cfreturn selectedUser>
</cffunction>
<cfoutput>#getNameFromId(3)#</cfoutput>
case 2: (a) content of CFM page userName.cfm
<cfset userObject = createobject("component", "User")>
<cfoutput>#userObject.getNameFromId(2)#</cfoutput>
<!--- Alternative, using cfinvoke --->
<!---
<cfinvoke component="User" method="getNameFromId" returnVariable="userName">
<cfinvokeargument name="id" value="2">
</cfinvoke>
<cfoutput>#userName#</cfoutput>
--->
(b) The user-defined function is in a component saved as User.cfc in the same directory as the page userName.cfm
<cfcomponent displayname="User">
<cffunction name="getNameFromId">
<cfargument name="id" default="1">
<cfset var selectedUser = "">
<cfset user = arrayNew(1)>
<cfset user[1] = "John">
<cfset user[2] = "Steve">
<cfset user[3] = "Joe">
<cfset user[4] = "Bob">
<cfset selectedUser = user[arguments.id]>
<cfreturn selectedUser>
</cffunction>
</cfcomponent> -
Is the directory watcher multi-threaded once it calls the cfc?
the docs say there's a single thread that watches the directory. But say for example it finds 3 files and calls the cfc. At that point do all 3 files run one at a time on a single thread in the order they came in, or do they run at the same time on multi-threads?
I think I understood your questions. There were more than one, some implicit. Here are my answers:
ColdFusion runs the directory-watcher in a single thread.
During the execution of the same thread, ColdFusion detects whether of not a file has, or any number of files have, been added, deleted or changed.
When ColdFusion calls the CFC, it does so in that same single thread. My guess is that any file add-events, delete-events and change-events are queued and handled one after the other. -
Howdy gang!
I have inherited an application with a fairly large number of cfcs. The codebase goes back quite a few years. Though the code is in mostly decent shape, as with most long lived apps, there are files no longer in use, etc.
I am hoping to figure out a way to monitor cfc usage. Ideally, I would be getting something like:
* cfc name
* method
* file called from
* maybe args passed
I would stuff this info in to a table, so I can basically select all cfcs that have not seen any use in a given time period.
Coming up completely blank on this one. Any ideas? Thanks!/Web-inf/debug/ directory (classic.cfm is the classic debugging that is visible at the end of the page)
Indeed. The key code is
<cfobject action="CREATE" type="JAVA" class="coldfusion.server.ServiceFactory" name="factory">
<cfset cfdebugger = factory.getDebuggingService()>
<cfset qEvents = cfdebugger.getDebugger().getData()>
qEvents is a query. What you want to get your grimy mitts on is that query's template column.
However, I should be wary of tampering with any of the files in /WEB-INF/debug/, as they are system files. Another consideration is load. The files in WEB-INF bootstrap a web application, and are generally meant to run before every request. Therefore, you wouldn't want to add any heavy-duty code in there.
I can think of two ways around that. In either case you create a temporary debug file with the sole purpose of logging the templates that your applications open. You will delete the files when you've collected enough information.
The first possibility is to make a copy of classic.cfm, say, /WEB-INF/debug/myClassic.cfm. Then, in myClassic.cfm, you may add the following line immediately after <cfset qEvents = cfdebugger.getDebugger().getData()>:
<cflog file="templates" text="#qEvents.template#">
Alternatively, you can just create your own debug file, say, /WEB-INF/debug/templateLogger.cfm. The file templateLogger.cfm would contain the barest minimum code you need for the job, namely
<cfobject action="CREATE" type="JAVA" class="coldfusion.server.ServiceFactory" name="factory">
<cfset cfdebugger = factory.getDebuggingService()>
<cfset qEvents = cfdebugger.getDebugger().getData()>
<cflog file="templates" text="#qEvents.template#">
In fact, as you will see in a moment, you may choose to implement both myClassic.cfm and templateLogger.cfm. After all, you will only be able to apply one at a time! How then?
In the Coldfusion Administrator, of course. Go to the section on Debugging & Logging. You will find that all the files in /WEB-INF/debug/ appear as a drop-down list entitled, "Select Debugging Output Format". You can only choose one!
Tick the checkbox "Enable Request Debugging Output". Click the button to submit the changes, and you're in business. -
$25 Reward - Calling a CFC via Remote Object or Web Service without making the result public
I am just getting into Flex 2, so please forgive me for my
newbe vocab.
Here is how my applications have worked in the past, i.e.
ColdFusion:
<cfscript>
//Create an instance of component
order = CreateObject( 'component', 'PEK.Catalog.Order' );
//Call methd
theOrder = order.getOrder(1234);
</cfscript>
Display the order via HTML and CFML.
getOrder() returns a query and 1234 is a sample orderID. The
most important part of the solution I am looking for is that the it
must not expose my getOrder() as a public web service. I am able to
run the application with WS by making the mothod URL visible and
remote, but this is no way near the security I would like to have.
Here is my folder structure where components folder has been maped
to CF.
Application
|__extentions
| ... |__components
| ... ... |__PEK
|__wwwroot
I guest there should be a way to call CFC with the thing
remote object that I have no idea how to set up. So please what
would be a solution to my security issues.
Thank you in advance!Click
Here for Link to Article
I guess this article answers part of the question. It is very
important to note that if the CFC is sitting on the same server as
the CFC the component methods could be public and not remote, thus
making it alot more secure. -
Calling remote CFC method from CFFORM
From what I understand by the remote methods in CFCs you can
access them by passing the argument names and values through the
URL with the method defined as well. I am trying to do the
following:
http://www.cfcoding.com/osu/components/Employees.cfc?method=addEmployee&firstname=Tristan& lastname=Lee&email=tristanlee%40gmail.com&address=1234+Some+Dr.&city=My+City&state=My+Stat e&zip=12345&comments=Test2&onNext=%2Fadmin%2F
I have attached the code for that function, but it seems as
though when I call that method with the arguments, the page is just
blank. Even with output being on, I still can't get anything to
display. In the end, the new employee isn't inserted into the
database which is my biggest concern. Any dieas?There are several issues:
1. You need to obtain file handle before calling GetFileType(). How are you going to get it?
2. The simplest way to call a method from kernel32 would be using jni wrapper library, like xFunction:
import com.excelsior.xFunction.*;
/* Call Beep() from KERNEL32.DLL */
xFunction f = new xFunction( "kernel32", "int Beep(int,int)" );
f.invoke( new Argument(1770), new Argument(100) );regards, Denis -
Flex app calling CF cfc to download file gets "Channel disconnected" fault
I am a newbie with ColdFusion and Flex. I am trying to implement file download/streaming functionality in my Flex 4.5 application and I am running ColdFusion 9 as my back end. More specifically, I have a component in my Flex app that displays a list of files - some of these files can be available for opening (or "previewing") via the client. I want the client to be able to click a button and download the file from the ColdFusion server, after the appropriate security checks are performed (also in ColdFusion). Right now I am just trying to get the basic download functionality to work with a very simple cfc. Here is the cfc code:
<cfcomponent displayname="Preview Document"
output="false">
<cffunction name="streamFile" access="remote" returntype="any">
<cfargument name="filename" displayName="Filename" type="string" required="true" />
<cfheader name="Content-Disposition" value="attachment;filename=#filename#" >
<cfcontent type="application/unknown" file="c:\myserverpath\#filename#">
</cffunction>
</cfcomponent>
When I try this via a cfm, it works fine (I get a File Download window where I can choose to either open or save the file). But when I try to use this in my Flex app, I get an error.
In my Flex app, I have a RemoteObject to access my cfc and a CallResponder:
<s:RemoteObject id="PreviewDocument"
source="PreviewDocument"
destination="ColdFusion"
showBusyCursor="true"/>
<s:CallResponder id="PreviewDocumentResult"
fault="Alert.show('CallResponder PreviewDocumentResult: ' +
event.fault.faultString + '\n' + event.fault.faultDetail)"
result="PreviewDocumentResult_resultHandler(event)"/>
Then I created a button whose click even executes the following line:
PreviewDocumentResult.token = PreviewDocument.streamFile("myfile.pdf");
When I run my app, I get the following fault:
faultCode = "Client.Error.DeliveryInDoubt"
faultString = "Channel disconnected"
faultDetail = "Channel disconnected before an acknowledgement was received"
I have tried many different approaches and searched online for help with this fault, but I could not find any helpful clue to where I can start investigating this.
Can anyone help with why I am getting this fault?
Thanks in advance.@sir_teddy, thanks for your reply again.
Yes I have created a simple cfc that returns a string successfully (in fact I had used the same cfc and basically just commented out the cfcontent and cfheader tags, and returned the name of the file being requested in the cfreturn tag). When I un-comment the cfcontent tag from the code, the error comes back.
So I am really at a loss here... -
Hi,
In a web application, if I need to call a CFC method from a different CFC, what would be considered as the best way of doing it?
For example, let's say I have two components: Customer and Product. From a method functionA in Customer, I would like to call functionB in Product. I can do one of the following, but which way is best practice and why?
1. Create a Product object in functionA, and use it to call functionB
<cfcomponent name="Customer">
<cffunction name="functionA">
<cfset productObj = createObject('component', 'Product')>
<cfset productObj.functionB()>
</cffunction>
</cfcomponent>
2. Pass a Product object when we initialize a Customer object, and use that to call functionB
<cfcomponent name="Customer">
<cffunction name="init">
<cfargument name="productObj">
<cfset variables.productObj = arguments.productObj>
</cffunction>
<cffunction name="functionA">
<cfset variables.productObj.functionB()>
</cffunction>
</cfcomponent>
3. Assume that Customer object has access to the Product object in the application scope
<cfcomponent name="Customer">
<cffunction name="functionA">
<cfset application.productObj.functionB()>
</cffunction>
</cfcomponent>
Thank you very much.The first two are fine. If the CFC being called is always gonna be the exact same one, then there's no prob directly referencing it in the calling CFC. If the CFC could vary, then pass it in.
If you're only using the CFC transiently, then you could use <cfinvoke> as well in this case.
Directly accessing an application-scoped CFC within a method is poor practice.
Adam -
Remoteobject call cfc on remote server
Our goal is to have any of our flex developers use a central set of cfcs. Rather than having everyone need to duplicate all the required file structure etc.
So it seemed like adding endpoint to the RemoteObject tags should get us significantly closer.
<mx:RemoteObject id="SomeTest" source="sometest" destination="ColdFusion" endpoint="http://localhost:8500/" >
... I've tried various endpoint syntax a remote server address and ip and using 127.0.0.1 instead of localhost
... If I take out the endpoint attribute, it works just fine
... it calls a cfc in the webroot
... in case you want to see the cfc function... it just returns a variable.
<cffunction name="TestFunction" access="remote" returntype="String">
I'm running cf locally and my flex compiler is
-services "C:\ColdFusion8\wwwroot\WEB-INF\flex\services-config.xml" -locale en_US
When I run the app which simply calls the cfc and alerts the result, it works fine unless I have an endpoint defined as above. The error is:
faultDetail="Channel.Connect.Failed error NetConnection.Call.BadVersion: : url: 'http://localhost:8500/The correct endpoint will be http://localhost:8500/flex2gateway
Sincerely,
Michael
El 27/04/2009, a las 14:07, arocheking <[email protected]> escribió:
>
Our goal is to have any of our flex developers use a central set of
cfcs. Rather than having everyone need to duplicate all the required
file structure etc.
So it seemed like adding endpoint to the RemoteObject tags should
get us significantly closer.
>
<mx:RemoteObject id="SomeTest" source="sometest"
destination="ColdFusion" endpoint="http://localhost:8500" >
... I've tried various endpoint syntax a remote server address and
ip and using 127.0.0.1 instead of localhost
... If I take out the endpoint attribute, it works just fine
>
... it calls a cfc in the webroot
... in case you want to see the cfc function... it just returns a
variable.
<cffunction name="TestFunction" access="remote" returntype="String">
>
I'm running cf locally and my flex compiler is
-services "C:\ColdFusion8\wwwroot\WEB-INF\flex\services-config.xml" -
locale en_US
>
When I run the app which simply calls the cfc and alerts the result,
it works fine unless I have an endpoint defined as above. The error
is:
faultDetail="Channel.Connect.Failed error
NetConnection.Call.BadVersion: : url: 'http://localhost:8500/
> -
How to create/call dynamic XML feed from CFC - HELP PLEASE!!
Hi All,
First off I'm a newb to web services. I'm trying to create the invoke a web service on a CFC for a XML feed. When I call the CFC directly all looks fine and is correctly formatted etc:
http://www.prevu.tv/cfc/xyzTest.cfc?method=listPlant
Am I correct in outputting it in this way? What if I output as a string instead......would others be able to consume it?
When I try to invoke it as a web service I am getting an error I do not understand. I am trying to call it using (user/pass not required in CFC):
<cfinvoke webservice="test" method="listPlant" returnvariable="foo">
<cfinvokeargument name="username" value="abc">
<cfinvokeargument name="password" value="123">
</cfinvoke>
<cfoutput><cfdump var="#foo#"></cfoutput>
Here is my CFC code:
<cfcomponent>
<cffunction name="listPlant" access="remote" returntype="xml" output="no">
<cfargument name="username" type="string" required="no">
<cfargument name="password" type="string" required="no">
<cfquery datasource="#request.dsn#" name="getPlant">
SELECT *
FROM plant
INNER JOIN plantaddress ON plant.plantID = plantaddress.plantID
WHERE icePlantID IS NULL
AND categoryID NOT IN (9,10,11)
AND statusID = 1
AND activePlantList = 1
ORDER BY plant.plantID LIMIT 5
</cfquery>
<!---Convert Query to xml--->
<cfprocessingdirective suppresswhitespace="Yes">
<cfcontent type="text/xml; charset=utf-8">
<cfxml variable="xmlobject">
<PrevuPlant>
<cfoutput query="getPlant">
<Plant>
<PlantID>#plantID#</PlantID>
<PlantName>#XmlFormat(plantName)#</PlantName>
<Street>#XmlFormat(street)#</Street>
<Suburb>#XmlFormat(suburb)#</Suburb>
<City>#XmlFormat(city)#</City>
<State>#XmlFormat(state)#</State>
<Country>#XmlFormat(country)#</Country>
<PostCode>#XmlFormat(postcode)#</PostCode>
<Latitude>#XmlFormat(latitude)#</Latitude>
<Longitude>#XmlFormat(longitude)#</Longitude>
<CountryCode>#XmlFormat(countryCode)#</CountryCode>
<AreaCode>#XmlFormat(areaCode)#</AreaCode>
<Phone>#XmlFormat(phone)#</Phone>
<Fax>#XmlFormat(fax)#</Fax>
</Plant>
</cfoutput>
</PrevuPlant>
</cfxml>
<!---Convert back to a string--->
<cfset myvar=toString(xmlobject)>
</cfprocessingdirective>
<cfreturn myvar>
</cffunction>
</cfcomponent>
Can anyone please tell me where I am going wrong, or how the output for a XML feed called from a CFC should look in a browser etc?
ThanksHey Dan....thanks for the prompt reply.
I added the wsdl and this is what I get when I call the service from this cfm page: http://www.prevu.tv/xyzTest.cfm
Have never seen output like this. Is this correct?
The web service I'm writing is also for some .net developers so it may be that I need to output as string also - this discussion has not taken place yet. -
Is it possible to have cfc's in a different location than the
root folder. So for instance if i want to invoke a cfc and it was
located 2 directories above where i'm calling it from and is called
users.cfc would i call it like this:
<cfinvoke component="../../cfc/users" method="testmethod"
returnvariable="test">
Or how would i call it.You can have CFC files stored wherever
You can either try and "backup" using the method shown above,
which can get a bit hairy if you have many sub directory layers, or
you can simply start the directory location from the root:
component="/cfc/users"
by starting the pathway with a "/", it tells the server to
start at the root directory. This way the path can be consistent
between all pages regardless of what directory or subdirectory they
may be in. -
Issue modeling data from Coldfusion cfc
Problem: Configure return type in Flash Builder (using with Coldfusion) Mysql 5 driver (testing using localhost with CF also acting as the web server)
I have tried going thru the steps presented in the video presentations for hooking Flash Builder to Coldfusion query data. I provide a name for a Custom data type, provide variables (that are optionally required by the CFC), and then proceed. The operation comes back with the following message.
The operation returned a response of the type "Object"
You may either update server code to fix the return data or CLICK OK to set "Objecdt" as the returntype of this operation
In all of the videos I have watched, Flash Builder auto-magically introspected the table that was being called and knew the data types of each piece of the data returned by the query. In my case, I get the above message and cannot proceed.
CFM Testing
I have tested the query by calling the CFC method via a coldfusion page and dumping the result. Everything is works with that.
Action:
I would like to get past the problem and learn what if anything I am doing wrong with this. Your input is appreciated. I have been learning CF and am getting pretty comfortable with that product. I would like to move forward with Flash Builder. I have some basic knowledge of Flex 3.
Thanks for your help
Background:
CFC signature
<cffunction name="getJewels" access="remote" returntype="any">
<cfargument name="jType" type="string" required="no" />
<cfargument name="jActive" type="boolean" required="no" />
<cfargument name="jOrder" type="boolean" required="no" />
Server Settings > Settings Summary
Report generated on Jul 08, 2009 11:07 AM
This report shows the status of all ColdFusion configuration settings. To display the area of the ColdFusion Administrator where you can edit the group settings, click any of the groups in the report.
Version Information
Server Details
Server Product
ColdFusion
Version
8,0,0,176276
Edition
Developer
Serial Number
Operating System
Windows XP
OS Version
5.1
Adobe Driver Version
3.6 (Build 0017)
JVM Details
Java Version
1.6.0_01
Java Vendor
Sun Microsystems Inc.
Java Vendor URL
http://java.sun.com/
Java Home
C:\ColdFusion8\runtime\jre
Java File Encoding
Cp1252
Java Default Locale
en_US
File Separator
Path Separator
Line Separator
Chr(13)
User Name
SYSTEM
User Home
C:\
User Dir
C:\ColdFusion8\runtime\bin
Java VM Specification Version
1.0
Java VM Specification Vendor
Sun Microsystems Inc.
Java VM Specification Name
Java Virtual Machine Specification
Java VM Version
1.6.0_01-b06
Java VM Vendor
Sun Microsystems Inc.
Java VM Name
Java HotSpot(TM) Server VM
Java Specification Version
1.6
Java Specification Vendor
Sun Microsystems Inc.
Java Specification Name
Java Platform API Specification
Java Class Version
50.0
This is the dataset I am trying to get at.
dstones
CF data source name
dstones
Description
Dancing stones databases
Driver
MySQL5
JDBC URL
jdbc:mysql://localhost:3306/hmsollie?
Username
root
Login timeout
30 seconds
Long text buffer size
64000
Timeout
1200 seconds
Maintain connections
Yes
Interval
420 seconds
Restricted SQL operations
Disable connections
No
Data & Services > Flex Integration
Enable Flash Remoting support
Lets a Flash client connect to this ColdFusion server and invoke ColdFusion Components (CFCs). NOTE: Disabling this feature also disables ColdFusion server monitoring and multiserver monitoring.
Enable Remote Adobe LiveCycle Data Management access
Lets LiveCycle Data Services ES connect to this ColdFusion server through RMI and use CFCs to read and update data that supports a Flex application. If you are not using this feature, disable it. This does not affect LiveCycle Data Services ES integrated in to the ColdFusion installation.
Server Identity:
If you are running more than one instance of ColdFusion on this machine, you must configure each instance with a unique ID.
Enable RMI over SSL for Data Management
Lets you use Secure Socket Layer (SSL) encryption for the RMI communication between Flex and ColdFusion. This is not required unless you are transmitting authentication information or confidential data between Flex and ColdFusion over an unsecured network. You must provide a keystore file and keystore password. For instructions on how to create a keystore file, see the online Help.
Full path to keystore:
Keystore password:
Select IP addresses where LiveCycle Data Services are running
To secure the LiveCycle Data Services ES integration point, the hosts that are allowed to perform Data Management operations are restricted. If you are running LiveCycle Data Services ES on a different computer, specify its IP address here. By default, only the local computer can perform Data Management operations in ColdFusion.
IP Address
View or Remove selected IP addresses where LiveCycle Data Services ES are runningSunil,
I have found the problem. When initialy given the arguments list to fill in "Configure Return Type", I filled in a string argument as "E". This gives a return of object. To accurately use the Configure Return Type, I needed to just fill in a string as E.
See the Screen Prints on the error
I have tested the following functionality and it appears to work ok
1. I have tested with no parms to the CFC query method
2. I have tested using Dynamic SQL based on variables set before the query in a CFC method
3. I have tested passing one string argument in from Flash Builder to a CFC method
4. I have tested passing a string and boolean argument From Flash Builder to a CFC method
For 3 and 4, I had make some slight changes o set the arguments that were being sent to CFC in Flash Builder before the call
It all worked.
**** New Issue ***
I have another runtime issue involving states that I uncovered in my testing where buttons are the screen were being covered up when I used some of the DataGrid Controls. If I can repeat it, I will post it and then let you guys let me know how to work around this.
I am a Flex/AS Novice, so I may be mis-understanding something on this new issue.
Thanks. -
Problem with calling onApplicationStart() method
Hi all,
I have a problem with calling application.cfc's methods from coldfusion template. The problem is like when i am calling "onapplicationstart" method inside a cfml template i getting the error shown below
The onApplicationStart method was not found.
Either there are no methods with the specified method name and argument types or the onApplicationStart method is overloaded with argument types that ColdFusion cannot decipher reliably. ColdFusion found 0 methods that match the provided arguments. If this is a Java object and you verified that the method exists, use the javacast function to reduce ambiguity.
My code is like below.
Application.cfc
<cfcomponent hint="control application" output="false">
<cfscript>
this.name="startest";
this.applicationtimeout = createtimespan(0,2,0,0);
this.sessionmanagement = True;
this.sessionTimeout = createtimespan(0,0,5,0);
</cfscript>
<cffunction name="onApplicationStart" returnType="boolean">
<cfset application.myvar = "saurav">
<cfset application.newvar ="saurav2">
<cfreturn true>
</cffunction>
</cfcomponent>
testpage.cfm
<cfset variables.onApplicationStart()>
I have tried to call the above method in different way also like
1--- <cfset onApplicationStart()>
i got error like this
Variable ONAPPLICATIONSTART is undefined.
2---<cfset Application.onApplicationStart()>
The onApplicationStart method was not found.
Either there are no methods with the specified method name and argument types or the onApplicationStart method is overloaded with argument types that ColdFusion cannot decipher reliably. ColdFusion found 0 methods that match the provided arguments. If this is a Java object and you verified that the method exists, use the javacast function to reduce ambiguity
Please help me out.
Thanks
SauravYou can't just call methods in a CFC without a reference to that CFC. This includes methods in Application.cfc.
What are you trying to do, exactly, anyway? You'd probably be better served by placing a call to onApplicationStart within onRequestStart in Application.cfc, if your goal is to refresh the application based on some condition:
<cffunction name="onRequestStart">
<cfif someCondition>
<cfset onApplicationStart()>
</cfif>
</cffunction>
Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/
http://training.figleaf.com/
Maybe you are looking for
-
I make annotations to my photos in iphoto using preview. But once I have made the annotation I do not get the photo back into the event in iphoto from which I took the photo. What am I doing wrong? I am not using aperture
-
TS4532 Bluetooth problem with iOS 6.1 - Help!
Since I updated to iOS 6.1 I can't Sync any of my bluetooth earpieces, Jawbone and Ant. Both worked fine until upgrade. Any suggestions? Thanks
-
Troubleshooting Performance Concerns
I have been having some serious 'disk thrashing' and beach balls when working inside Aperture. And this is while doing things like sorting photos, moving between projects, stacking/unstacking/extracting an item from a stack. Nothing I would deem 'pro
-
Loss of speaker sound with soundblaster li
hello;I have just incurred another incident as to where my speakers went dead and I lost the sound in my soundblaster li've! software. I recieved an error message "there is no mixer device detected on this system", system mixer will? now exit. when I
-
I have a servlet that I launch from the iPlanet Portal. The Servlet is running on another WebServer. If I open the portal using the FQDN (i.e. http://myhost.mydomain:9999/login) and launch the Servlet the Session information is correctly passed. Howe