Hello
Is there a way to export only single page during Export? I know that it’s possible to mention the page numbers with Print API. But we are using Export function.
Regards
Philip
Hello
Is there a way to export only single page during Export? I know that it’s possible to mention the page numbers with Print API. But we are using Export function.
Regards
Philip
Have you seen the API LlPrintSetOption? Here you are able to define the options you search for I think.
Hi Philip,
it is not clear which version you are using currently. But last week we have made some adaptions because of an similar requirement with the event DefinePrintOptions using page limiter in version 30 of List & Label. So please try to get the latest modules for List & Label 30. You can find them in your account in section Service Packs and “List Label 30 LatestPrerelease Service Pack”.
But remember: If your are using .NET NuGet Packages for List & Label, please use temporary a hard reference to the List & Label .NET assembly in your application to test the new modules. The NuGet Packages hosted on nuget.org are only updated after official Service Pack Release.
If this will not help or solve your requirement, please open a support case at out Support Center.
Hi Daniel
Thanks for your response. I am using combit.ListLabel30.Enterprise(30.0.0) nuget package. When can we expect the new service pack release?
Regards
Philip
Hi Philip,
We have not yet set a final date for the release of the first service pack for version 30. In all probability, Q1/2025 is likely.
In the meantime, however, you can use and test the latest prerelease service pack to see whether the requirement can be implemented as desired or whether further adjustments may need to be made before the official release of the service pack.
Regards,
Daniel
Hello Daniel
I have tried the same code (Option to Export only one page. - #3 by Philip_Mathew) above on the new version 30.1. Still its printing all the pages. Do you have any suggestions?
Regards
Philip
Hello Philip,
Thank you for the feedback and sorry for the inconvenience.
But with the new modules from Service Pack 30.001 I could not reproduce the behavior. The change was made in the module cmll30.dll (using x86) or cxll30.dll (using x64) - so please check if that module is really loaded within your project/process.
The other point I could see in our code is: you are not using the sender-object within the defined event DefinePrintOptions like that:
...
private void LL_DefinePrintOptions(object sender, EventArgs e)
{
(sender as ListLabel).Core.LlPrintSetOption(LlPrintOption.LastPage, 2);
}
...
If this will not help further, please create a support case and provide a small programming sample, so we can check more details.
Hello Daniel
Thanks for quick reply. I have re-checked it and found that the layout I used had embeded ToC and Index sections. So the ToC and Index were created along with single page causing the confusion. Is there any way we can exclude ToC and Index creations also along with single page creation?
Thanks & Regards
Philip
Hello Philip,
ok - that is a new and important information. Can you try to remove these report elements via DOM at runtime?
...
private void LL_DefinePrintOptions(object sender, EventArgs e)
{
if (JustSingelPage)
{
// remove TOC and IDX by DOM
ProjectList lst = new ProjectList((sender as ListLabel));
lst.GetFromParent();
lst.ReportSections.TableOfContents.FileName = "";
lst.ReportSections.Index.FileName = "";
(sender as ListLabel).Core.LlPrintSetOption(LlPrintOption.LastPage, 2);
}
}
...
What happens in DefinePrintOptions and getting the current loaded print/export project via DOM with the help of GetFromParent is just temporarly and does not persists on the real project file.
Hello Daniel
Yes, that worked! Thanks!
Regards
Philip Mathew
Hello Philip,
Thank you for your feedback. Glad to hear that the proposed solution works for you.
Regards,
Daniel