/// <summary>
        /// This Method is a javascript callable method.
        /// </summary>
        /// <param name="e">A parameter from javascript.</param>
        /// <param name="y">A callback to javascript.</param>
        public void WebMethod2(string e, Action<string> y)
        {
            // { Message = Could not load file or assembly 'System.Data.SQLite, Version=1.0.82.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139'
            // or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. 
            // (Exception from HRESULT: 0x80131040), 
            //Could not load file or assembly 'System.Data.SQLite, Version=1.0.83.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)

            //wtf?

            var x = new __ConsoleToDatabaseWriter(y);

            Native.API.error_reporting(-1);

            Console.WriteLine("before data");

            var data = new TheGridTable();

            data.Create();

            data.Insert(
                new TheGridTableQueries.Insert { ContentValue = "v", ContentComment = "c" }
                , id =>
                {
                    Console.WriteLine("just inserted " + new { id });

                    data.Insert(
                         new TheGridTableQueries.Insert { ContentValue = "vv", ContentComment = "cc", ParentContentKey = id }
                         , cid =>
                         {
                             Console.WriteLine("just inserted child " + new { cid });
                         }
                     );

                }
            );

            data.SelectContent(
                new TheGridTableQueries.SelectContentByParent(),
                r =>
                {
                    long ContentKey = r.ContentKey;
                    int ContentChildren = r.ContentChildren;

                    Console.WriteLine("found " + new { ContentKey, ContentChildren });

                    if (ContentChildren > 0)
                    {
                        // show children!

                        data.SelectContent(
                             new TheGridTableQueries.SelectContentByParent { ParentContentKey = ContentKey },
                             rr =>
                             {
                                 long cContentKey = rr.ContentKey;
                                 int cContentChildren = rr.ContentChildren;

                                 Console.WriteLine("found child " + new { cContentKey, cContentChildren });

                             }
                         );
                    }
                }
            );

            Console.WriteLine("done!");
            x.Dispose();
        }
        private static TextWriter InitializeAndKeepOriginal(__ConsoleToDatabaseWriter w)
        {
            // Console is not really thread safe!
            if (o == null)
                o = Console.Out;

            Console.SetOut(w);
            return o;
        }