This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Get the names of columns with missing values | |
cols_with_missing = [col for col in X_train.columns if X_train[col].isnull().any()] | |
# Drop columns in training and validation data containing missing values | |
reduced_X_train = X_train.drop(cols_with_missing, axis=1) | |
reduced_X_valid = X_valid.drop(cols_with_missing, axis=1) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Path to original steps: https://absolute-sharepoint.com/2016/09/test-the-word-automation-service-application-with-powershell.html | |
# Confirm if this path is same on your env | |
Add-Type -Path 'C:\Windows\Microsoft.NET\assembly\GAC_MSIL\Microsoft.Office.Word.Server\v4.0_16.0.0.0__71e9bce111e9429c\Microsoft.Office.Word.Server.dll' | |
# Configure the job | |
$jobSettings = New-Object Microsoft.Office.Word.Server.Conversions.ConversionJobSettings | |
$jobSettings.OutputFormat = "PDF" | |
# Configure your word automation service name and credentials | |
$job = New-Object Microsoft.Office.Word.Server.Conversions.ConversionJob("Word Automation", $jobSettings) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Diagnostics; | |
namespace ConsoleApp_WordToPDF | |
{ | |
class Program | |
{ | |
static void Main(string[] args) | |
{ | |
// The code provided will print ‘Hello World’ to the console. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using Microsoft.Office.Interop.Word; | |
using Word = Microsoft.Office.Interop.Word; | |
namespace WordToPDFConsoleApp | |
{ | |
class Program | |
{ | |
static void Main(string[] args) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.IO; | |
//wordtopdf.dll downloaded from https://www.c-sharpcorner.com/uploadfile/698727/convert-word-file-to-pdf-using-c-sharp/ | |
using WordToPDF; | |
namespace WordPDFConsoleApp | |
{ | |
class Program | |
{ |