Author Topic: New to HyperNext need direction for learning how to.  (Read 322 times)

d-ton

  • Newbie
  • *
  • Posts: 1
New to HyperNext need direction for learning how to.
« on: July 31, 2022, 05:04:27 PM »
I would like to make an app similar to a to do task list and a finished task list.  One where you can slide a button from to do list to complete list.  Also be able to slide back to the todo list if needed.  I have read the start up and do not know what section I should play around in next.  Any info would be appreciated. 

Malkom

  • Administrator
  • Newbie
  • *****
  • Posts: 443
  • Here to help you
Re: New to HyperNext need direction for learning how to.
« Reply #1 on: July 31, 2022, 07:31:10 PM »
I would like to make an app similar to a to do task list and a finished task list.  One where you can slide a button from to do list to complete list.  Also be able to slide back to the todo list if needed.  I have read the start up and do not know what section I should play around in next.  Any info would be appreciated.

Perhaps the easiest approach is to use two Listboxes, one for the To-Do and one for the Finished task list.
You could use a button to move a highlighted or selected row between listboxes or perhaps just a double-click on a  listbox's row.

Listboxes are covered in the Language Reference chapter 10 on Control Types.
HN's in-built help also has information on Listboxes - accessible from its Guide menu.


Here are some forum posts on list boxes:-

http://www.tigabyte.com/smf/index.php?topic=349.msg984#msg984

http://www.tigabyte.com/smf/index.php?topic=2983.msg3742#msg3742

http://www.tigabyte.com/smf/index.php?topic=351.msg3448#msg3448

http://www.tigabyte.com/smf/index.php?topic=49.msg93#msg93


Note, the QuickStart PDF might help you make sense of this.


Here is some simple code to setup two list boxes
Create a new project and then use the Creator Toolbar to create two listboxes and one button.

Then place the script below in the button to build your listboxes.
Note, I used Global variables so you can easily access them in other procedures or other controls etc.
The script would normnally be placed in the Card's open event.


Code: [Select]
@ To Do listbox
Global nrows1,ncols1

@ Finished listbox
Global nrows2,ncols2

@ Build listbox 1
Put 10 into nrows1
Put 3 into ncols1
ListBoxBuild(1,nrows1,ncols1)
ListBoxSetHeading(1,1,'TO DO')
ListBoxSetHeading(1,2,'Info 1')
ListBoxSetHeading(1,3,'Info 2')

@ Build list box 2
Put 2 into nrows2
Put 3 into ncols2
ListBoxBuild(2,nrows2,ncols2)
ListBoxSetHeading(2,1,'FINISHED')
ListBoxSetHeading(2,2,'Info 2')
ListBoxSetHeading(2,3,'Info 2')

You could then experiment with various Listbox functions for setting cell values, moving from one list to another etc.
The easiest way to do this is to use a button for each listbox function you are testing.


By the way, if you don't like the look of listboxes then you could make your own using a Canvas control.
Canvas controls are much more work but their graphics are prettier.









« Last Edit: July 31, 2022, 07:33:42 PM by Malkom »
I am sorry but I do not have time to answer questions by PM or email.
If you post your questions in this forum then it might help others.

 

anything