Skip to content

Commit

Permalink
902906: Playground integration changes
Browse files Browse the repository at this point in the history
  • Loading branch information
GowthamPonrajSF5414 committed Aug 23, 2024
1 parent df81917 commit 94c1e10
Show file tree
Hide file tree
Showing 23 changed files with 46 additions and 48 deletions.
8 changes: 8 additions & 0 deletions Editing Excel cells/Filter/.NET/Filter/Filter/Filter.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,14 @@

<ItemGroup>
<PackageReference Include="Syncfusion.XlsIO.NET" Version="*" />
<None Update="Data\InputTemplate.xlsx">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Output\.gitkeep">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
</ItemGroup>



</Project>
Empty file.
Binary file not shown.
10 changes: 2 additions & 8 deletions Editing Excel cells/Filter/.NET/Filter/Filter/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ static void Main(string[] args)
{
IApplication application = excelEngine.Excel;
application.DefaultVersion = ExcelVersion.Xlsx;
FileStream inputStream = new FileStream("../../../InputTemplate.xlsx", FileMode.Open, FileAccess.Read);
FileStream inputStream = new FileStream(Path.GetFullPath(@"Data/InputTemplate.xlsx"), FileMode.Open, FileAccess.Read);
IWorkbook workbook = application.Workbooks.Open(inputStream);
IWorksheet worksheet = workbook.Worksheets[0];

Expand All @@ -32,20 +32,14 @@ static void Main(string[] args)

#region Save
//Saving the workbook
FileStream outputStream = new FileStream("Filter.xlsx", FileMode.Create, FileAccess.Write);
FileStream outputStream = new FileStream(Path.GetFullPath(@"Output/Filter.xlsx"), FileMode.Create, FileAccess.Write);
workbook.SaveAs(outputStream);
#endregion

//Dispose streams
outputStream.Dispose();
inputStream.Dispose();

System.Diagnostics.Process process = new System.Diagnostics.Process();
process.StartInfo = new System.Diagnostics.ProcessStartInfo("Filter.xlsx")
{
UseShellExecute = true
};
process.Start();
}
}
}
Expand Down
6 changes: 6 additions & 0 deletions Editing Excel cells/Find/.NET/Find/Find/Find.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@

<ItemGroup>
<PackageReference Include="Syncfusion.XlsIO.Net.Core" Version="*" />
<None Update="Output\.gitkeep">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Data\InputTemplate.xlsx">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
</ItemGroup>

</Project>
Empty file.
10 changes: 2 additions & 8 deletions Editing Excel cells/Find/.NET/Find/Find/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ public static void Main(string[] args)
{
IApplication application = excelEngine.Excel;
application.DefaultVersion = ExcelVersion.Xlsx;
FileStream fileStream = new FileStream("../../../Data/InputTemplate.xlsx", FileMode.Open, FileAccess.Read);
FileStream fileStream = new FileStream(Path.GetFullPath(@"Data/InputTemplate.xlsx"), FileMode.Open, FileAccess.Read);
IWorkbook workbook = application.Workbooks.Open(fileStream);
IWorksheet worksheet = workbook.Worksheets[0];

Expand All @@ -36,16 +36,10 @@ public static void Main(string[] args)
IRange[] result7 = worksheet.FindAll("5", ExcelFindType.Text, ExcelFindOptions.MatchEntireCellContent);

//Saving the workbook as stream
FileStream stream = new FileStream("Find.xlsx", FileMode.Create, FileAccess.ReadWrite);
FileStream stream = new FileStream(Path.GetFullPath(@"Output/Find.xlsx"), FileMode.Create, FileAccess.ReadWrite);
workbook.SaveAs(stream);
stream.Dispose();

System.Diagnostics.Process process = new System.Diagnostics.Process();
process.StartInfo = new System.Diagnostics.ProcessStartInfo("Find.xlsx")
{
UseShellExecute = true
};
process.Start();
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@

<ItemGroup>
<PackageReference Include="Syncfusion.XlsIO.NET" Version="*" />
<None Update="Output\.gitkeep">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
</ItemGroup>

</Project>
Empty file.
Original file line number Diff line number Diff line change
Expand Up @@ -51,19 +51,13 @@ static void Main(string[] args)

#region Save
//Saving the workbook
FileStream outputStream = new FileStream("Hyperlinks.xlsx", FileMode.Create, FileAccess.Write);
FileStream outputStream = new FileStream(Path.GetFullPath(@"Output/Hyperlinks.xlsx"), FileMode.Create, FileAccess.Write);
workbook.SaveAs(outputStream);
#endregion

//Dispose streams
outputStream.Dispose();

System.Diagnostics.Process process = new System.Diagnostics.Process();
process.StartInfo = new System.Diagnostics.ProcessStartInfo("Hyperlinks.xlsx")
{
UseShellExecute = true
};
process.Start();
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ static void Main(string[] args)
{
IApplication application = excelEngine.Excel;
application.DefaultVersion = ExcelVersion.Xlsx;
FileStream inputStream = new FileStream("../../../InputTemplate.xlsx", FileMode.Open, FileAccess.Read);
FileStream inputStream = new FileStream(Path.GetFullPath(@"Data/InputTemplate.xlsx"), FileMode.Open, FileAccess.Read);
IWorkbook workbook = application.Workbooks.Open(inputStream);
IWorksheet worksheet = workbook.Worksheets[0];

Expand Down Expand Up @@ -49,20 +49,13 @@ static void Main(string[] args)

#region Save
//Saving the workbook
FileStream outputStream = new FileStream("SortOnCellColor.xlsx", FileMode.Create, FileAccess.Write);
FileStream outputStream = new FileStream(Path.GetFullPath(@"Output/SortOnCellColor.xlsx"), FileMode.Create, FileAccess.Write);
workbook.SaveAs(outputStream);
#endregion

//Dispose streams
outputStream.Dispose();
inputStream.Dispose();

System.Diagnostics.Process process = new System.Diagnostics.Process();
process.StartInfo = new System.Diagnostics.ProcessStartInfo("SortOnCellColor.xlsx")
{
UseShellExecute = true
};
process.Start();
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,12 @@

<ItemGroup>
<PackageReference Include="Syncfusion.XlsIO.NET" Version="*" />
<None Update="Data\InputTemplate.xlsx">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Output\.gitkeep">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ static void Main(string[] args)
{
IApplication application = excelEngine.Excel;
application.DefaultVersion = ExcelVersion.Xlsx;
FileStream inputStream = new FileStream("../../../InputTemplate.xlsx", FileMode.Open, FileAccess.Read);
FileStream inputStream = new FileStream(Path.GetFullPath(@"Data/InputTemplate.xlsx"), FileMode.Open, FileAccess.Read);
IWorkbook workbook = application.Workbooks.Open(inputStream);
IWorksheet worksheet = workbook.Worksheets[0];

Expand Down Expand Up @@ -43,20 +43,14 @@ static void Main(string[] args)

#region Save
//Saving the workbook
FileStream outputStream = new FileStream("SortOnValues.xlsx", FileMode.Create, FileAccess.Write);
FileStream outputStream = new FileStream(Path.GetFullPath(@"Output/SortOnValues.xlsx"), FileMode.Create, FileAccess.Write);
workbook.SaveAs(outputStream);
#endregion

//Dispose streams
outputStream.Dispose();
inputStream.Dispose();

System.Diagnostics.Process process = new System.Diagnostics.Process();
process.StartInfo = new System.Diagnostics.ProcessStartInfo("SortOnValues.xlsx")
{
UseShellExecute = true
};
process.Start();
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,12 @@

<ItemGroup>
<PackageReference Include="Syncfusion.XlsIO.NET" Version="*" />
<None Update="Output\.gitkeep">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Data\InputTemplate.xlsx">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ static void Main(string[] args)
{
IApplication application = excelEngine.Excel;
application.DefaultVersion = ExcelVersion.Xlsx;
FileStream inputStream = new FileStream("../../../InputTemplate.xlsx", FileMode.Open, FileAccess.Read);
FileStream inputStream = new FileStream(Path.GetFullPath(@"Data/InputTemplate.xlsx"), FileMode.Open, FileAccess.Read);
IWorkbook workbook = application.Workbooks.Open(inputStream);
IWorksheet worksheet = workbook.Worksheets[0];

Expand Down Expand Up @@ -49,20 +49,14 @@ static void Main(string[] args)

#region Save
//Saving the workbook
FileStream outputStream = new FileStream("SortOnFontColor.xlsx", FileMode.Create, FileAccess.Write);
FileStream outputStream = new FileStream(Path.GetFullPath(@"Output/SortOnFontColor.xlsx"), FileMode.Create, FileAccess.Write);
workbook.SaveAs(outputStream);
#endregion

//Dispose streams
outputStream.Dispose();
inputStream.Dispose();

System.Diagnostics.Process process = new System.Diagnostics.Process();
process.StartInfo = new System.Diagnostics.ProcessStartInfo("SortOnFontColor.xlsx")
{
UseShellExecute = true
};
process.Start();
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,12 @@

<ItemGroup>
<PackageReference Include="Syncfusion.XlsIO.NET" Version="*" />
<None Update="Output\.gitkeep">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Data\InputTemplate.xlsx">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
</ItemGroup>

</Project>

0 comments on commit 94c1e10

Please sign in to comment.