vba

ACCESS 2007 - how can I open select window dialog from VBA

Hi all, I just converted ACCESS 2000 to ACCESS 2007 application. How do I access to the switch windows - "select window" dialog, how can I open this dialog from VBA Thanks ...

Accessing an Access DB from Outlook via VBA

Hi The situation: In Outlook I get a message from a server. The content of the message needs to be put into an Access db. But, there may not exist another message with the same date. So, I need to look into a db if there is already a message with the same date and time. If there exists one, then it needs to be replaced and otherwise th...

excel vba adding programatically commandbutton to userform

hi, in excel vba i have added a commandbutton to userform... like below Set ctrl = Me.Controls.Add( _ bstrProgID:="Forms.CommandButton.1", _ Name:="CommandButton1", Visible:=True) Now I wanted to know how would I tell it what to do when it is clicked? thanks!! ...

What is the proper way to handle module level arrays in a VBA class?

What is the proper way to handle a module level array in a VBA class? I use Property Let and Property Get for other variables, but I haven't figured out how to pass arrays to and from Properties. Updated. This code works thanks to Mark Nold. Option Explicit Private mstrTestArray() As String Public Property Get TestArray() As String(...

Excel: filtering a time series graph

I have data that looks like the following: ID | Location | Attendees | StartDate | EndDate --------------------------------------------- Event1 | Bldg 1 | 10 | June 1 | June 5 Event2 | Bldg 2 | 15 | June 3 | June 6 Event3 | Bldg 1 | 5 | June 3 | June 10 I'd like to create a time series grap...

Powerpoint VBA - Distribute columns evenly

I am using PowerPoint 2000 which does not have the distribute columns evenly function that 2003 and newer has. Does anyone know what VBA code would be used to distribute selected table columns evenly? (I know how to do it for the WHOLE table by finding the table width, dividing it by the number of columns, and adjusting each column's wi...

excel: mid: can't find project or library

for some reason in my VBA code in excel, when it gets to a line of code where i am using mid it says can't find project or library. what does this mean? ...

How can I programatically (VBA) copy an excel slide to a Word document

Goal: Step 1. Use a PowerPoint presentation during a seminar that allows the presenter to click on text fields and fill in information while still in "slideshow" view. Step 2. Copy (in any way) the entered information to a word document. Currently one the slide in question I have a table in powerpoint with msotextboxes overlayed over ...

vba, excel - detecting with xls files have a macro in them?

does anyone know a programmatic way to determine whether an excel file has a macro with it? i have hundreds of excel files and i need to know which files have macros in them? ...

excel: object variable or with block variable not set

Dim cht As Chart Dim Xleft As Double, Ytop As Double Xleft = cht.PlotArea.InsideLeft i am getting this error on the third line. does anyone know why? here is the full code. please keep in mind that this is excel 2003 Sub DrawSmoothTransparentShapesOnRadarChart() Dim cht As Chart Set cht = Worksheets(1).ChartObjects(1) ...

excel 2003, putting a button or textbox on worksheet?

does anyone know how to place buttons or textboxes on worksheet with vba or manually? ...

what is the purpose of OFFSET in excel?

In Excel, the Offset function returns a reference to a range that is offset a number of rows and columns from another range or cell. can someone please tell me what that means? for example in this formula: =OFFSET($B$4,ROW()-ROW($F$4),0,1,1) what is it doing? ...

feeding data labels into excel with VBA

i have a scatter plot graph i would like each dot to have a label. how do i feed in labels through VBA for each dot? ...

Iterating quickly through Outlook appointment items

I've written a macro which iterates through a users calendar and makes modifications to entries that fufil a certain critera. The problem is that when the calendar is very big, this takes a long time to do. I don't seem to be able to filter the appointments because oAppointmentItems seems to store entries as they were created - which is...

Question about replicating Word form fields in a table

I have a project in development that uses Word documents as an input mechanism to a larger system. My company's client has 4 different Word documents they use that contain form fields. When the document is submitted to our system, it will strip the data from the form fields and store it in a SQL Server database. I realize this isn't t...

Who am I? How to use Microsoft Office Permission/UserPermission

Microsoft Office documents, im my case: PowerPoint presentations, can have restricted permissions. How can I find out, programmatically, which permissions my code has on a given document? All I can find on MSDN on this topic is this: http://msdn.microsoft.com/en-us/library/aa432118.aspx If I run the following code, I get a list of user...

How to requery a subform from another form?

I've struggling with this problem on my own, then with some help, then search about it; but I haven't had any luck. So I decided to ask. I have two forms in Access 2007 lets call them MainForm and EntryForm. MainForm has a subform and a button. The button opens the EntryForm in Add Mode. What I want to do is when the EntryForm saves the...

Refresh Pivot Table With XML From ServerXMLHTTP Response

I have succesfully made an Ajax like request to a web service using Microsoft Excel. My goal is to have a button that the user can click to pull down the information and refresh the pivot tables and charts in the excel document to reflect the udpated information. Can I set the Pivot Table to have an XML as it's source? If not, what a...

Merge and Left Justify a Range of Rows in Excel

I have a macro to select a range of cells on the same row and then merge & left justify that selection. I would like to enhance it to allow me to select a range or block of rows and perform the same action on each row in the range. Does anyone have some sample code to do something like that? Thanks! Craig ...

what is MDO with VBA?

i do lots of vba with excel. what is mdo? if i want to do vba with mdo what does that mean? ...