Consulting

Results 1 to 15 of 15

Thread: Sleeper: Few Quick Questions

  1. #1
    VBAX Master
    Joined
    Jun 2006
    Posts
    1,091
    Location

    Sleeper: Few Quick Questions

    1) I remember I have to hold down one button to see the other controls not in the toolbox initially, I just can't remember the button to hold down- I am looking for the calendar control

    2) How do I switch to a tab based on the name of the tab - the name of the tab is Credits but I don't know what number the tab would be

    3) I had another question but I can't remember it now, when I remember I will ask it

  2. #2
    VBAX Master
    Joined
    Jun 2006
    Posts
    1,091
    Location
    Oh I remember, this is the code I am using to bring up the Save As dialog, I just want it to change it so it always chooses Microsoft Office Excel Workbook as the file type. How do I do this?

    If Not Application.Dialogs(xlDialogSaveAs).Show Then
            MsgBox "The Report did not Save."
        End If
    Last edited by Djblois; 03-30-2007 at 06:54 AM.

  3. #3
    Distinguished Lord of VBAX VBAX Grand Master Bob Phillips's Avatar
    Joined
    Apr 2005
    Posts
    25,453
    Location
    The code?

  4. #4
    Distinguished Lord of VBAX VBAX Grand Master Bob Phillips's Avatar
    Joined
    Apr 2005
    Posts
    25,453
    Location
    BTW, I forgot something last week. If and when I remember, I will probably forget to tell you.

  5. #5
    VBAX Master
    Joined
    Jun 2006
    Posts
    1,091
    Location
    Sorry, I added the code. Also what about help with the first 2 questions also?

  6. #6
    VBAX Master
    Joined
    Jun 2006
    Posts
    1,091
    Location
    Kick

  7. #7
    Moderator VBAX Wizard lucas's Avatar
    Joined
    Jun 2004
    Location
    Tulsa, Oklahoma
    Posts
    7,323
    Location
    Why is it that you think we are mind readers.....
    1..userform or sheet controls
    userform...right click on the toolbox and select additional controls.
    sheet controls...from the control toolbox select more controls.
    Steve
    "Nearly all men can stand adversity, but if you want to test a man's character, give him power."
    -Abraham Lincoln

  8. #8
    VBAX Master
    Joined
    Jun 2006
    Posts
    1,091
    Location
    I dont think you are mind readers. I think I give you enough information, if I don't and people ask for more I answer.

  9. #9
    Distinguished Lord of VBAX VBAX Grand Master Bob Phillips's Avatar
    Joined
    Apr 2005
    Posts
    25,453
    Location
    Quote Originally Posted by Djblois
    1) I remember I have to hold down one button to see the other controls not in the toolbox initially, I just can't remember the button to hold down- I am looking for the calendar control

    2) How do I switch to a tab based on the name of the tab - the name of the tab is Credits but I don't know what number the tab would be

    3) I had another question but I can't remember it now, when I remember I will ask it
    I thought your follow-up post superceded this.

    1) Right click the toolbox, you see additional controls then.

    2) worksheet tab, multipage tab?

  10. #10
    Moderator VBAX Wizard lucas's Avatar
    Joined
    Jun 2004
    Location
    Tulsa, Oklahoma
    Posts
    7,323
    Location
    did you try help before you posted this basic question?
    1) I remember I have to hold down one button to see the other controls not in the toolbox initially, I just can't remember the button to hold down- I am looking for the calendar control
    All I am saying is that your working on addins, etc...fairly advanced for a beginner group but you post a question that you should be able to find the answer to in 10 seconds with a little research on your own. That's what we want to encourage here. You also seem to post as your thinking...on the fly. Take just a few minutes to think about what your question is...re-read it and see if it makes sense to you before you post it to the world.

    If you can't find it in the help files then do your own research here at the forum. Half of the help I give you I found the aswser to by searching this forum or kb....you could do the same before you post is all I am trying to say. Most of these questions have already been answered once at least here. For sure the one about the tab naming and I'm pretty sure you knew that. So why ask us to search for you when you could do it?
    Steve
    "Nearly all men can stand adversity, but if you want to test a man's character, give him power."
    -Abraham Lincoln

  11. #11
    VBAX Master
    Joined
    Jun 2006
    Posts
    1,091
    Location
    I am sorry but I searched and I still can't find this one:

    Oh I remember, this is the code I am using to bring up the Save As dialog, I just want it to change it so it always chooses Microsoft Office Excel Workbook as the file type. How do I do this?

    If Not Application.Dialogs(xlDialogSaveAs).Show Then MsgBox "The Report did not Save." End If

    Maybe this isn't possible?
    Last edited by Djblois; 03-30-2007 at 11:46 AM.

  12. #12
    VBAX Contributor CaptRon's Avatar
    Joined
    Mar 2007
    Location
    Austin, Texas
    Posts
    141
    Location
    Perhaps you could try this....
    If Not Application.GetSaveAsFilename(InitialFileName:="", _
           filefilter:="Microsoft Excel Workbook (*.xls), *.xls") Then
    MsgBox "The Report did not Save."
    End If
    Before you criticize someone, you should walk a mile in their shoes. That way, when you criticize them, you're a mile away and you have their shoes.

  13. #13
    Administrator
    VP-Knowledge Base
    VBAX Grand Master mdmackillop's Avatar
    Joined
    May 2004
    Location
    Scotland
    Posts
    14,489
    Location
    As Steve says, it's all in the help file
    GetSaveAsFilename Method
    MVP (Excel 2008-2010)

    Post a workbook with sample data and layout if you want a quicker solution.


    To help indent your macros try Smart Indent

    Please remember to mark threads 'Solved'

  14. #14
    VBAX Contributor CaptRon's Avatar
    Joined
    Mar 2007
    Location
    Austin, Texas
    Posts
    141
    Location
    Yes, sir. That's where I found this method about two years ago when I needed a way to suggest to the user how to properly name a saved document. I didn't set initialfilename as "", but placed something there that would guide them. It was in the VBE help.

    BTW. I've posted two inquiries in this forum myself which have been answered expeditiously and my issues were resolved promptly. I appreciate that so much. But even more than that, I've gleaned a number of practical tips and solutions from this forum that I have managed to apply to several of my current work projects simply by "trolling" through the forum and exploring threads that sound interesting to me. There is a wealth of information here to be explored.

    I posted to his question, not because I'm a great VBA wizard, but because I had used the GetSaveAsFilename Method, I knew it would do what he asked, and others in this forum have been very helpful to me. It was an opportunity at my level of limited understanding to contribute in return.
    Before you criticize someone, you should walk a mile in their shoes. That way, when you criticize them, you're a mile away and you have their shoes.

  15. #15
    Moderator VBAX Wizard lucas's Avatar
    Joined
    Jun 2004
    Location
    Tulsa, Oklahoma
    Posts
    7,323
    Location
    Glad your reading and trying to contribute CaptRon. You will learn much here by following the posts.....I'm personally not sure exactly what Daniel is trying to do yet.....
    Steve
    "Nearly all men can stand adversity, but if you want to test a man's character, give him power."
    -Abraham Lincoln

Posting Permissions

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