Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 11-22-2013, 10:11 PM
Lostinvba Lostinvba is offline Trouble automatically running user form Mac OS X Trouble automatically running user form Office for Mac 2011
Novice
Trouble automatically running user form
 
Join Date: Nov 2013
Posts: 3
Lostinvba is on a distinguished road
Exclamation Trouble automatically running user form

Userform fully functions when I run it from the run tab in developer but when I open a new document from the template the form doesn't automatically show. I have the form code:
Code:
Option Explicit
Private Sub Userform_Initialize()
End Sub
Private Sub cmdSubmit_Click()
Select Case ""
    Case Me.txtContactName.Value
        MsgBox "Please fill-in the full name of the contact for the group."
        Me.txtContactName.SetFocus
        Exit Sub

….etc (all runs great)
and This Document code simply:
Code:
Private Sub Document_New()
FRM_room_block.Show
End Sub
My form is called "FRM_room_block" obv.
Reply With Quote
  #2  
Old 11-22-2013, 10:47 PM
fumei fumei is offline Trouble automatically running user form Windows 7 64bit Trouble automatically running user form Office XP
Expert
 
Join Date: Jan 2013
Posts: 440
fumei is on a distinguished road
Default

Just to confirm...

The userform is in the template file (not the document).
The .Show code in Document_New is in the template file.
Reply With Quote
  #3  
Old 11-23-2013, 03:26 PM
Lostinvba Lostinvba is offline Trouble automatically running user form Mac OS X Trouble automatically running user form Office for Mac 2011
Novice
Trouble automatically running user form
 
Join Date: Nov 2013
Posts: 3
Lostinvba is on a distinguished road
Default

Both are in the template file and the New Doc references the template file.
Reply With Quote
  #4  
Old 11-23-2013, 07:22 PM
Lostinvba Lostinvba is offline Trouble automatically running user form Mac OS X Trouble automatically running user form Office for Mac 2011
Novice
Trouble automatically running user form
 
Join Date: Nov 2013
Posts: 3
Lostinvba is on a distinguished road
Default Document_New vs ThisDocument_Open

Attached are the 2 different procedures I've tried without success and a screenshot of the Userform code box for ref. Thanks every/anyone.
Attached Images
File Type: jpg ThisDocument_Open.jpg (180.0 KB, 12 views)
File Type: jpg Document_New.jpg (170.9 KB, 11 views)
File Type: jpg Userform.jpg (196.7 KB, 10 views)
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Trouble automatically running user form I'm having trouble creating a Merge using label form and placing a shape in the text blockie Mail Merge 8 11-13-2013 11:28 PM
Trouble automatically running user form User Form placasse47 Excel Programming 3 08-01-2012 05:57 AM
Trouble automatically running user form Running a Macro in a protected form yessmarie Word VBA 1 05-25-2012 12:04 AM
Controlling Style when a user pastes into a form Cris0205 Word 0 08-05-2010 04:33 PM
Trouble updating a form TomCaesar Outlook 0 11-29-2006 10:52 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 01:54 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft