UserForms & Events: Cut-down Version Of The Spreadsheet

Dec 15, 2006

I am trying to reconstruct my problem with a cut-down version of the spreadsheet so possibly I might be able to post something in the future. Here is my scenario:-

1. workbook, containing 3 sheets opens with "sheet1" selected. Sheets 2 & 3 are hidden.

2. simple userform containing 1 combobox and 1 command button display as part of workbook_open() event. Combobox takes as its rowsource a range from sheet1

3.on pressing command button, userform is hidden (not unloaded), macro generates a dynamic SQL statement (using contents chosen from combobox), unhides "sheet2", selects "sheet2" which contains a querytable, updates the command text using the dynamic SQL, refreshes the querty with background refresh = false (i.e. query is completed before macro continues), re-hides "sheet2"

4. macro continues (still originating from the command button on userform), unhides "sheet3", selects "sheet3" which contains a pivottable, using the results of "sheet2" as its datasource.

5. The worksheet_activate() event of sheet3 includes code to refresh the pivot table so as soon as the sheet is selected the PT is refreshed "before the users eyes" with the new data.................

View 4 Replies


ADVERTISEMENT

UserForm Textboxes Triggering Events - Even After Events Have Been Disabled?

Oct 20, 2012

I have a UserForm with a Text Box, I populate that Text Box with a number (say 5) and then the following code runs:

Code:
Private Sub tbOverrideMokWh_Change()
Application.EnableEvents = False: Application.ScreenUpdating = False
With tbOverrideMokWh

[Code]....

After the Sub is run 1 time, it runs again. Why? I've disabled Events?

View 6 Replies View Related

Could Two Change Events (Conditions) Be Possible With Worksheet Change Events

Dec 13, 2012

I am aware that I can use single changing events in worksheet change events. For instance, if column 1, or A is changed, do something. This is only a single If statement, i.e. either the condition is true, or not. What I am not sure is if I can use two changing events, i.e. two conditions. For e.g. I would like if Column A value is X and Column B is "Active", action it, but only if two conditions are true.

For.e,g. The below syntax does not work. If it is only column A, it does work, but I want both A and B to be true, then copy and paste the target does not anything.

VB:
If Target.Column = 1 Then
If Target.Column = 2 Then
If Not Intersect(Target, Range("A2:A" & Rows.Count)) Is Nothing Then
If Not Intersect(Target, Range("B2:B" & Rows.Count)) Is Nothing Then
If Target.Value = "X" And Target.Value = "Active" Then

View 4 Replies View Related

Specify Excel Version To Run VB6

Jan 15, 2009

I have Excel 2003 and 2007 on my computer and I want open excel from vb6 but they are both called Excel.exe. So it opens both of them when I run my code. I renamed one of the exe's and I was going to do it that way but then it was going to do a whole bunch of reinstalling.

Can I specify which version of excel I want to run, in vba or vb6 code ?

Maybe by specify the path some how.

View 14 Replies View Related

Version Number?

Jan 19, 2010

If I want to create an Excel file that other users would use, and want to create a specific version number of the file. Is there a place I can save that information outside of the worksheets?

For example, lets say I create a file that is version 1.0. Can I save that somewhere in "Properties" or somewhere else so that "1.0" can't be modified, and if I come out with a different version say 2.0, I can update it?

View 9 Replies View Related

Set Default Version

Aug 23, 2007

As per title, I have both Excel 2003 & 2007 installed - I need to set 2003 as the default for opening xls files when double-clicking but can't seem to override 2007 which wants to hog all the action. I've been through the File Types menu and selected the 2003 version of Excel as the default, but it doesn't make the slightest difference.

View 9 Replies View Related

Get Version Of .dll File

Feb 2, 2008

how to get version number of the .dll file (in the path C:program files....) using VBA code. The properties of that .dll file has a tab named "Version". so i need the version number displayed on that tab.

View 3 Replies View Related

VBA To Change A Particular Cell Version 2

Dec 10, 2008

In a previous thread I asked for a solution to the following problem

Cells
A1 = 1
A2 = 2
A3 = 3
A4 = 4
etc.

What I want to do is when I click on cell A1 the value is put in cell C1.
When I click on cell A2, C1 changes to to A2 value and so on.

VERSION 2
The VBA I received is good for 1 range.
Is there a way to use multiple ranges? In my example above column A is the 1st range and cell C1 changes accordingly. Now i would like to use column B as a 2nd range and have cell D1 change accordingly.

View 2 Replies View Related

Automatically Update To New Version?

Sep 25, 2009

I have an excel based appliction that I distribute to about 150 people in the US, London, Hong Kong and Singapore. Distribution is currently done by email containing a link to a Sharepoint site (the email has the link, release notes, etc). The end users open the file and save it to their desktops, overwritting the previous version. I'm finding that many users are not updating their versions as they should be.

So what I'm wondering is if there's a way to have this process automated - so that when the user opens the file, it checks a repository (sharepoint or otherwise) for a more current version, then prompts the user to download it.

View 5 Replies View Related

Trapping File Version In VBA?

Dec 11, 2012

how I could amend the following code so that my target worksheet includes file versions? The worksheet range "Folder" contains a string specifying the target folder and the worksheet range "IncludeSubFolders" is either TRUE or FALSE. I can trap FilePath, FileName, FileSize and DateModified fine but not File Version (I'm working with DLL libraries).

Code:

Dim iRow As Long
Sub ListFiles()
iRow = Range("DatabaseStart").Offset(1, 0).Row
Call ListMyFiles(Range("Folder"), Range("IncludeSubFolders"))
End Sub

[Code]......

View 1 Replies View Related

Multipage - Vertical Tab Version

Jun 9, 2007

I need to create a multipage with tabs running down the left hand side. I cannot use the normal horizontal multipage control because this would result in an impossibly wide page. Is there a vertical multipage control? I could not find one? Or a way to convert the multipage control to show vertical tabs?

Please bare in mind that this vertical multipage will be shown in a form that already includes a normal horizontal multipage (I am using multipages within multipages too!).

View 9 Replies View Related

Database Version Control

Mar 11, 2009

We have a club membership database in Excel 2003. Unfortunately too many people can change it and we sometime use an old version for a mailout when there is a later version around. We have no easy, foolproof way of establishing which is the latest version.

Is there a way that a cell in the database can automatically have the date & time it was last changed (NOT last time it was read - Windows does that). Also a user name.
Failing that, is it possible to detect when anything has changed & when you try to close the file it requests a date & user which have to be entered before it closes ( this relies on the user putting in valid info but at least it's a start).
Ideally when you re-open the file it should say in A1, A2 - last changed .... by .....

View 9 Replies View Related

Autosave To Older Version

Jan 2, 2010

Please review the following and advise the one Best Connection needs to save in Excel 5.0/95 format without prompting me about incompatability issues

Sub Tomo() ....

View 9 Replies View Related

Vba Version: Search For Topics

Mar 21, 2007

I've made a workbook in office2002, and it's work fine. but when i run it from PC with office2000 I've encounterd some vba erorrs. NOW I want to search for topics talking about this topics.

--- In General Idea-----
How to be sure that my work will work fine with all versions.

View 3 Replies View Related

Trial Version That Expires

Jun 3, 2007

how i can make my excel file triel and can use just for 7 days?

View 4 Replies View Related

Return Version With VBA Code

Feb 15, 2008

Is there a way to find out which version of excel somebody is using within VBA?

View 2 Replies View Related

Run Different Code Based On Version

Aug 2, 2008

I am writing an excel 'tool' that must be compatabile with both Excel 2003 and Excel 2007. I originally wrote some functions using Application.Filesearch, and had to re-write that code due to the lack of Application.Filesearch in Excel 2007 (I used the chdir method). The chdir method is much slower the way I am using it, therefore, I would like to still use the Application.Filesearch method for those using Excel 2003. Now, I have the user select their excel version and run the correct macro. Is there a way to detect the Excel Version automatically and the call the correct macro?

View 2 Replies View Related

Version Limitations On Countifs Functions?

Mar 27, 2014

I recently bought a new Dell XPS 10 tablet with a keyboard. When I copied my spreadsheets from my old notebook, none of the countifs or countif functions are working, all popping out a zero. It work completely fine on my old notebook on which I have Excel 2010 installed. On the tablet I have the pre-installed Home & Student 2013 RT. Could this version have limitations to my functions? What can I do to get my functions working again?

View 4 Replies View Related

VBA Test For Finding Excel Version?

Dec 7, 2008

Is there a way in vba to test to see what version of Excel is being used? My macro would crash if their data would exceed the 65K row limit in Excel 2003. I have a message that pops up if they do that, and it handles the problem just fine, but if they are ALREADY using Excel 2007 (or whatever comes later) I don't want the message to appear.

View 9 Replies View Related

Convert MDY To DMY With Text Version Date?

Dec 12, 2011

I have some date data use MDY format. Want to convert to DMY format. But text to columns function doesn't work as those dates are text not numbers. How can I do the convertion?

examples:

3/14/19644/18/1964

View 9 Replies View Related

User To Enter Date (US Version)

Dec 13, 2011

I have a userform where I want the user to enter the date (US Version)

I want them to enter 121311

I want the textbox which I am using to show 12/13/11 when they exit from it.

Here is my code i am using:

Private Sub mm_built_Exit(ByVal Cancel As MSForms.ReturnBoolean)
Dim mm_date As Date
Me.mm_built.Text = Format(mm_date, "mmm/dd/yy")
End Sub

What shows when they exit the entry for the above is Dec/30/99

How do I get it to show correctly?

View 5 Replies View Related

References To Tables In Version 2007

Aug 18, 2007

The new table feature of Excel 2007 is IMO the best improvement over the 2003 version.

I have 3 questions about references to these tables:

1) When you reference to a cell in a table on the same row, you get the reference "#This Row". Why isn't there a "#This Column" reference?

2) Normally when you want to "fix" a reference to a cell you use the $ sign by hitting F4 (i.e. A1 -> $A$1). How can you do this with tables (Column1 will not change to $Column1 when hitting F4)?

3) When I have = sum(Column1) above Column1 and I drag this to a cell above Column2 I get =sum(Column2). However, when I have the formula {=sum(Column1)} this doesn't work. Why?

View 9 Replies View Related

Prevent Save As Version Message

Oct 17, 2006

I have an extensive application which I wrote using Excel 2002 (XP - Version 10). However it will likely be used on anything ranging from 2003 - 1997. When I tested it using Excel 97 it gave me the traditional [annoying] message asking if I was sure I wanted to save it under an earlier version than which it was created.

I want to get rid of this message (a lot of my users aren't the most computer literate and the more annoying messages I can avoid the better!)
I tried using:

Application.DisplayAlerts = False


but it doesn't affect this particular message. I need to know how to keep this message from popping up. Please Help.

Under 97 (NOT on my 2002) it also gives a "Do you want to save the changes" message upon closing even though the "DisplayAlerts" is set to false. I'm not sure why this is still coming up.

View 9 Replies View Related

Version 97 IF Formula Not Recognized In 2003

Nov 17, 2006

The following simple formula was written in Excel version 97. when I try to use it on a newer version (03) it does not seem to recognise it as a formula? =IF(F66="yes",1,IF(F66="N/A",1,0))

View 2 Replies View Related

Compare Version Number Strings

Dec 13, 2006

I have two numbers, they are version numbers, I am having problems with my If then else and elseif statements.

59821 for version 5.9.8.2.1
is more than
5983 for version 5.9.8.3

even though 5.9.8.3 is a greater version number. Do you see where my problem is. How do I compare # by # reading it, checking to see what one is bigger and going from there. so when it gets to the 3 of the 5983 its bigger than 2 of 5982 of the 5.9.8.2.1

View 2 Replies View Related

Compare Worksheet To Newer Version

Jul 1, 2008

during the executiuon of a macro, I would like to " record" the content of a given worksheet. Later on, I'd like to compare the recorded contents with what the worksheet presently looks like, and return True if the content of at least one cell has changed, False otherwise.

View 2 Replies View Related

Outlook Object Library In Different Version Of Office

May 5, 2014

Our office has different versions of Office on different computers. We have a file containing macros specifically macros that interact with Outlook requiring the Outlook Object Library. If a 2013 opens and saves the file all the libraries get changed to 15.0. Then a 2010 Office opens the file ... the Excel Objects and Office Objects libraries change to 14.0 because of 2010, but then we getting the error about missing library. Instead of loading the Outlook 14.0 Object Library like it's supposed to the systems tries to find the 15.0, but can't find it and throws the error.

I have to manually go in to References and uncheck the Missing 15.0 outlook library and find and check the 14.0 one and click ok then the macros work fine.

My question is why do the other object libraries automatically change depending on the version of office and the outlook one doesn't.

Interestingly enough this doesn't happen the other way e.g. 2010 to 2013. Ones the file is saved using the 2010 with the 14.0 references 2013 has no issues converting those references to 15.0.

View 2 Replies View Related

Requires To Distinguish Between Xl2007 And Previous Version

Jun 4, 2009

I know I have asked this question before and in that occasion for the safety copy creation I got a good solution, but now I have another issue which requires to distinguish between xl2007 and previous excels. Based on advice I have tried this:

View 3 Replies View Related

Macro To Check Version Before Saving File

Jul 21, 2009

The other day, I had posted a macro, which copies one of the sheets from a workbook, on to a blank sheet, and then saves it with a name obtained from the value of cell E7. I required certain modifications to it, before I could implement it.

You will find it here and the code looks like this:

View 10 Replies View Related

Version Coding Conflict XL 2007 Vs. 2003

Dec 3, 2009

With the kind help of this forum, I put together a nice business tool that has a fair amount of automation via macro buttons, etc. It works great in XL 2007 but some users are having issues in 2003. I appreciate this is quite general but are there significant conflicts / differences with coding in these two different versions?

View 6 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved