Skip to content

559692 - Include the sample for the documentation “Adding your standard stamps in the toolbar”. - #51

Merged
RajaVigneshB merged 4 commits into
masterfrom
WPF-558682
Mar 28, 2025
Merged

RajaVigneshB merged 4 commits into
masterfrom
WPF-558682

Conversation

@Dhileep4290

Copy link
Copy Markdown
Collaborator

Description :

  • Added Git sample for adding Standard stamps in the toolbar

@@ -0,0 +1,107 @@
<?xml version="1.0" encoding="utf-8"?>

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change the sample name as "AddStandardStampInToolbar" in all necessary places

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed the sample name as suggested

<None Include="App.config" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="packages\Syncfusion.PdfToImageConverter.WPF.29.1.33\build\net462\Syncfusion.PdfToImageConverter.WPF.targets" Condition="Exists('packages\Syncfusion.PdfToImageConverter.WPF.29.1.33\build\net462\Syncfusion.PdfToImageConverter.WPF.targets')" />

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this required? Check other samples

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No it is not required removed this

<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.8" />
</startup>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove this unwanted bindings

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed unwanted bindings

Comment thread Annotations/AddStandardStampsinToolBar/MainWindow.xaml
this.WindowState = WindowState.Maximized;
//Loads the Document
#if NETFRAMEWORK
pdfViewer.Load("../../Data/PDF_Succinctly.pdf");

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change the file as F# pdf

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed the file name as F#

//Load the custom image from the local disk.
System.Windows.Controls.Image image = new System.Windows.Controls.Image();
#if NETFRAMEWORK
image.Source = new BitmapImage(new Uri(@"../../Data/CustomStamp.png", UriKind.RelativeOrAbsolute));

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change the image

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed the image

this.WindowState = WindowState.Maximized;
//Loads the Document
#if NETFRAMEWORK
pdfViewer.Load("../../Data/F#.pdf");

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Keep the path in global variable as string path ="../../Data"; and reuse it

#endif
}

private void addStamp_Click(object sender, RoutedEventArgs e)

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add summary for the method

@RajaVigneshB
RajaVigneshB merged commit d6456e2 into master Mar 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants