Skip to content
DataMiner Dojo

More results...

Generic selectors
Exact matches only
Search in title
Search in content
Post Type Selectors
Search in posts
Search in pages
Search in posts
Search in pages
Log in
Menu
  • Updates & Insights
  • Questions
  • Learning
    • E-learning Courses
    • Tutorials
    • Open Classroom Training
    • Certification
      • DataMiner Fundamentals
      • DataMiner Configurator
      • DataMiner Automation
      • Scripts & Connectors Developer: HTTP Basics
      • Scripts & Connectors Developer: SNMP Basics
      • Visual Overview – Level 1
      • Verify a certificate
    • YouTube Videos
    • Solutions & Use Cases
      • Solutions
      • Use Case Library
    • Agility
      • Learn more about Agile
        • Agile Webspace
        • Everything Agile
          • The Agile Manifesto
          • Best Practices
          • Retro Recipes
        • Methodologies
          • The Scrum Framework
          • Kanban
          • Extreme Programming
        • Roles
          • The Product Owner
          • The Agile Coach
          • The Quality & UX Coach (QX)
      • Book your Agile Fundamentals training
      • Book you Kanban workshop
    • >> Go to DataMiner Docs
  • DevOps
    • About the DevOps Program
    • Sign up for the DevOps Program
    • DataMiner DevOps Support
    • Feature Suggestions
  • Downloads
  • Swag Shop
  • PARTNERS
    • Business Partners
    • Technology Partners
  • Contact
    • Sales, Training & Certification
    • DataMiner Support
    • Global Feedback Survey
  • >> Go to dataminer.services

Using Automation Script to Copy Elements Under a New View Without Losing Historical Data

66 views2 days agoAutomtionScript
0
A B M Sidddique [DevOps Advocate]399 2 days ago 0 Comments

Hello , I’m writing a C# automation script that uses the Class Library (

Skyline.DataMiner.Core.DataMinerSystem.Automation.

Skyline.DataMiner.Core.DataMinerSystem.Common

) to work with elements and views.

Each of our site has its own container view with several elements under it — and I’d like to automate the process of copying all elements from one site view to another.

Basically, I want to:

  • Get all elements under a specific container (e.g. “Japan”)

  • Duplicate them under another container or view (e.g. “Japan_Copy”) or multiple selection of elements using regex/string mapping and then move it to a new parent container

  • Keep the original elements untouched

  • Ideally preserve their configuration and historical data

Dragging and dropping 200+ elements manually isn’t very efficient, so I was wondering — can I safely use the Duplicate() method from the Class Library inside an automation script to do this, without losing historical data or trend info?

If not, is there another way to programmatically copy or reference existing elements into a new view while keeping their data?

Appreciate any pointers or examples from anyone who’s tried something similar

Miguel Obregon [SLC] [DevOps Catalyst] Answered question 2 days ago

1 Answer

  • Active
  • Voted
  • Newest
  • Oldest
2
Miguel Obregon [SLC] [DevOps Catalyst]21.01K Posted 2 days ago 2 Comments

Hi,

Is it necessary to duplicate the elements? Keep in mind that a single element can be displayed across multiple views.

If that's not feasible, an alternative approach could be element replication (Replicating elements)

Hope it helps.

Miguel Obregon [SLC] [DevOps Catalyst] Posted new comment 2 days ago
A B M Sidddique [DevOps Advocate] commented 2 days ago

yeah basically i want that other element displayed another parent view aswell – is it possible to do it with a script rather than selecting edit and checking the box for each element ?

Miguel Obregon [SLC] [DevOps Catalyst] commented 2 days ago

Hi,
Using the class library, you can create an element and make it available in multiple views. See below example:
https://docs.dataminer.services/develop/devguide/ClassLibrary/ClassLibraryElementCreation.html#creating-an-element-in-specific-views
To update an existing element, see the below example:
https://docs.dataminer.services/develop/devguide/ClassLibrary/ClassLibraryExamples.html#setting-a-property-and-renaming-the-element
The example is focused on element properties. In your case, you will need to update the element configuration to add another view:
https://docs.dataminer.services/develop/api/types/Skyline.DataMiner.Core.DataMinerSystem.Common.ElementConfiguration.html

You are viewing 1 out of 1 answers, click here to view all answers.
Please login to be able to comment or post an answer.

My DevOps rank

DevOps Members get more insights on their profile page.

My user earnings

0 Dojo credits

Spend your credits in our swag shop.

0 Reputation points

Boost your reputation, climb the leaderboard.

Promo banner DataMiner DevOps Professiona Program
DataMiner Integration Studio (DIS)
Empower Katas
Privacy Policy • Terms & Conditions • Contact

© 2025 Skyline Communications. All rights reserved.

DOJO Q&A widget

Can't find what you need?

? Explore the Q&A DataMiner Docs

[ Placeholder content for popup link ] WordPress Download Manager - Best Download Management Plugin