Word search Nl, En, De, Fr updated
- Dutchman
- Posts: 858
- Joined: Mon May 06, 2013 9:21 am
- My devices: iMac, iPad Air, iPhone
- Location: Netherlands
- Flag:
Word search Nl, En, De, Fr updated
I made a program to find words for the board game "Scrabble" and its digital version "WordFeud".
The search can be done for Dutch, English, German or French words.
You can find the program and its related files on Dropbox in
https://www.dropbox.com/sh/r46yin9uyjlp ... Xxd1a?dl=0
or in short: http://bit.ly/1e8WLB1
The program is developed on iPad, but tested for iPhone's screensize.
I could not test it on iPhone, so please report on that if you can.
In the file "- Read Me.txt" you'll find info on usage, program structure, search algorithm etc.
It explains also how lists of words can be prepared for usage.
The search can be done for Dutch, English, German or French words.
You can find the program and its related files on Dropbox in
https://www.dropbox.com/sh/r46yin9uyjlp ... Xxd1a?dl=0
or in short: http://bit.ly/1e8WLB1
The program is developed on iPad, but tested for iPhone's screensize.
I could not test it on iPhone, so please report on that if you can.
In the file "- Read Me.txt" you'll find info on usage, program structure, search algorithm etc.
It explains also how lists of words can be prepared for usage.
Last edited by Dutchman on Tue Aug 09, 2016 9:48 am, edited 5 times in total.
- rbytes
- Posts: 1338
- Joined: Sun May 31, 2015 12:11 am
- My devices: iPhone 11 Pro Max
iPad Pro 11
MacBook
Dell Inspiron laptop
CHUWI Plus 10 convertible Windows/Android tablet - Location: Calgary, Canada
- Flag:
- Contact:
Re: Word search
I tried a Search using the default Pattern and Selection and got an error. I can not seem to enter a Pattern or Selection that work. I always get Error - Letters Only, even though your default shows that I can use - and = in the Pattern and ? In the Selection.
I hope I can get this to work. I play Scrabble and Zynga's Words With Friends regularly.
I hope I can get this to work. I play Scrabble and Zynga's Words With Friends regularly.
The only thing that gets me down is gravity...
- Dutchman
- Posts: 858
- Joined: Mon May 06, 2013 9:21 am
- My devices: iMac, iPad Air, iPhone
- Location: Netherlands
- Flag:
Re: Word search
That is really strange. Especially because the default values don't work.
Could you place a line 'debug pause' after the label 'Error:' in the functions 'CheckSelection' and 'CheckPattern'.
What is then the value of '.Pat$' and/or '.Sel$' after input?
Note: set test-option 'Short=1' to use the short words-list during testing.

Could you place a line 'debug pause' after the label 'Error:' in the functions 'CheckSelection' and 'CheckPattern'.
What is then the value of '.Pat$' and/or '.Sel$' after input?
Note: set test-option 'Short=1' to use the short words-list during testing.

- Dutchman
- Posts: 858
- Joined: Mon May 06, 2013 9:21 am
- My devices: iMac, iPad Air, iPhone
- Location: Netherlands
- Flag:
Re: Word search
I have changed the function 'Alphabetical()'.
Now it tests on real characters, not on ASCII values.
Maybe the ASCII values are keyboard-dependent.
Please reload 'Word search.txt'
Now it tests on real characters, not on ASCII values.
Maybe the ASCII values are keyboard-dependent.

Please reload 'Word search.txt'
- rbytes
- Posts: 1338
- Joined: Sun May 31, 2015 12:11 am
- My devices: iPhone 11 Pro Max
iPad Pro 11
MacBook
Dell Inspiron laptop
CHUWI Plus 10 convertible Windows/Android tablet - Location: Calgary, Canada
- Flag:
- Contact:
Re: Word search
I reloaded Word Search and put in the debug pauses. I don't know why, but it did not do a debug pause in either place when I ran the program. So I commented out Set Toolbar Off so that I could manually select debug mode and check the values of the two variables you asked about. You referred to them as .pat$ and .sel$, but they just showed in the debug list as PAT$ and SEL$. They were both = "". The Error still appeared, no matter how I changed the Text pattern and Selection fields.
I have attached screen photos. The first shows the error message that appears when I use my own values. The other shows the same error message when I use the default values.
Hope this helps.
I have attached screen photos. The first shows the error message that appears when I use my own values. The other shows the same error message when I use the default values.
Hope this helps.
- Attachments
-
- image.jpg (408.98 KiB) Viewed 4066 times
-
- image.jpg (541.13 KiB) Viewed 4066 times
The only thing that gets me down is gravity...
- Dutchman
- Posts: 858
- Joined: Mon May 06, 2013 9:21 am
- My devices: iMac, iPad Air, iPhone
- Location: Netherlands
- Flag:
Re: Word search
You did not give 'Enter'
Even with the default values you should give 'Enter' (2 times) otherwise the program does not know that the fields changed.
If you enter text, you should also finish with 'Enter'
Both fields should be 'entered' before touching 'Search'
I'm quite sure that this solves the problem.
Now I can sleep soundly


Even with the default values you should give 'Enter' (2 times) otherwise the program does not know that the fields changed.
If you enter text, you should also finish with 'Enter'
Both fields should be 'entered' before touching 'Search'

I'm quite sure that this solves the problem.

Now I can sleep soundly

- rbytes
- Posts: 1338
- Joined: Sun May 31, 2015 12:11 am
- My devices: iPhone 11 Pro Max
iPad Pro 11
MacBook
Dell Inspiron laptop
CHUWI Plus 10 convertible Windows/Android tablet - Location: Calgary, Canada
- Flag:
- Contact:
Re: Word search
Yes, this was the solution. Thanks for your help.
I remember now having this problem when trying to load files into Poly Designer after typing the name into a field. Unfortunately it is not intuitive to press Enter, since outside of smartBASIC it is rarely required. I wonder if Mr. K would consider a feature request to make the Enter occur automatically after anything is typed into a field...
I remember now having this problem when trying to load files into Poly Designer after typing the name into a field. Unfortunately it is not intuitive to press Enter, since outside of smartBASIC it is rarely required. I wonder if Mr. K would consider a feature request to make the Enter occur automatically after anything is typed into a field...
The only thing that gets me down is gravity...
- Mr. Kibernetik
- Site Admin
- Posts: 4787
- Joined: Mon Nov 19, 2012 10:16 pm
- My devices: iPhone, iPad, MacBook
- Location: Russia
- Flag:
Re: Word search
How to detect that typing into a field is finished?
- rbytes
- Posts: 1338
- Joined: Sun May 31, 2015 12:11 am
- My devices: iPhone 11 Pro Max
iPad Pro 11
MacBook
Dell Inspiron laptop
CHUWI Plus 10 convertible Windows/Android tablet - Location: Calgary, Canada
- Flag:
- Contact:
Re: Word search
I went over the field commands again, and I think you have already provided a solution with the command FIELD_TEXT$(N$). Here is a little test I coded, which allows me to extract characters from a field and use them without pressing Enter, perfect for a file requester.
Once you run this program, type anything into the text field, or just leave the default text as "cow". When you press the Save button your entry will appear below the button with the extension ".jpg" appended. You can repeat this action as many times as you want. You never have to press Enter to confirm your entry, since the FIELD_CHANGED(M$) command is not being used.
Code: Select all
GRAPHICS
GRAPHICS CLEAR 0,0,0
N$ = "Entry"
A$ = "cow"
M$ = "Save"
FILL COLOR 0,0,0
FIELD N$ TEXT A$ AT 100,100 SIZE 200,40
BUTTON M$ TEXT M$ AT 100,200 SIZE 100,60
DO
IF BUTTON_PRESSED(M$) THEN
R$ = FIELD_TEXT$(N$)&".jpg" 'Extract the characters from the field
FILL RECT 100,320 TO 300,380 'Erase previous filename
DRAW TEXT R$ AT 100,320 'Display new filename
ENDIF
UNTIL 0
Last edited by rbytes on Mon Jul 20, 2015 6:54 pm, edited 2 times in total.
The only thing that gets me down is gravity...
- Mr. Kibernetik
- Site Admin
- Posts: 4787
- Joined: Mon Nov 19, 2012 10:16 pm
- My devices: iPhone, iPad, MacBook
- Location: Russia
- Flag:
Re: Word search
In smart BASIC text fields does not require "enter" to be pressed.
In the program above you enter text to text field and then press button - and text from text field is printed. So there is no need to press "enter" for finishing text input in text field.
Code: Select all
FIELD 0 AT 0,100
BUTTON 0 TEXT "button" AT 0,140
1 IF NOT BUTTON_PRESSED("0") THEN 1
PRINT FIELD_TEXT$("0")