Appian Community
Site
Search
Sign In/Register
Site
Search
User
DISCUSS
LEARN
SUCCESS
SUPPORT
Documentation
AppMarket
More
Cancel
I'm looking for ...
State
Not Answered
Replies
12 replies
Subscribers
6 subscribers
Views
5321 views
Users
0 members are here
Share
More
Cancel
Related Discussions
Home
»
Discussions
»
Integrations
Hi Guys, is there a way to call an Appian function within my Java Code (Smart Se
Jess
over 9 years ago
Hi Guys, is there a way to call an Appian function within my Java Code (Smart Service Plugin)? I need to use todocument() function to convert the input string (ex. "[DocumentId: xxxx]" ) to a document.
Also, once I got the document, I need to get the server path/filename of that file.
Thanks in advance!
OriginalPostID-192788
OriginalPostID-192788
Discussion posts and replies are publicly visible
0
Stefan Helzle
A Score Level 3
over 9 years ago
You can download existing plugins. They contain the source code and can help you understand how to develop your own plugins.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Rahul Gundu
over 9 years ago
Use tointeger() function in Appian to get the Document ID.
Pass the Long value to your Java Code. Using the Document Id, We get doc path, document etc..
Go though API,
forum.appian.com/.../
you'll find couple of document functions, which will do your job.
Sample Java Code
long docId;
String docPath=null;
Document document = new Document();
document = this.contentService.download(this.docId[i], ContentConstants.VERSION_CURRENT, Boolean.valueOf(false))[0];
String docName=document.getDisplayName();
String docInternalPath=document.getInternalFilename();
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
<