Keep UserForm Visible While Other Workbooks Are Open
Oct 15, 2006
I have a workbook with 'Application.Visible = False' in the 'Workbook
open' event, as well as 'Userform1.show'. The relevant Desktop shortcut
is set up for the application to run 'Minimized' and to start in
"C:Program FilesMicrosoft OfficeOFFICE11".
In this manner, when the shortcut is Dbl clicked, the userform appears
with no visible evidence of Excel having been started. The
application.visible attribute is reset in the 'workbook close' event
with :"Application visible = true.
All of this works extremely well, however wilst previously opened
workbooks remain open and visible when I start this workbook, while the
workbook is opened I an unable to start any other excel workbook via
their shortcuts. I can however start a new instance of Excel then
browse to the workbook to open it.
MY QUESTION: How do I allow users to start any of their Excel
workbooks via their shortcuts while my application is running and the
userform showing?
View 6 Replies
ADVERTISEMENT
Dec 28, 2009
I have an excel sheet that has a userform on, when this is open my users are required to cross reference with another excel sheet they have just typed up to make sure they enter the right information into the userform. The only problem i have is, when the userform is open my users cant access any other excel workbooks.
View 2 Replies
View Related
Dec 3, 2008
I have built a sub that prompts the user for a folder then opens every workbook in the folder 1 at a time to get stats on the contents of each workbook. Worked like a dam until I ran into an unexpected bug. Some of the users built on open events in their workbooks. ...
Right now my routine inventories workbooks to get formula counts, cell counts, most complex formula, highest value... it does this by looping throught the sheets and the cells. If there is a way of obtaining those stats without opening the workbook I may need to rethink a lot of my work.
way to suppress the code in the target workbook I open through workbooks.open
View 9 Replies
View Related
Mar 10, 2009
How do I get a workbook to open with a selected sheet visible, or preferably all hidden? I already have a userform that opens upon opening the workbook that the user 'Enters' the workbook with.
My untidy method would have been to use an If -Then statement for each sheet in the Private Sub Workbook_Open. Is there a neater way of doing it?
View 6 Replies
View Related
Jun 19, 2002
I want to open a workbook, using a button, but I don't want the workbook to be visible. I'm looking for something similar to the visible = false that you can use when opening a database file. If I use the visible = true command after the workbooks.open command, it hides the workbook that the the code is in and not the one that the code is opening.
Currently I'm just using the workbooks.open command, but I just want the file I'm opening to open in the background.
View 6 Replies
View Related
Nov 8, 2006
I was working on a multi-tab spreadsheet (7 tabs to be exact) and I went to hide one of the tabs and all of a sudden the worksheet went away and I was left with my empty personal.xls spreadsheet. If I go into tools and visual basic I see my spreadsheet listed as VBAProject (Durex Sales Oct 1 to Oct 28 06.xls) with the 7 sheets listed below it within a folder called Microsoft Excel Objects, but I can't get it back in spreadsheet form.
View 5 Replies
View Related
Aug 5, 2014
I have a Userform that it makes possible to step through the the spreadsheet. It works with Previous and Next buttons. The Userform opens with a doubleclick. This works fine, but when I use an autofilter and the criteria reduces the number of rows, the Userform shows the hidden rows as well as the filtered rows. How could it be made that it only steps through the visible rows?
View 2 Replies
View Related
Jul 11, 2007
I have a Userform that allows you to step through the the spread sheet that works with Previous and Next buttons. This works fine.
When I use an autofilter where the criteria reduces the number of rows the Userform shows the hidden rows as well as the filtered rows. how can I make it just show the visible rows.
View 14 Replies
View Related
Sep 20, 2007
I have a form to allow users to select and print pages from a workbook.
Private Sub UserForm_Initialize()
Dim sht As Worksheet
For Each sht In ActiveWorkbook.Worksheets
ListBox1.AddItem sht.Name
Next sht
Me.Height = 128
End Sub
Only problem is that this lists all worksheets in the form. Need to modifying it so that it does not list worksheets that are xlSheetVeryHidden.
View 2 Replies
View Related
Aug 8, 2006
I have some code to put a GIF animation into a web browser on a userform. This works fine - on its own. However, once the GIF has loaded I want to run a whole bunch of code in the background. If I run the code all at once, the userform appears but the picture doest show - but when I place a breakpoint between loading the userform and the main sub routine of my code - the GIF loads and the animation is shown all the time my code is running in the backgorund.
View 4 Replies
View Related
Oct 20, 2006
In design mode on my UserForm, I have an object on top of all other objects (it's hidden until a button is clicked). That's how I designed it and it was working fine when I ran the form. Now, when I run the form and click the button, the object appears at the bottom below all other objects. I've tried closing Excel & re-opening it, setting the ZOrder in design mode and in the CommandButton code--nothing works. If I did do something to cause this--I have no idea what it was. I've been moving and re-sizing some objects, but not adjusting the ZOrder.
View 9 Replies
View Related
Apr 10, 2008
I have a couple of Inactive controls in my userform. I need to activate them only if a certain condition is found to be true and also dynamically give them their name and caption property.. i have an idea how to loop through controls like my code below but have no idea how to loop through just inactive controls.
Dim ctl As Control
For Each ctl In Me.Controls
If TypeOf ctl Is Label Or TypeOf ctl Is TextBox Then
ctl.Visible = True
End If
Next ctl
Auto Merged Post Until 24 Hrs Passes;The reason I want to do it this way is because if I dynamically create controls, I am able to see it in my userform at runtime but those controls actually don't get saved in the userform for future use.
View 7 Replies
View Related
May 26, 2014
I have a user form where people fill in data into text boxes. some text boxes remain hidden if the user does not need to fill in the requested field. but when the command button is submitted all text boxes hidden or otherwise are copied to clip board.
VBA in order for only visible text boxes to be copied to clip board. I was thinking of some sort of if statement around the vba to copy to clipboard but nothing i use works.
View 5 Replies
View Related
Dec 23, 2009
I have put calendar in my form and I want it to be visible only if I click on the combobox and make it invisible when date gets filled in the combobox.
I wrote the following code but it gives me runtime error -2147417848(80010108) Automation error :The object invoked has disconnected from its clients.
View 9 Replies
View Related
Oct 22, 2012
I have a MultiPage User Form, it has 2 tabs within the User Form.
I want to display Tab #1 (the first tab) as the 'visible/active' Tab for the user upon opening the user form. How do I do that?
Usually, I would open a User Form with frmMyForm.Show in a private module, to show the form. But now I have 2 Tabs, and want to select a certain Tab upon opening it?
View 2 Replies
View Related
Jul 6, 2013
I have a user form with multipage.
With the use of the option buttons,the page needs to made visible or invisible.
Example: on Page one, i have placed radio buttons as page2,Page3&page4.
By default only page 1 should be visible and when we select radio button page2, page2 should become visible or else it should be invisible,when we select radio button page3, page3 should become visible or else should remain invisible.
View 5 Replies
View Related
Jul 4, 2012
What I would like to do is to be able to open a second workbook from a user form, preform some work on it then save and come back to the same place in the original user form.
So in steps:
1 : user clicks command button to open user form
2: user then clicks on command button on userform that opens 2nd workbook via a yes / no message box, but closes userform on 1st workbook (would be ideal if this could stay open, but hidden)
3: user then does work on 2nd workbook,
4: userform on 2nd workbook saves then activates the 1st workbook and reopens the userform
This is where no matter what I try I cant get the command button on the 1st userform to be clicked automatically so the yes / no message box appears.
This is part of the code in the 2nd sheet commandbutton that saves / closes / opens
Code:
Unload Me
ActiveWorkbook.save
Windows("ABC.xlsm").Activate
Sheets("Request Sheet").Activate
Call Sheets("Request Sheet").ForceClickOnBouttonXYZ
Call UserForm1.CommandButton6_Click 'this is where I cant get it to work!!
Windows("xyz.xlsm").Close
ABC is the 1st workbook
xyz is the 2nd workbook
This is the code on the 1st workbook I use to call on the 2nd workbook
Code:
Public Sub ForceClickOnBouttonXYZ() Call CommandButton1_Click End Sub
View 7 Replies
View Related
Feb 23, 2010
I have a macro on a workbook that when I run it, it's supposed to open a workbook, but it opens another workbook also.
How do I prevent this behavior?
View 9 Replies
View Related
Nov 14, 2006
I have a UDF in a workbook that works fine until I open another workbook which contains the same UDF. When Excel does a full recalculation it not only recalculates the currently selected workbook but also recalculates all other open workbooks. Something from the currently selected workbook appears to interfere with the other open workbooks as these other workbooks show #VALUE! in all cells that use the UDF. Is there some way to make a UDF unique only to the workbook that it resides in such that opening another workbook with the same named UDF won't interfere with it?
Function SumRangeLookup(FromCode, ToCode, Database, FromColumn, ToColumn)
Dim Code As Range
Dim MonthColumns As Integer
Dim CalcResult As Double
SumRangeLookup = 0
For Each Code In Range(Database)
On Error Goto SkipCode
If Code >= FromCode And Code <= ToCode Then
For MonthColumns = FromColumn To ToColumn
CalcResult = CalcResult + Code.Offset(0, MonthColumns)
Next MonthColumns
End If
Next Code
SumRangeLookup = CalcResult
SkipCode:
End Function
View 6 Replies
View Related
Feb 4, 2014
I have a workbook open. When I try to open a separate workbook, it opens already opened workbook (basically linking the workbooks as one). I want to have my workbooks on two separate screens this is preventing that. How to unlink these workbooks.
View 1 Replies
View Related
Nov 14, 2008
Having some issues moving between 2 open workbooks. I just want to add a new workbook, select the first workbook and active sheet then move that sheet to the new workbook that was just made and lastly save the new workbook with the name of the sheet that was just moved. I have some code but it is not working correctly.
View 5 Replies
View Related
Jan 27, 2009
Sub vocab6()
Dim fname As String
fname = "c:Documents and Settings
obertDesktopvocab.xlsx"
Workbooks.Open Filename:=fname
Workbooks(fname).Worksheets("tangible nouns").Range("A1").Value = 9
End Sub
I just want to open a workbook saved on my desktop (from a different workbook), and insert 9 into the first sheet (which is named tangible nouns).
View 9 Replies
View Related
Jun 24, 2009
I have a script below that opens all the workbooks in a folder based on a msgbox. The script works as is. However what I would like to do is remove the msgbox and have the script go back and forth between the folders.
Example it would open one workbook in the (Large Area)folder call my other script (Hazleton_Data_Conversion) Return Open a workbook in (Varsity) Folder Call the
my (Hazleton_Data_Conversion)and repeat the process till all the workbooks in both folders have been processed.
Like I said this script works with the msgbox I just like to change to without msgbox and to flip back and forth.
View 3 Replies
View Related
Dec 2, 2009
I am using a macro to open .txts in excel in seperate workbooks
I look for a macro to save all open woorksbooks in .xls
View 12 Replies
View Related
Oct 17, 2013
I have a macro that opens all workbooks in a folder and searches for a few terms returning the appropriate rows, my problem is that someone has decided to protect some of the sheets so when the files are opened you get the password box popup. I have added the (filename, readonly) segment however this has not solved the issue, the macro displays an error stating a workbook is open.
Is there any way to resolve this without unprotecting the sheets?
View 2 Replies
View Related
Jul 19, 2007
I am trying to use Workbooks.Open() function in a function. The function is not working as desired (it does not return workbook object), but when i use same piece of code in sub(macro), it works fine. I am not sure if I cant use this API inside function. I am using function because I would like to call this inside cell and that should return some value.
View 9 Replies
View Related
Jun 11, 2009
I would like to run a macro on all open workbooks except the workbook where the macro is saved. I thought I could just do the following but it does not run my macro on all the work books:
Sub apply()
For Each wb In Workbooks
If wbk.Name ThisWorkbook.Name Then
Debug.Print
nominee_name
End If
Next wb
End Sub
View 9 Replies
View Related
Aug 23, 2007
I have written a VBA code to make a pivot table from data in another workbook,A, and transfer it to workbook B. I however dont want to restrict this code to workbook A only. This is because usually workbook A will have varying names everytime it is sent. I want to be able to get data from any other workbook that is open at the same time as work book B. What code can I use to select/activate another unspecified open workbook and get data from there?
View 3 Replies
View Related
Feb 25, 2008
I made an Excel based program that uses multiple workbooks with two main workbooks (“Master List” and “Products”) that all the others pull information from. I run into a problem when a user clicks the close X in the upper right hand corner and the entire application closes. I found some code that will let me close all the workbooks but one (the code is put in the “Products” workbook in the BeforeClose event).
For Each wb In Workbooks
If Not wb Is ThisWorkbook Then
wb.Close SaveChanges:=True
End If
Next wb
Is there a way to modify the code so it will close all the workbooks but the two main ones if someone clicks the close X button in the upper right hand corner?
View 3 Replies
View Related
Mar 15, 2008
I have a folder containing a number of worksheets, these worksheets are of 2 types, a customer submitted workbook and, associated with each of these, anything between 2 and 7 locally created workbooks. I have a macro which opens a customer workbook and all the relevant local workbooks. My problem is that I need to declare a variable for each of the workbooks in the form
Dim N As Integer, WbN As workbook,Wb1 As workbook
If activeworkbook. name Like *ALL.xls Then
Set wb1 = activeworkbook
Else
Set WbN = activeworkbook
N=N+1
End If
This code is contained within a Found files loop
View 2 Replies
View Related