ByteScout PDF Suite - C++ - Split Protected PDF Document (C++ CLR) with PDF Extractor SDK - ByteScout

ByteScout PDF Suite – C++ – Split Protected PDF Document (C++ CLR) with PDF Extractor SDK

  • Home
  • /
  • Articles
  • /
  • ByteScout PDF Suite – C++ – Split Protected PDF Document (C++ CLR) with PDF Extractor SDK

How to split protected PDF document (c++ clr) with PDF extractor SDK in C++ and ByteScout PDF Suite

How to write a robust code in C++ to split protected PDF document (c++ clr) with PDF extractor SDK with this step-by-step tutorial

The coding instructions are formulated to help you to try-out the features without the requirement to write your own code. ByteScout PDF Suite can split protected PDF document (c++ clr) with PDF extractor SDK. It can be applied from C++. ByteScout PDF Suite is the set that includes 6 SDK products to work with PDF from generating rich PDF reports to extracting data from PDF documents and converting them to HTML. This bundle includes PDF (Generator) SDK, PDF Renderer SDK, PDF Extractor SDK, PDF to HTML SDK, PDF Viewer SDK and PDF Generator SDK for Javascript.

Want to save time? You will save a lot of time on writing and testing code as you may just take the C++ code from ByteScout PDF Suite for split protected PDF document (c++ clr) with PDF extractor SDK below and use it in your application. Simply copy and paste in your C++ project or application you and then run your app! Enjoy writing a code with ready-to-use sample C++ codes.

Our website gives trial version of ByteScout PDF Suite for free. It also includes documentation and source code samples.

On-demand (REST Web API) version:
 Web API (on-demand version)

On-premise offline SDK for Windows:
 60 Day Free Trial (on-premise)

CPPCLRConsoleApplication.cpp
      
#include "stdafx.h" // // This example demonstrates how to provide password for protected PDF files. // using namespace System; using Bytescout::PDFExtractor::DocumentSplitter; // `PasswordRequired` event handler void OnPasswordRequired(System::Object ^sender, System::String ^document, System::String ^%password); int main(array<System::String ^> ^args) { String^ input(".\\encrypted (password is 'password').pdf"); String^ output1(".\\result1.pdf"); String^ output2(".\\result2.pdf"); // Create DocumentSplitter instance DocumentSplitter^ merger = gcnew DocumentSplitter("demo", "demo"); // Handle `PasswordRequired` event merger->PasswordRequired += gcnew Bytescout::PDFExtractor::PasswordEventHandler(&OnPasswordRequired); // Ignore document permissions merger->CheckPermissions = false; // Split document merger->Split(input, output1, output2, 3); delete merger; // Open the output documents in default associated application (for demonstration) Diagnostics::Process::Start(output1); Diagnostics::Process::Start(output2); return 0; } // `PasswordRequired` event handler void OnPasswordRequired(System::Object ^sender, System::String ^document, System::String ^%password) { // Ask user for password and put it to `Password` property. password = "password"; }

ON-PREMISE OFFLINE SDK

60 Day Free Trial or Visit ByteScout PDF Suite Home Page

Explore ByteScout PDF Suite Documentation

Explore Samples

Sign Up for ByteScout PDF Suite Online Training

ON-DEMAND REST WEB API

Get Your API Key

Explore Web API Docs

Explore Web API Samples

Resource.h
      
//{{NO_DEPENDENCIES}} // Microsoft Visual C++ generated include file. // Used by app.rc

ON-PREMISE OFFLINE SDK

60 Day Free Trial or Visit ByteScout PDF Suite Home Page

Explore ByteScout PDF Suite Documentation

Explore Samples

Sign Up for ByteScout PDF Suite Online Training

ON-DEMAND REST WEB API

Get Your API Key

Explore Web API Docs

Explore Web API Samples

stdafx.cpp
      
#include "stdafx.h"

ON-PREMISE OFFLINE SDK

60 Day Free Trial or Visit ByteScout PDF Suite Home Page

Explore ByteScout PDF Suite Documentation

Explore Samples

Sign Up for ByteScout PDF Suite Online Training

ON-DEMAND REST WEB API

Get Your API Key

Explore Web API Docs

Explore Web API Samples

stdafx.h
      
#pragma once // TODO: reference additional headers your program requires here

ON-PREMISE OFFLINE SDK

60 Day Free Trial or Visit ByteScout PDF Suite Home Page

Explore ByteScout PDF Suite Documentation

Explore Samples

Sign Up for ByteScout PDF Suite Online Training

ON-DEMAND REST WEB API

Get Your API Key

Explore Web API Docs

Explore Web API Samples

VIDEO

ON-PREMISE OFFLINE SDK

60 Day Free Trial or Visit ByteScout PDF Suite Home Page

Explore ByteScout PDF Suite Documentation

Explore Samples

Sign Up for ByteScout PDF Suite Online Training

ON-DEMAND REST WEB API

Get Your API Key

Explore Web API Docs

Explore Web API Samples

Tutorials:

prev
next