Clever Table Object

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Clever Table Object

Bill Vlahos
Several folks have asked me how I got the native field object in lcTaskList to do those table tricks without using ListMagic or the Data Grid.

I recently discovered Bernd Niggeman's "OldTableFieldDragDividers" stack in RevOnLine (he uploaded it in 2010 but even though it has been downloaded over 300 times I missed it) which teaches the regular table field object lots of new tricks just with scripting. I didn't think it was possible but his scripts are very clever and easy to understand.

For lcTaskList I use a field and graphic for the header and a field for the table object for the data and have handlers cross reference his scripts in each field object.

I would encourage everyone to take a look at his amazing stack and the RunRev folks to make it an optional part of the field object.

Hats off to Bernd.
Bill Vlahos
_________________
InfoWallet (http://www.infowallet.com) is about keeping your important life information with you, accessible, and secure.
lcTaskList: (http://www.infowallet.com/lctasklist/index.htm)


_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|

Re: Clever Table Object

BNig
Hi Bill,

Bill Vlahos wrote
Several folks have asked me how I got the native field object in lcTaskList to do those table tricks without using ListMagic or the Data Grid.

I recently discovered Bernd Niggeman's "OldTableFieldDragDividers" stack in RevOnLine (he uploaded it in 2010 but even though it has been downloaded over 300 times I missed it) which teaches the regular table field object lots of new tricks just with scripting. I didn't think it was possible but his scripts are very clever and easy to understand.
thank you for the kind words.

Unfortunately RunRev changed the way to calculate the offset of the vertical dividers from the left of the field. You filed a bug #10223, Rev may change this or may not.
I tried to update the stack on RevOnline but RevOnline did not like me ... :)

If anyone wants to make this work for versions < 5.5 and >= 5.5 add this to the script
------------------
  -- fix for the changed tab location in LiveCode 5.5
   put the version into tVersion
   replace "." with "" in tVersion
   if char 1 to 2 of tVersion >= 55 then
      add (item 1 of the margins of me -3) to tLeft
   end if
   -- end fix for changed tab location
------------------
Kind regards
Bernd
Reply | Threaded
Open this post in threaded view
|

Re: Clever Table Object

slylabs13
To which handler?

Bob


On Jun 18, 2012, at 4:33 AM, BNig wrote:

> If anyone wants to make this work for versions < 5.5 and >= 5.5 add this to
> the script
> ------------------
>  -- fix for the changed tab location in LiveCode 5.5
>   put the version into tVersion
>   replace "." with "" in tVersion
>   if char 1 to 2 of tVersion >= 55 then
>      add (item 1 of the margins of me -3) to tLeft
>   end if
>   -- end fix for changed tab location
> ------------------
> Kind regards
> Bernd


_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|

Re: Clever Table Object

BNig
Sorry about that,

insert the said fix into the on mouseEnter handler after

put the left of me into tLeft

I will try my luck with revOnline again but will probably have to post the stack on my website. Too bad. I hope Runrev will find the time to fix revOnline in the near future. It is such a nice way to share stacks.
kind regards
Bernd

slylabs13 wrote
To which handler?

Bob


On Jun 18, 2012, at 4:33 AM, BNig wrote:

> If anyone wants to make this work for versions < 5.5 and >= 5.5 add this to
> the script
> ------------------
>  -- fix for the changed tab location in LiveCode 5.5
>   put the version into tVersion
>   replace "." with "" in tVersion
>   if char 1 to 2 of tVersion >= 55 then
>      add (item 1 of the margins of me -3) to tLeft
>   end if
>   -- end fix for changed tab location
> ------------------
> Kind regards
> Bernd
Reply | Threaded
Open this post in threaded view
|

Re: Clever Table Object

René Micout

Le 19 juin 2012 à 00:00, BNig a écrit :

>  I hope Runrev will find the time to fix
> revOnline in the near future.

Oh YES !!!
Bernd > Hello from Paris...
_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode