Skip to content

feat(visio-activex-controls): add 30 compiler-validated C# examples - Visio Activex Controls [26.8.0/net8.0] - #83

Merged
amjad-sahi merged 37 commits into
mainfrom
feat/examples-visio-activex-controls-20260828
Aug 28, 2026
Merged

feat(visio-activex-controls): add 30 compiler-validated C# examples - Visio Activex Controls [26.8.0/net8.0]#83
amjad-sahi merged 37 commits into
mainfrom
feat/examples-visio-activex-controls-20260828

Conversation

@agent-aspose-diagram-examples

Copy link
Copy Markdown
Collaborator

Visio Activex Controls — Compiler-Validated C# Examples

What this PR does

Adds 30 AI-generated, compiler-validated C# examples for the Visio Activex Controls category of Aspose.Diagram for .NET.

All examples were generated by the Aspose.Diagram Examples Generator Agent and passed the full three-attempt validation pipeline before being included.

Validation Summary

Check Result
dotnet build ✅ Passed — zero compiler errors
dotnet run ✅ Passed — clean execution
Aspose.Diagram Version 26.8.0
Target Framework net8.0
Examples Added 30

Pipeline

Each example was generated and validated through:

  1. Attempt 1 — MCP direct code retrieval and assembly
  2. Attempt 2 — MCP retrieval with injected API correction rules
  3. Attempt 3 — LLM repair pass with compiler errors and rules

Only examples that passed both dotnet build and dotnet run are included in this PR.

Examples Added

File Task Description
add-a-new-slider-activex-control-to-a-shape-programmatically-and-initialize-its-minimum-maximum-and-value-properties.cs Add a new slider activex control to a shape programmatically and initialize its minimum maximum and value properties
benchmark-the-time-required-to-retrieve-and-modify-activex-controls-across-diagrams-of-varying-sizes-and-complexities.cs Benchmark the time required to retrieve and modify activex controls across diagrams of varying sizes and complexities
cast-the-generic-activexcontrol-instance-to-its-specific-control-class-before-modifying-any-properties.cs Cast the generic activexcontrol instance to its specific control class before modifying any properties
check-whether-a-shape-s-activexcontrol-property-is-null-before-accessing-its-members.cs Check whether a shape s activexcontrol property is null before accessing its members
compare-two-visio-diagrams-by-checking-differences-in-activex-control-property-values-across-matching-shapes.cs Compare two visio diagrams by checking differences in activex control property values across matching shapes
create-a-reusable-helper-method-that-abstracts-casting-of-activexcontrol-objects-to-their-concrete-types.cs Create a reusable helper method that abstracts casting of activexcontrol objects to their concrete types
create-a-script-that-disables-all-activex-controls-on-a-diagram-before-exporting-it-to-pdf-for-security.cs Create a script that disables all activex controls on a diagram before exporting it to pdf for security
create-a-unit-test-that-verifies-property-changes-on-a-retrieved-checkbox-activex-control-are-persisted-after-saving.cs Create a unit test that verifies property changes on a retrieved checkbox activex control are persisted after saving
deserialize-json-configuration-and-apply-the-values-to-corresponding-activex-control-properties-within-a-visio-diagram.cs Deserialize json configuration and apply the values to corresponding activex control properties within a visio diagram
design-a-feature-that-disables-activex-controls-when-the-diagram-is-opened-in-read-only-mode-to-prevent-changes.cs Design a feature that disables activex controls when the diagram is opened in read only mode to prevent changes
determine-the-concrete-activex-control-type-of-a-retrieved-object-by-inspecting-its-progid-property-value.cs Determine the concrete activex control type of a retrieved object by inspecting its progid property value
extract-the-helpfile-property-from-a-commandbutton-activex-control-to-locate-associated-documentation-resources.cs Extract the helpfile property from a commandbutton activex control to locate associated documentation resources
handle-invalidcastexception-when-attempting-to-cast-an-activexcontrol-to-an-incompatible-control-class-type.cs Handle invalidcastexception when attempting to cast an activexcontrol to an incompatible control class type
implement-a-safeguard-that-prevents-modifying-read-only-properties-of-an-activex-control-and-logs-a-warning.cs Implement a safeguard that prevents modifying read only properties of an activex control and logs a warning
implement-error-handling-to-catch-comexception-when-accessing-activex-control-properties-that-require-specific-permissio.cs Implement error handling to catch comexception when accessing activex control properties that require specific permissio
integrate-activex-control-manipulation-into-an-asp-net-mvc-application-to-dynamically-update-diagram-visuals.cs Integrate activex control manipulation into an asp net mvc application to dynamically update diagram visuals
iterate-over-all-shapes-in-a-diagram-processing-only-those-that-contain-an-activexcontrol-object.cs Iterate over all shapes in a diagram processing only those that contain an activexcontrol object
load-a-visio-diagram-containing-activex-controls-and-enumerate-all-shapes-that-embed-such-controls.cs Load a visio diagram containing activex controls and enumerate all shapes that embed such controls
load-a-visio-diagram-from-a-memory-stream-and-update-activex-control-properties-without-writing-to-disk.cs Load a visio diagram from a memory stream and update activex control properties without writing to disk
log-each-property-change-made-to-an-activex-control-including-previous-and-new-values-for-audit-purposes.cs Log each property change made to an activex control including previous and new values for audit purposes
read-the-current-caption-property-of-a-button-activex-control-embedded-in-a-visio-shape.cs Read the current caption property of a button activex control embedded in a visio shape
remove-an-activexcontrol-from-a-shape-by-setting-its-activexcontrol-property-to-null-and-saving-diagram.cs Remove an activexcontrol from a shape by setting its activexcontrol property to null and saving diagram
retrieve-the-activexcontrol-object-from-a-specific-shape-using-shape-activexcontrol-property-for-further-processing.cs Retrieve the activexcontrol object from a specific shape using shape activexcontrol property for further processing
save-the-modified-visio-diagram-to-a-new-file-preserving-original-activex-control-configurations-and-layout.cs Save the modified visio diagram to a new file preserving original activex control configurations and layout
serialize-the-property-values-of-an-activex-control-to-json-for-external-configuration-management.cs Serialize the property values of an activex control to json for external configuration management
set-the-enabled-property-of-a-checkbox-activex-control-to-false-to-disable-user-interaction.cs Set the enabled property of a checkbox activex control to false to disable user interaction
update-one-or-more-properties-of-the-activex-control-and-persist-the-modified-diagram-to-a-new-file.cs Update one or more properties of the activex control and persist the modified diagram to a new file
use-reflection-to-enumerate-all-publicly-settable-properties-of-a-specific-activex-control-class-at-runtime.cs Use reflection to enumerate all publicly settable properties of a specific activex control class at runtime
validate-that-the-value-property-of-a-slider-activex-control-remains-within-its-defined-minimum-and-maximum-range.cs Validate that the value property of a slider activex control remains within its defined minimum and maximum range
write-a-method-that-retrieves-all-activex-controls-on-a-given-page-and-returns-their-count.cs Write a method that retrieves all activex controls on a given page and returns their count

Validation Details


This PR was created automatically by the Aspose.Diagram Examples Generator Agent. Merge after reviewing the examples above.

…-a-shape-programmatically-and-initialize-its-minimum-maximum-and-value-properties

Task: Add a new slider activex control to a shape programmatically and initialize its minimum maximum and value properties

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…ieve-and-modify-activex-controls-across-diagrams-of-varying-sizes-and-complexities

Task: Benchmark the time required to retrieve and modify activex controls across diagrams of varying sizes and complexities

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…tance-to-its-specific-control-class-before-modifying-any-properties

Task: Cast the generic activexcontrol instance to its specific control class before modifying any properties

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…rol-property-is-null-before-accessing-its-members

Task: Check whether a shape s activexcontrol property is null before accessing its members

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…ing-differences-in-activex-control-property-values-across-matching-shapes

Task: Compare two visio diagrams by checking differences in activex control property values across matching shapes

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…t-abstracts-casting-of-activexcontrol-objects-to-their-concrete-types

Task: Create a reusable helper method that abstracts casting of activexcontrol objects to their concrete types

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…ctivex-controls-on-a-diagram-before-exporting-it-to-pdf-for-security

Task: Create a script that disables all activex controls on a diagram before exporting it to pdf for security

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…operty-changes-on-a-retrieved-checkbox-activex-control-are-persisted-after-saving

Task: Create a unit test that verifies property changes on a retrieved checkbox activex control are persisted after saving

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…apply-the-values-to-corresponding-activex-control-properties-within-a-visio-diagram

Task: Deserialize json configuration and apply the values to corresponding activex control properties within a visio diagram

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…vex-controls-when-the-diagram-is-opened-in-read-only-mode-to-prevent-changes

Task: Design a feature that disables activex controls when the diagram is opened in read only mode to prevent changes

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…rol-type-of-a-retrieved-object-by-inspecting-its-progid-property-value

Task: Determine the concrete activex control type of a retrieved object by inspecting its progid property value

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…a-commandbutton-activex-control-to-locate-associated-documentation-resources

Task: Extract the helpfile property from a commandbutton activex control to locate associated documentation resources

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…tempting-to-cast-an-activexcontrol-to-an-incompatible-control-class-type

Task: Handle invalidcastexception when attempting to cast an activexcontrol to an incompatible control class type

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…-modifying-read-only-properties-of-an-activex-control-and-logs-a-warning

Task: Implement a safeguard that prevents modifying read only properties of an activex control and logs a warning

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…omexception-when-accessing-activex-control-properties-that-require-specific-permissio

Task: Implement error handling to catch comexception when accessing activex control properties that require specific permissio

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…ion-into-an-asp-net-mvc-application-to-dynamically-update-diagram-visuals

Task: Integrate activex control manipulation into an asp net mvc application to dynamically update diagram visuals

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…m-processing-only-those-that-contain-an-activexcontrol-object

Task: Iterate over all shapes in a diagram processing only those that contain an activexcontrol object

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…ivex-controls-and-enumerate-all-shapes-that-embed-such-controls

Task: Load a visio diagram containing activex controls and enumerate all shapes that embed such controls

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…stream-and-update-activex-control-properties-without-writing-to-disk

Task: Load a visio diagram from a memory stream and update activex control properties without writing to disk

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…-activex-control-including-previous-and-new-values-for-audit-purposes

Task: Log each property change made to an activex control including previous and new values for audit purposes

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…f-a-button-activex-control-embedded-in-a-visio-shape

Task: Read the current caption property of a button activex control embedded in a visio shape

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…pe-by-setting-its-activexcontrol-property-to-null-and-saving-diagram

Task: Remove an activexcontrol from a shape by setting its activexcontrol property to null and saving diagram

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…from-a-specific-shape-using-shape-activexcontrol-property-for-further-processing

Task: Retrieve the activexcontrol object from a specific shape using shape activexcontrol property for further processing

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…a-new-file-preserving-original-activex-control-configurations-and-layout

Task: Save the modified visio diagram to a new file preserving original activex control configurations and layout

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…-activex-control-to-json-for-external-configuration-management

Task: Serialize the property values of an activex control to json for external configuration management

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…box-activex-control-to-false-to-disable-user-interaction

Task: Set the enabled property of a checkbox activex control to false to disable user interaction

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…e-activex-control-and-persist-the-modified-diagram-to-a-new-file

Task: Update one or more properties of the activex control and persist the modified diagram to a new file

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…licly-settable-properties-of-a-specific-activex-control-class-at-runtime

Task: Use reflection to enumerate all publicly settable properties of a specific activex control class at runtime

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…-a-slider-activex-control-remains-within-its-defined-minimum-and-maximum-range

Task: Validate that the value property of a slider activex control remains within its defined minimum and maximum range

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
…ctivex-controls-on-a-given-page-and-returns-their-count

Task: Write a method that retrieves all activex controls on a given page and returns their count

- Validated: dotnet build passed
- Validated: dotnet run passed
- Generator: Aspose.Diagram Examples Generator Agent v2.0
- Library: Aspose.Diagram for .NET 26.8.0
- Framework: net8.0
- Pipeline: MCP retrieval → rules injection → LLM repair
@amjad-sahi
amjad-sahi merged commit 781d803 into main Aug 28, 2026
1 check passed
@amjad-sahi
amjad-sahi deleted the feat/examples-visio-activex-controls-20260828 branch August 28, 2026 14:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants