Category: Uncategorized

Working with Amiga C using Visual Studio Code

Working with Amiga C using Visual Studio Code

I’ve found it rather difficult to go back to coding on the Amiga with the available editors. Most of them lack decent syntax highlighting, formatting, intellisense and autocomplete. Professionally I’m used to using the likes of Visual Studio which supplies all those features. Using Visual Studio Code, a free IDE […]

XML Serialization quick and easy csharp

XML Serialization quick and easy csharp

Serialization with XML and C# this is mainly here as a reminder for me on how to do it! To serialize to a file: using System.Xml; using System.Xml.Serialization; // other code List<string> mylist = this.getList(); Type stype = typeof(List<string>); var serializer = new XmlSerializer(stype); XmlWriterSettings settings = new XmlWriterSettings(); settings.OmitXmlDeclaration […]

Bootstrap compatible asp.net button

Bootstrap compatible asp.net button

Similar to my previous post, you can use the following code to create a custom asp.net button with the ‘button’ tags used in HTML5 and bootstrap. [ParseChildren] public class bsButton : Button { private string _ButtonCss = "btn btn-default"; [Browsable(true), Description("The css class"),] public string ButtonCss { get { return […]

Calculate a fraction in javascript

Calculate a fraction in javascript

Calculating a fraction from a double in javascript The following code will allow you to calculate a fraction in javascript function getFraction(dblValue, dblTolerance) { var f0 = 1 / dblValue; var f1 = 1 / (f0 – Math.floor(f0)); var a_t = Math.floor(f0); var a_r = Math.round(f0); var b_t = Math.floor(f1); […]

Amiga emulator (E-UAE) for Cobra ODE, works on superslim

Amiga emulator (E-UAE) for Cobra ODE, works on superslim

Just a quick post giving a place to download E-UAE for the Cobra ODE. Please glance at the read me file and create a folder structure to that on the zip. TOSEC is a good resource to get hold of ADF’s and the kickstarts are available from all over the […]

Delete / Drop all stored procedures in an SQL Database

Delete / Drop all stored procedures in an SQL Database

The following SQL will delete all stored procedures in a specified database. Make sure you specify the database you are using! USE [MyDatabase] DECLARE @spName varchar(500) DECLARE _CurCursor CURSOR FOR SELECT [name] FROM sys.objects WHERE type = 'p' OPEN _CurCursor FETCH NEXT FROM _CurCursor INTO @spName WHILE @@fetch_status = 0 […]