machine control script ( parameterless method? )

Discussion in 'Python' started by simon place, Mar 6, 2004.

  1. simon place

    simon place Guest

    I'm thinking of rewriting some vb code in python, its a
    machine control
    program currently using a simple script to define an action
    sequence.

    but if i directly use python for the action sequence ( the
    most flexible approach.) means each action ( method ) having
    brackets, which is a bit redundant and confusing to the
    user, since i'm separating the parameters all actions are
    calls to parameterless methods,

    so the question is, is there any way to call a method when a
    name is referenced ( like __repr__ in interactive mode.)

    why do i separate the parameters?
    well a parameter can be changed often, can occur in several
    actions and is unlikely to cause major problems if wrongly
    entered, whilst the actions have more serious consequences
    if wrongly arranged , so they are differently accessed. This
    arrangement seems to me to be quite common, like a washing
    machine, dial to select a predefined sequence and then
    buttons or dials to tailor it to more refined requirements.


    thanks in advance.
     
    simon place, Mar 6, 2004
    #1
    1. Advertising

  2. simon place

    Bluexcell Guest

    Assuming your machine program is not hard wired..then the user is using some
    form of GUI or other interface to alter the parameters for control, why not use
    a Tkinter GUI to create the program I/O interface.. the checks and safeguards
    for for incorrect entry are hidden and the user is more inclined to enter the
    right data in the right place?
     
    Bluexcell, Mar 6, 2004
    #2
    1. Advertising

  3. simon place

    simon place Guest

    Bluexcell wrote:

    > Assuming your machine program is not hard wired..then the user is using some
    > form of GUI or other interface to alter the parameters for control, why not use
    > a Tkinter GUI to create the program I/O interface.. the checks and safeguards
    > for for incorrect entry are hidden and the user is more inclined to enter the
    > right data in the right place?


    i was thinking of using a text control for the user to edit an action script,
    ( thsts why im thinking of python.) v.v.little code, v.flexible ( i don't have
    to worry about malicious user) that's why the question is actually only about
    getting rid of the brackets.
     
    simon place, Mar 6, 2004
    #3
  4. simon place

    F. Petitjean Guest

    On Sat, 06 Mar 2004 simon place <> wrote:
    >

    [snip]
    > that's why the question is actually only about
    > getting rid of the brackets.

    If the action is a property, simply writing someobject.someobject can
    trigger a get method whithout the brackets.

    Regards.
     
    F. Petitjean, Mar 7, 2004
    #4
  5. simon place

    simon place Guest

    F. Petitjean wrote:

    > On Sat, 06 Mar 2004 simon place <> wrote:
    >
    > [snip]
    >
    >>that's why the question is actually only about
    >>getting rid of the brackets.

    >
    > If the action is a property, simply writing someobject.someobject can
    > trigger a get method whithout the brackets.
    >
    > Regards.


    thanks this is lot better, i might be able to except a dot but if anyone has
    an idea about getting rid of this too?
     
    simon place, Mar 7, 2004
    #5
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. =?Utf-8?B?UmVzaG1hIFByYWJodQ==?=

    Auto-attach to process '[1084] aspnet_wp.exe' on machine <Machine

    =?Utf-8?B?UmVzaG1hIFByYWJodQ==?=, Jan 21, 2005, in forum: ASP .Net
    Replies:
    0
    Views:
    1,084
    =?Utf-8?B?UmVzaG1hIFByYWJodQ==?=
    Jan 21, 2005
  2. Nathan Sokalski
    Replies:
    1
    Views:
    2,563
    Gaurav Vaish \(www.EdujiniOnline.com\)
    Nov 21, 2006
  3. johnny
    Replies:
    5
    Views:
    553
    Antonio Cuni
    Jul 11, 2007
  4. Julia B
    Replies:
    8
    Views:
    539
    Mike Baker
    Nov 21, 2008
  5. vncntj

    Newbie: does not have a parameterless constructor

    vncntj, Nov 25, 2007, in forum: ASP .Net Web Services
    Replies:
    1
    Views:
    179
    vncntj
    Nov 25, 2007
Loading...

Share This Page