Results 1 to 4 of 4

Thread: [VB6] Crossword Puzzle Constructor

  1. #1

    Thread Starter
    Lively Member vbLewis's Avatar
    Join Date
    Feb 2009
    Location
    USA
    Posts
    126

    [VB6] Crossword Puzzle Constructor

    This is a program i threw together to generate crosswords based on a word/clue list. You can then print out the generated puzzle on a printer or solve it from within the program.

    For those that haven't followed the thread on creating the program with SamOscarBrown you can view it here:
    https://www.vbforums.com/showthread....word-Generator

    Name:  ss8.jpg
Views: 844
Size:  52.3 KB
    Attached Files Attached Files

  2. #2
    Fanatic Member
    Join Date
    Aug 2016
    Posts
    673

    Re: [VB6] Crossword Puzzle Constructor

    [QUOTE=vbLewis;5563158]This is a program i threw together to generate crosswords based on a word/clue list. You can then print out the generated puzzle on a printer or solve it from within the program.

    For those that haven't followed the thread on creating the program with SamOscarBrown you can view it here:
    https://www.vbforums.com/showthread....word-Generator

    Name:  ss8.jpg
Views: 844
Size:  52.3 KB[/QUOT]

    The form appears too large for my laptop

  3. #3

    Thread Starter
    Lively Member vbLewis's Avatar
    Join Date
    Feb 2009
    Location
    USA
    Posts
    126

    Re: [VB6] Crossword Puzzle Constructor

    Quote Originally Posted by xxdoc123 View Post

    The form appears too large for my laptop
    you can constrain the max size of generated puzzles by limiting the width and height of the grid.

    in modPuzzle.bas at the top is this line of code
    Code:
    Public Const MAX_PUZZLE_ROWS As Long = 36
    use this formula to figure out the correct number to put here
    Code:
    (<monitor resolution height> - 106)  /  35) - 2

    so for example if your monitor resolution is 1080p height then you would use
    Code:
     (1080 - 106 / 35) - 2 = 25
    
    Public Const MAX_PUZZLE_ROWS As Long = 25
    that should limit the puzzles from being generated to large for your screen.
    my resolution is 2560x1440 which is why its 36


    edit: just to explain what the numbers mean - 106 is the width of the clues in pixels, 35 is the width of each textbox in the grid in pixels. taking off 2 from the answer allows for spacing and borders.
    so your using this formula: (<monitor height resolution> - <clue list width> / <puzzle textbox size> ) - <border and spacing>
    you can also make the grid textbox's a little smaller to fit more into to screen area
    just also be aware that not as many words may be resolved the smaller the grid becomes

    regards
    lewis
    Last edited by vbLewis; Apr 10th, 2022 at 10:08 PM.

  4. #4
    PowerPoster
    Join Date
    Jul 2010
    Location
    NYC
    Posts
    5,651

    Re: [VB6] Crossword Puzzle Constructor

    Very nice.

    Have you considered using the Across Lite .puz file format? It's the de facto standard and having a VB6 implementation would be pretty cool. That would allow interoperability with puzzles generated by most very popular crossword apps. If you're interested the format specifications can be found here. There's also a much simpler plain text version described here, but I'm not sure how widespread the compatibility is.

    For a long time NYT Crosswords were distributed as that. A lot crossword fans were quite upset when NYT stopped that to move to a closed proprietary format that could only be used with their own apps with a rather ****** lie about not wanting to adapt to the tools of others and the need to support new features that still don't exist a year later. Really they just wanted to force people using 3rd party apps to use the official app.
    Last edited by fafalone; Apr 14th, 2022 at 07:55 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width