Hi All,
I am using below modern activities to convert my Excel into pDf but the aligment is not getting added properly in the PDF.
Excel has quite a no of columns but needs to be adjusted in one PDF .
PDF getting generated looks like this :-
How this can be achieved with this modern activites?
lrtetala
(Lakshman Reddy)
January 11, 2024, 12:35pm
2
Hi @shashank_dullu
Can you please try below sample
Code:
Excel to PDF.txt (478 Bytes)
Sequence.xaml (9.6 KB)
Cheers!!
Before converting to PDF you can try formatting the sheet using Format cell activity and define the whole range.
@lrtetala - This is not working .
How can I pass the path below line from txt.
ws.ExportAsFixedFormat Type:=xlTypePDF, Filename:=“C:\Users\lrtetala\Documents\UiPath\BlankProcess17\Pdf.pdf”, Quality:=xlQualityStandard
lrtetala
(Lakshman Reddy)
January 11, 2024, 3:58pm
5
@shashank_dullu
Change it to your location it creates the pdf file
If you want to pass the location dynamically then use below
BlankProcess17.zip (710.8 KB)
Cheers!!
lrtetala
(Lakshman Reddy)
January 11, 2024, 4:36pm
7
@shashank_dullu
If possible can your share your excel file, meanwhile try below code
Excel to PDF new.txt (645 Bytes)
Report_test.xlsx (10.4 KB)
Sample excel which needs to be converted
lrtetala
(Lakshman Reddy)
January 11, 2024, 5:56pm
9
@shashank_dullu
Can you try below
Excel to PDF new.txt (489 Bytes)
Output:
ExcelPDF.pdf (52.9 KB)
Sequence.xaml (16.8 KB)
Cheers!!
lrtetala
(Lakshman Reddy)
January 11, 2024, 6:03pm
11
@shashank_dullu
Can you please extract the below file and change the pdf path and run the bot
BlankProcess17.zip (704.3 KB)
and also can you please check whether in your Excel Macro settings are enabled or not
Click on File->Options->Trust Center->Trust Center Settings->Macro Settings
Still getting the error @lrtetala - Can we connect via Zoom for this ?
lrtetala
(Lakshman Reddy)
January 12, 2024, 9:01am
13
Ok @shashank_dullu
Can you share the link of Zoom
MeetingID- 9553920440
passcode - 0WFb30
@lrtetala - Can you please ping me
That run time error is again causing blocker post excel property to false.
Anyother way to achieve this ??