Skip to main content
Question

Unable to edit document in Aurena - IFS Cloud DOCMAN


Forum|alt.badge.img+18

Hi Team,

I have an issue where I am unable to edit the documents in Aurena and I am not getting any error when I click on edit option and the screen remain same. FYI, I have installed Aurena Agent and using Chrome Browser.

Here I am connecting a document for eg. customer order by using option New Document from Template where I am choosing a document class which is having a template revision. Once the new document is created it inherits the document connected to template revision and check out the document and till here everything is fine. But when I try to edit this document nothing is happening.

Could anyone please help If I am missing something here configure to have this function work seamlessly. 

 

Regards,

Mithun K V

2 replies

Forum|alt.badge.img+18
  • Author
  • Superhero (Partner)
  • 392 replies
  • June 20, 2022
EqeMithuV wrote:

Hi Team,

I have an issue where I am unable to edit the documents in Aurena and I am not getting any error when I click on edit option and the screen remain same. FYI, I have installed Aurena Agent and using Chrome Browser.

Here I am connecting a document for eg. customer order by using option New Document from Template where I am choosing a document class which is having a template revision. Once the new document is created it inherits the document connected to template revision and check out the document and till here everything is fine. But when I try to edit this document nothing is happening.

Could anyone please help If I am missing something here configure to have this function work seamlessly. 

 

Regards,

Mithun K V

Hi All,

 

I have sorted this issue by creating the macro to view the document when it is checked out  and it is working as expected. But, I am still unable to view the file after I edit and checked in. I tried to use same macro  unfortunately its not working for document process 'View’. Can someone help me on this??? 

@Dilini Arandara @Mathias Dahl 

 

PUBLIC FUNCTION WORD_VIEW_MSOFFICE()
ON ERROR RESUME NEXT
O_APP.NORMALTEMPLATE.SAVED = TRUE
O_APP.VISIBLE = FALSE
O_APP.APPLICATION.DISPLAYALERTS = 0
SET O_DOC = O_APP.DOCUMENTS.OPEN(IFS_CHECK_OUT_PATH & O_FILENAME)
FOR EACH STRPROPERTY IN O_APP.ACTIVEDOCUMENT.CUSTOMDOCUMENTPROPERTIES
O_APP.ACTIVEDOCUMENT.CUSTOMDOCUMENTPROPERTIES(STRPROPERTY.NAME).DELETE
NEXT

FOR I = 0 to UBOUND(O_DOCARRAY,2)
IF LEN(O_DOCARRAY(1,I)) > 254 THEN
N = 0
FOR D = 1 to LEN(O_DOCARRAY(1,I)) STEP 254
IF N > 0 THEN
O_APP.ACTIVEDOCUMENT.CUSTOMDOCUMENTPROPERTIES.ADD "IFS_" & O_DOCARRAY(0,I) & "_" & N, FALSE, "4",  MID(O_DOCARRAY(1,I),D,254)
ELSE
O_APP.ACTIVEDOCUMENT.CUSTOMDOCUMENTPROPERTIES.ADD "IFS_" & O_DOCARRAY(0,I), FALSE, "4",  MID(O_DOCARRAY(1,I),D,254)
END IF
N = N + 1
NEXT
ELSE
O_APP.ACTIVEDOCUMENT.CUSTOMDOCUMENTPROPERTIES.ADD "IFS_" & O_DOCARRAY(0,I), FALSE, "4",  O_DOCARRAY(1,I)
END IF
NEXT

OBJECT_CONNECTIONS("CONNECTED_OBJECT_TYPES")

O_APP.ACTIVEWINDOW.ACTIVEPANE.VIEW.SEEKVIEW = 0

'UPDATES FIELD VALUES
FOR EACH OSTORY IN O_APP.ACTIVEDOCUMENT.STORYRANGES 
OSTORY.FIELDS.UPDATE 
NEXT 

FOR EACH OSHP IN O_APP.ACTIVEDOCUMENT.SHAPES
  IF OSHP.TYPE = 17 THEN
    O_APP.ACTIVEDOCUMENT.SHAPES(OSHP.NAME).TEXTFRAME.TEXTRANGE.FIELDS.UPDATE
  END IF
NEXT
PW = O_DOC.PAGESETUP.PAGEWIDTH
PH = O_DOC.PAGESETUP.PAGEHEIGHT
IF O_DOC.PROTECTIONTYPE <> -1 THEN
O_DOC.UNPROTECT
END IF
IF O_DOC.PROTECTIONTYPE = -1 THEN
WATERMARK = "UNCONTROLLED COPY " & CHR(10) & SCRIPTVALUES.ITEM("FND_USER").VALUE & " - " & DATE()

FOR EACH SEC IN O_DOC.SECTIONS
FOR EACH HDR IN SEC.HEADERS
SET SHP = HDR.SHAPES.ADDTEXTEFFECT("1",WATERMARK, "ARIAL", 1, TRUE, FALSE, 0, 0)
WITH SHP
    .TEXTEFFECT.NORMALIZEDHEIGHT = FALSE
    .LINE.VISIBLE = FALSE
    .FILL.VISIBLE = TRUE
    .FILL.SOLID
    .FILL.FORECOLOR.RGB = RGB(192, 192, 192)
    .FILL.TRANSPARENCY = 0.5
    .ROTATION = 315
    .LOCKASPECTRATIO = TRUE
    .HEIGHT = O_APP.INCHESTOPOINTS(1.33)
    .WIDTH = O_APP.INCHESTOPOINTS(7.55)
    .WRAPFORMAT.ALLOWOVERLAP = TRUE
    .WRAPFORMAT.SIDE = 3
    .WRAPFORMAT.TYPE = 3
    .RELATIVEHORIZONTALPOSITION = 0
    .RELATIVEVERTICALPOSITION = 0
    .LEFT = -999995
    .TOP = -999995
END WITH
NEXT
NEXT
O_APP.ACTIVEWINDOW.ACTIVEPANE.VIEW.SEEKVIEW = 0
O_APP.DOCUMENTS(1).PRINTPREVIEW
O_APP.DOCUMENTS(1).CLOSEPRINTPREVIEW
O_APP.ACTIVEDOCUMENT.SAVE


'GENERATE DYNAMIC PASSWORD
STRCHARACTERS = "ABCDEFGHJKMNPQRSTUVWXYZABCDEFGHJKLMNPQRSTUVW1234567890"
RANDOMIZE
DIM STRS, INTI
FOR INTI = 1 TO 8
STRS = STRS + MID(STRCHARACTERS, INT(RND() * LEN(STRCHARACTERS))+1, 1)
NEXT
O_DOC.PROTECT 2,TRUE, STRS
END IF

PDFFILE = O_DOC.PATH & "\" & LEFT(O_DOC.NAME,INSTR(O_DOC.NAME,".")-1) & ".PDF"
PDF = O_APP.ACTIVEDOCUMENT.EXPORTASFIXEDFORMAT (PDFFILE, 17, TRUE,  0, 0, 0)

O_DOC.CLOSE 0
O_APP.QUIT

SET FSO = CREATEOBJECT("SCRIPTING.FILESYSTEMOBJECT")
IF FSO.FILEEXISTS(IFS_CHECK_OUT_PATH & O_FILENAME) THEN
FSO.DELETEFILE IFS_CHECK_OUT_PATH & O_FILENAME,1
END IF

SET FSO = NOTHING
SET O_DOC = NOTHING
SET O_APP = NOTHING


END FUNCTION


Mathias Dahl
Superhero (Employee)
Forum|alt.badge.img+32
  • Superhero (Employee)
  • 2810 replies
  • August 3, 2022

Hi,

When the file is to be viewed there is no file name in the LOCAL_FILE_NAME attribute (since that is only set if the file is checked out). Instead use the LOCAL_FILE_1 attribute from the ClientScriptValues collection. It's documented here:

https://docs.ifs.com/ifsclouddocs/22r1/CreateAndMaintainDocument/AboutDocumentMacro.htm?StandAlone=true

Let me know if this helps.


 


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings