PC SOFT

FOROS PROFESIONALES
WINDEVWEBDEV y WINDEV Mobile

Inicio → WINDEV 2024 → Sharepoint Integration
Sharepoint Integration
Iniciado por argie.catalan, 29,ene. 2021 14:30 - No hay respuesta
Publicado el 29,enero 2021 - 14:30
Hi, Im using Copy.xml (WSDL) of Sharepoint and Im trying to Copy a file from a Network drive to the SharePoint Library.

I was able to import the Copy.xml wsdl to the webdev environment but I cannot get it to work.
Im using webdev 21.

below is the code that I made, (I have to cover the paths and links):

ls_FilePath is string = "\\*****\*****\******\TestFileSharepoint.docx"
ls_DestPath is string = "https://******.sharepoint.com/sites/******/WinDev"
ls_arrDestPath is an array of string
ArrayAdd(ls_arrDestPath,ls_DestPath & "TestFileSharepoint.docx")

l_copyresult1 is CopyResult
l_copyresult2 is CopyResult
l_arrCopyResult is array of CopyResult
ArrayAdd(l_arrCopyResult, l_copyresult1)
ArrayAdd(l_arrCopyResult, l_copyresult2)

l_myFieldInfo is a FieldInformation
l_myFieldInfo:DisplayName = "Description"
l_myFieldInfo:Value = "Sample Description"

l_arrMyfieldInfo is an array of FieldInformation

ArrayAdd(l_arrMyfieldInfo,l_myFieldInfo)
L_buffFile is a Buffer = fLoadBuffer(ls_FilePath)


li is an unsigned int

li = CopyIntoItems(ls_arrDestPath, ls_arrDestPath, l_arrMyfieldInfo, L_buffFile, l_arrCopyResult)



IF li = 0 THEN
li_idx is int = 0

FOR EACH l_myCopyresult OF l_arrCopyResult
sL_opstring is string = li_idx +1

IF l_arrCopyResult[li_idx]:ErrorMessage = Null THEN
Info("Successfully copied!")
ELSE
Info("Failed to copy!")
END

END
END


Anyone have a sample to begin with the integration?

Thanks!