Category: .net (c#)

  • c# .Net Autocad plugin – “Hello world” Walk through

    There’s not much out there in the way of introductions. You’d have to wade through some manuals and it can be tedious. A simple walk through of how to get started. You would do well to record it at 1.5-x2 playback speed.   Autocad .net c# Plug in – Hello World Example from Tek1 on…

  • Convert ObjectID[] to ObjectIDCollections!

    When dealing with selection sets we can obtain the object ids of the objects contained within. The method though, returns an array.   But what if we want an ObjectIDCollection?   We can simply pass the ObjectID[] array into the ObjectIDCollection constructor.   Simple. The last thing you want to do is iterate through the…

  • Program to supersede and manage hundreds of drawings received via transmittal

    What is the problem? Superseding documents is a real pain – a great difficulty. Manually clicking and deleting files: it’s very time consuming and error prone. What if you miss an important drawing? It’s very, very easy when you get 20-30 new drawings every two days to sort through. In 3 months you’ll have a…

  • Batch Processing AutoCAD drawings using AcCoreConsole and Script Pro 2.0

    Batch Processing Using AcCoreConsole is now here. What is AcCoreConsole? It is a command line version of AutoCAD without a user interface. It allows us to batch process AutoCAD drawings super fast. Example: Let’s say I have 500 drawings. (This is a prime candidate for batch processing). Now let’s say I have to apply a…

  • Writing Clear Tests

    A very rudimentary but fundamental tip: When you are testing something, it is absolutely paramount that you have a crystal clear idea in your mind of exactly what you are testing. If you want to ensure that there are 4 tyres on your car, before you start out from your garage, you must check for…

  • WPF Tunnelling – Explanation by analogy

    Tunnelling – What is it? And no, I’m not referring to how El Chapo escaped.   Refresher: what is bubbling? In the last post we talked about “bubbling”. It’s kinda like those instances where you get a parking fine. If you don’t deal with it then, you’ll get another fine. If you don’t deal with…

  • What is a routed event?

    What is a routed event? This is the answer that is typical on Stack Overflow sites and other such forums: A routed event is a type of event that can invoke handlers on multiple listeners in an element tree, rather than just on the object that raised the event. It seems – with all due…

  • What is an event?

    Assumed knowledge: Assume you know what a method is.   What is an event? Let’s keep it simple. An event is anything which “happens”. “Oh great! That helps a lot :’(  ,“ I hear you say. Examples are in order: The President comes to town. He could come at anytime. You don’t know when he…

  • What is a call-back function?

    Example by Parable and Analogy I have a secretary. At the end of the day, I ask her to: (i) take the firm’s outgoing mail and to drop it off at the post office, and in addition to that, after she has dropped the mail off, I ask her to do something else: (ii) whatever…