When I create a msgbox can I have my own title instead of it saying
Microsoft Access?
Also - anyway of sizing it?
Thanks In Advance
Dave
Allen Browne - 08 Mar 2008 11:58 GMT
Too easy:
MsgBox "Say what?",,"Put your title here"
You can't control the size of the message box. You can include a CrLf
(carriage return + line feed) in the text to break it into shorter lines.

Signature
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.
> When I create a msgbox can I have my own title instead of it saying
> Microsoft Access?
>
> Also - anyway of sizing it?
Dave - 08 Mar 2008 12:15 GMT
Thank you again Mr Allen Browne
> Too easy:
> MsgBox "Say what?",,"Put your title here"
[quoted text clipped - 6 lines]
>>
>> Also - anyway of sizing it?
Cheese_whiz - 08 Mar 2008 12:11 GMT
Hi Dave,
> When I create a msgbox can I have my own title instead of it saying
> Microsoft Access?
The third argument in MsgBox() provides the place for a window title:
If MsgBox("Click the ok button if you love cheese!", vbOkOnly, "Your title
here") = ok Then
blah blah blah
> Also - anyway of sizing it?
I'm pretty sure that if you want to size it you may have to just create and
use a separate form instead of using the built-in msgbox function.
HTH,
CW
Dave - 08 Mar 2008 15:57 GMT
Thanks CW
what is the second argument? I have is blank you have "vbOkOnly"
Can you explain.
And yep a new form instead of a msgbox would be satisfactort but I am
finding that "resizing" was not as important as I first thought.
Thanks again
dave
> Hi Dave,
>
[quoted text clipped - 15 lines]
> HTH,
> CW
tedmi - 08 Mar 2008 16:26 GMT
Look up "MessageBox" in Access Help.

Signature
TedMi
Dave - 08 Mar 2008 23:36 GMT
Thanks guys
dave
> Look up "MessageBox" in Access Help.
Cheese_whiz - 08 Mar 2008 16:46 GMT
Hi Dave,
The second argument is for the buttons you want to show up on the message
box. You should, as suggested, look it up, though. That way you'll be
familiar with all the arguments. It's a pretty commonly used function.
CW
> Thanks CW
>
[quoted text clipped - 27 lines]
> > HTH,
> > CW
Linq Adams - 08 Mar 2008 17:54 GMT
And the reason yours works with a blank in the second argument is that
"vbOkOnly" is the default for this argument.

Signature
There's ALWAYS more than one way to skin a cat!
Answers/posts based on Access 2000/2003
Dave - 08 Mar 2008 23:46 GMT
OK - now I want to take it one step further and add a second potential
search field:
But this did not work - and this time I don't thik it is a quote error
stLinkCriteria = "[phone_1]= '" & txtSearchPhones & "'" & " Or [phone_2]='"
& txtSearchPhones & "'" & " Or [phone_3]='" & txtSearchPhones & " Or
[last_name]='" & txtSearchLastName & "'"
what have I done wrong?
Thanks again
dave
> When I create a msgbox can I have my own title instead of it saying
> Microsoft Access?
[quoted text clipped - 4 lines]
>
> Dave
Dave - 09 Mar 2008 00:50 GMT
Disregard my last post - it was in the wrong place.
maybe some sleep is needed???
dave
> OK - now I want to take it one step further and add a second potential
> search field:
[quoted text clipped - 16 lines]
>>
>> Dave