Suneido

Integrated Application Platform

  • Home
  • Learning
    • Suneido Manual
    • Beginners
      • Inside Suneido
      • The Suneido Programming Language
      • The Suneido Database
      • Installing Suneido
      • Building Suneido
      • IDE Go To Tour
      • Upgrading To A New Release
    • Advanced
      • Canvas Control
      • DrawControl Part 1
      • DrawControl Part 2
      • DrawControl Part 3
      • SAX Like XML Processing
      • A Plug-In Architecture
      • A Simple Wizard Framework
      • An HTML Include Facility
      • An RSS 2 Feed Creator
      • MIME Generation
      • A New Add-on Facility
      • Workspace Improvement Hack
    • Mockito for Suneido
    • The Suneido Task Scheduler
    • Contributing To Suneido
    • Contributor Assignment of Copyright
    • Language Translation
    • Future Directions
    • Interview With Andrew Mckinlay
  • Forum
    • Announcements
    • Internals & Enhancements
    • Cookbook
    • General
  • FAQ
  • Screenshots
  • Downloads
  • Links

amckinlay

  • Profile
  • Topics Started
  • Replies Created
  • Engagements
  • Favorites

Forum Replies Created

Viewing 15 posts - 46 through 60 (of 197 total)
← 1 2 3 4 5 … 12 13 14 →
  • Author
    Posts
  • July 27, 2015 at 4:17 pm in reply to: Error with Reporter #1206
    amckinlay
    Keymaster

    Sorry, I was giving you the wrong directions.

    You do NOT need the plugin.

    CustomReportsMenu is wrong. Change GetSource to be:

        GetSource(source)
            {
            return Object(query: source, name: source)
            }

    You also need to run (from the WorkSpace):

    Params.Ensure()

    I tested with a fresh download and this seems to work for me. (I could recreate your problem.)

    If you look at the Accounting download you can see that it redefines parts of Reporter so that you choose a data source instead of just entering a query. That is what I was thinking of.

    July 27, 2015 at 12:41 pm in reply to: Error with Reporter #1203
    amckinlay
    Keymaster

    Looking at CustomReportsMenu.GetSource it appears that it is not finding your data source.

    I can not tell from your screen shot if it is asking for the correct name? (the one you defined) Double click on ‘x’ in the debugger and see if Source is ‘Liste’

    Did you restart Suneido to ensure the plugins are updated?

    Did you name your plugin “Plugin_Reporter”? (It must be exactly this name.)

    July 27, 2015 at 11:09 am in reply to: Error with Reporter #1200
    amckinlay
    Keymaster

    Hi Pierre,

    After editing plugins, you may need to restart Suneido.

    When do you get the error? Do you get the debugger? If so, what does it show?

    July 26, 2015 at 11:07 am in reply to: Error with Reporter #1198
    amckinlay
    Keymaster

    Hi,

    You probably need to define the data sources for your reports. Create a library record called Plugin_Reporter with something like:

    #(
    ExtensionPoints:
        (
        (queries)
        )
    Contributions:
        (
        (Reporter, queries,
            name: 'Tables',
            query: 'tables')
        )
    )

    You can define multiple contributions. These are what will show up in the Data Source pull down list in Reporter.

    If you download the Accounting Application it has lots of examples.

    June 2, 2015 at 2:19 pm in reply to: Wcstombs – String Conversion #1187
    amckinlay
    Keymaster

    I’m not sure why Wcstombs() is causing problems (I got an access violation when I tried your example). I assume it’s because the input is “bad”.

    Your example is backwards – Suneido uses 8 bit character strings, so “Test” is (more or less) UTF-8 (= multi byte string = mbs).

    s = “Test”.Mbstowcs()
    => “T\x00e\x00s\x00t\x00\x00\x00”

    s.Wcstombs()
    => “Test”

    April 10, 2015 at 4:12 pm in reply to: Mshtml as a Dialog #1173
    amckinlay
    Keymaster

    This works for me:

    Dialog(0, #(Mshtml 'hello world' xmin: 500, ymin: 500))

    April 10, 2015 at 4:03 pm in reply to: Browse : readOnly #1172
    amckinlay
    Keymaster

    It is not that hard to figure this kind of thing out yourself. (I have to do the same.)

    I looked at BrowseControl and I see List_HeaderContextMenu. If I comment this out, then there is no context menu on the header.

    March 27, 2015 at 11:51 am in reply to: ListView – how to make visible added rows? #1167
    amckinlay
    Keymaster

    […] is equivalent to Record(…) in code, or to #{…} in a constant
    I use it because it is shorter
    Although you have to be careful because Record is slightly different from Object

    1) You can sort your data before you add it to the list view. e.g. data.Sort!(By(#name))
    Or if you use DragDropListViewControl (see below) you can call the SortList method.

    2) If you use DragDropListViewControl instead of ListViewControl then you can click on the header to sort. (And you can also rearrange the columns.)

    March 26, 2015 at 9:27 am in reply to: ListView – how to make visible added rows? #1165
    amckinlay
    Keymaster

    I will correct the help, thanks.

    Here is an example that works for me:

    Window(Controller {
    	New()
    		{
    		.list = .FindControl('List')
    		.list.SetColumns(#(name, age))
    		}
    	Controls()
    		{
    		return ['Vert',
    			['ListView', style: LVS.REPORT],
    			#(Button Add)]
    		}
    	On_Add()
    		{
    		.list.Addrow(#(name: Bob, age: 24))
    		.list.Addrow(#(name: Sue, age: 19))
    		}
    	 })
    March 25, 2015 at 11:36 am in reply to: List View – Tool Tip and Click #1162
    amckinlay
    Keymaster

    The problem is that clicking on a row only selects the row if you click on the first item. (And ItemClicked is passing the selected row.) This is Windows, not Suneido.

    One way to make it work is to set a style with something like:

    .List.SetExtendedStyle(LVS_EX.FULLROWSELECT)

    March 24, 2015 at 9:31 am in reply to: List View – Tool Tip and Click #1159
    amckinlay
    Keymaster

    1) There is a Windows message to set the tooltip timing – TTM_SETDELAYTIME. This would let you keep the tooltip open longer. For example, at the end of ToolTipControl New you could add:

    .SendMessage(TTM.SETDELAYTIME, TTDT.AUTOPOP, 30000) // 30 sec

    Note: I have not tested this.

    2) I am not sure what you mean by “false is returned”. Do you mean the value passed to ItemClicked? This value is the row currently selected. If no row is selected it will be false.

    According to the MSDN documentation for list view NM_CLICK you must use LVM_SUBITEMHITTEST (ListViewControl SubItemHitTest) to determine which item was clicked on.

    February 14, 2015 at 8:29 am in reply to: counting based on more than two members of an object from inside a loop #1152
    amckinlay
    Keymaster

    You could build the code the same way you would build the query where and then use string.Eval. You would need to write it as a function and pass in the arguments. But that should not be necessary.

    If you make a list of the field names then you can just loop through them.

    function (row, fields)
        {
        for f in fields
            if row[f] isnt true
                return false
        return true
        }

    The first time the list would just have one field, the second time two fields, etc.

    Is that more what you are looking for?

    February 13, 2015 at 7:39 am in reply to: counting based on more than two members of an object from inside a loop #1150
    amckinlay
    Keymaster

    I am not sure exactly what you are looking for.

    Your lines of code look valid (except you have extra opening parenthesis)

    You could use the “functional” methods like object.Filter and object.Count or the combined object.CountIf

    e.g. n = rows.CountIf({ it[test1] is true and it[test2] is true })

    There is no shortcut to output a list of objects to a database table. It would be easy to write something that used a loop. If you have the data in memory it will be faster to process it there.

    I hope that helps.

    January 1, 2015 at 5:09 pm in reply to: Building with Visual Studio 2013 #1050
    amckinlay
    Keymaster

    The new Community Edition works fine as well.

    November 11, 2014 at 2:04 am in reply to: What about replication in suneido? #1115
    amckinlay
    Keymaster

    Hi Tahar,

    With the new database engine in jSuneido (the Java implementation) it would be reasonable to implement replication.

    Because the database file is append only, the replication process would only have to append the same data to the replica.

    However, this has not been implemented yet, and it would probably be more complex than this appears.

  • Author
    Posts
Viewing 15 posts - 46 through 60 (of 197 total)
← 1 2 3 4 5 … 12 13 14 →

Search Forums

Log In
Welcome to the new Suneido Web Site and Forum.
Register
Lost Password
users of the previous PHPBB Forum should be able to log in with their previous username and password.

Recent Topics

  • Alpha copy of gSuneido to play with
  • how to start jsuneido ?
  • Problem Starting Suneido…
  • Dialog not showing buttons
  • New link for Suneidojo

Contact Us | Legal Statement | Privacy Statement | SiteMap

Copyright © 2026 Axon® Development Corporation. All Rights Reserved. - Open Source Integrated Database and Programming Language