CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Jun 2001
    Posts
    65

    How can I do this....?

    Hi all,

    I have a grid which is a bitmap (picture box) with a path drawn on (for a maze game). I have another picture box as a player (another bitmap). I also have 4 buttons : UP / DOWN / LEFT / RIGHT.

    Each click of the button moves the player picture box by a designated amount, but what I want to be able to achieve is to be able to tell VB to grey out the UP and DOWN buttons when the path (for walking on) on the original bitmap, only runs from left to right. Otherwise the player could just walk any where on the screen!

    Is it possible to do this? Any code...?

    Thanks

    Mark


  2. #2
    Join Date
    Jun 2001
    Location
    Israel
    Posts
    228

    Re: How can I do this....?

    sub DisableVertical()
    cmdUp.Enabled=false
    cmdDown.Enabled=false
    end sub
    i hope this answers your question

    ----------
    The @host is everywhere!
    ----------

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

Featured