We’d like to remind Forumites to please avoid political debate on the Forum.

This is to keep it a safe and useful space for MoneySaving discussions. Threads that are – or become – political in nature may be removed in line with the Forum’s rules. Thank you for your understanding.

📨 Have you signed up to the Forum's new Email Digest yet? Get a selection of trending threads sent straight to your inbox daily, weekly or monthly!

Honestly last question. Excel Form VB

Hello... Feel embarrased to keep asking as you lot have bascially made my form for me! I'm reading up though and am working on my day off. I'm trying! lol

Well I want to hide the top of my Excel Form which is made on the VB. I want to hide the bar with the X in the corner.

Just need to remove the header - nothing seems to be on the internet....
Help me to help you :santa2:
«1

Comments

  • I want to hide the bar with the X in the corner.
    It's tricky but it can be done.

    Download FormFun.zip from http://www.bmsltd.co.uk/Excel/Default.htm to see how.
  • Tried but it doesn't seem to remove it.... I almost remember the lesson at college! damn I remember there being a lesson but not how to do it lol

    Any other ideas?
    Help me to help you :santa2:
  • Tried but it doesn't seem to remove it.
    Yes it does. Click Run Demo and untick Caption.
  • Hi Robert,

    I wish you'd stay on one thread...? I'm getting lost here :-)

    Anyway, I'm guessing you don't want the user to be able to close the form...?

    This will do it

    Private Sub UserForm_QueryClose(Cancel As Integer, CloseMode As Integer)
    If CloseMode = vbFormControlMenu Then
    Cancel = True
    MsgBox "You can not close the form"
    End If
    End Sub



    I have included this in the upload I have made for you in your other post

    Best Regards

    Kevin
  • Excellent that wasn't it but I'll use it anyway thanks lol I guess the only way to actually close it is ALT + F4 then?

    I actually wanted to make my own close button and I want to remove the big blue button and the X

    Thanks, Good to be at home? lol
    Help me to help you :santa2:
  • I added a button for you to close, there are ways to remove the title bar from the forms using the WinAPI if you want the code I'll dig it out. Yeah and good to be at home, beer and football instead of database programming and web pages.
  • lvwLitem.SubItems(3) = CCur(txtqty * txtprice)

    debugging error...?

    What exactly are all these other buttons#? They don't seem to ahem work? lol
    Help me to help you :santa2:
  • Ok this is listview code, I said that you may need to add some error trapping to ensure that an entry exists. What is the scenario in which this is occuring..?

    Is this occuring when you try to add a second entry...?
  • When I want to add

    1 pet - just click add and quit to leave

    2 pets - add second pet first then add then save and quit??

    What should I be clicking for what ?? I'm confused lol are you on msn?
    Help me to help you :santa2:
  • To answer the question though (Sorry) - these are not other buttons - this is code to add an item to the listview control, the code is performing the following:

    lvwLitem.SubItems(3) - this is the 3rd sub entry in the listview control
    = CCur () is a function to convert whatever is in the brackets to the currency format.

    txtqty and txtprice - these are names of your textboxes which I am using to try and create a calculation.

    The whole line requires that a numeric entry exists in both txtqty and txtprice for it to run.

    try and delete this line and try again or ensure that an entry exists with both.

    Best Regards

    Kevin
This discussion has been closed.
Meet your Ambassadors

🚀 Getting Started

Hi new member!

Our Getting Started Guide will help you get the most out of the Forum

Categories

  • All Categories
  • 351.7K Banking & Borrowing
  • 253.4K Reduce Debt & Boost Income
  • 454K Spending & Discounts
  • 244.7K Work, Benefits & Business
  • 600.1K Mortgages, Homes & Bills
  • 177.3K Life & Family
  • 258.4K Travel & Transport
  • 1.5M Hobbies & Leisure
  • 16.2K Discuss & Feedback
  • 37.6K Read-Only Boards

Is this how you want to be seen?

We see you are using a default avatar. It takes only a few seconds to pick a picture.