Simple site for editing simple data

Apr 22 2020 Published by under Uncategorized

Problem

As a developer I often have a settings table which is only editable by database tools (e.g. sql or text editor) and often only on the backend server. It would be nice to have a solution to allow easy editing while not being on the backend.

Solution

A small xcopy:able web site or application.
For database data it could have a connection string to the server and for text files it could have a path.

It should be able to figure out some meta data by itself but then, with local settings, override them to a more user friendly format.
For instance, if settings is a CSV table, the local settings could have definitions for separator characters, column headers and column data types.

This suggested solution is not for production but would solve the problem during development and even for production time backend manipulation in the right, careful hands. The same hands that otherwise would write sql queries to do the same task.

No responses yet

A code editor that doesn’t use the document metaphor

May 10 2017 Published by under Uncategorized

I dare say all main code editors today use the document metaphor; text in a document read from top to bottom.
I dare say time has come to drop this metaphor to a more object oriented or data flow oriented one.


When writing a class in an object oriented language the resulting document usually, contains the properties in the top and the methods below.
This means that when looking at the code reading a property name means it is easy to read other properties as they are close by in the document. But is this really what you want? – isn’t the methods using this property what you want to look at?

Now say you are debugging the Save method. There is a great chance you have method Restore (alphabet wise R is next to S) on the monitor; despite you being totally uninterested in them.

What you instead want to have before your eyes and withing a keystroke are the properties User and IsAdministrator and the method Validate; because they are part of the data flow method Save uses.

You are probably also interested in who calls Save and who is called by Save.

My proposal is this:

When you are working with a method, in your vicinity you want what Save reads and manipulates. Any property is shown in a window above the method you are working with. To the right you have a list of methods, and possibly some code, to all methods that are called from the method you are working with and to the left you can see all ways to call your method.
Equally easy to see and navigate to are the parents and descendants of your class.

3 responses so far

A way to find unused methods etc. in Visual studio

Dec 22 2011 Published by under Uncategorized

While refactoring projects I’d like to get a list or graph of unused methods.  This is not only for tidying or big-rewrites but also for whenever one updates a method.  Every time this happens I’d like a ping that x less or y more methods are used.

Combine this with profiled unit tests and one could get the time&resource impact of a rewrite very fast.

First step is to create something that find dud methods/properties/classes/etc.

Second step is to make it awesomelly useful.

This idea is probably already created somewhere.  Anyone who knows?

2 responses so far

Visualise layer or connection

May 10 2010 Published by under Uncategorized

Wouldn’t it be good to easily see which layer you are working in in your IDE?  When working in a multi layer environment one often has a class named Customer in every layer which makes for some document switching before finding the right one.  Add an icon in a corner or a slightly tinted background.

When working with multiple databases at once in a query tool it is often a hassle to keep the windows of the different databases apart.  Often one has two servers QA and Production with identical (or similar) database names.  It is very important to not update the wrong one.
Couldn’t one have a slightly tinted background that shows where one is?

Update:
There is an extension that can colour the tabs but it doesn’t give the full visual  clue I am looking for.

No responses yet

An editor where the paper moves up/down instead of the cursor

Mar 24 2010 Published by under Uncategorized

In my editor I spend too much time looking for the cursor; up, down, left, right.

Why not have the cursor in the same line, like 30% from the top, and instead move the text behind it?

This will make it possible to always write the code/text at the most comfortable place.

Sometimes one wants to write at the top (see code below) or vice verse and one could move the cursor to a new base position then.

(Finding the cursor is easier with a highlighted line where the cursor is.)

2 responses so far

Visual studio List visualiser

Mar 22 2010 Published by under Uncategorized

There is a good dataset visualiser in Visual studio.

But if one uses lists one is out of luck. I have tried creating one, but failed either of lack of competence or lack of time.

There might be a way to export a list to a datatable and work from there but strange enough I haven’t tried.

Create a debug visualiser for generic lists in Visual studio.

No responses yet

Programming: a reference that cannot be null

Mar 03 2010 Published by under Uncategorized

In most (all?) object oriented programming languages it is possible to have a reference to an object and have this reference be null/nothing/nil.  There are many cases this isn’t a good idea; like for instance method signatures.

AddCustomer( Customer customer )

and customer is null.  Not very common…

It would be nice to have a reference type that cannot be null.  Ever.  The compiler should also know about this and break if the code flow allows the reference being null.

No responses yet

Shortcut aid duplicate in Visual studio

Mar 03 2010 Published by under Uncategorized

When developing Winforms (and Webforms and Aspnet) in Microsoft Visual Studio there is no aid to stop me from entering overlapping shortcuts.

For example I have a menu with 5 items which have shortcuts alt-F, alt-E, alt-V, alt-T and alt-H.  It is then important that my buttons don’t have the same shortcuts.  There is nothing in Visual Studio signalling a shortcut used in more than one place.

Technically this could be solved through recursing through the controls of a form.  It can be done in the OnLoad event and only in debug mode.  The controls could then be highlighted and maybe reported since it isn’t possible to statically change shortcut while debugging and at least I forget which two controls should be changed to what.
One could take it further to show up already in the designer, that would be the nicest solution.

It is more complex for MDI interfaces.  There is no static linking between a parent and child forms.  One could have a settings file describing the relations.

Ditto tab controls.

Then we have rules like that alt-S should be Save and alt-E should be used for Seek throughout the application.  Without thinking one could use alt-S for Seek in a form somewhere which could fool the user into believing he has saved when he have not.
The technical solution to this could be to have a common settings file.  Controls using one of the regulated short cuts then flag that they are approved for this by a flag.  A developer might accidentally set a short cut but not a flag at the same time.

No responses yet