vba

VBA/excel to dll/exe for Java

Hi, I have an excel file with mannually input functions, which use an add-in from a third party. I want to use functionalities of the excel file in Java. I could think of two ways of doing it. code the functions in VBA, or VB with excel reference, then generate .dll or .exe files for Java to use. Feed data to excel file using jxl (wou...

Get Timezone Information in VBA (Excel)

Hi I would like to determine a time offset to GMT/UTC (including daylight saving time) for different countries at a specific date in VBA. Any ideas? Thanks ...

Is sharepoint versioning stored inside the document for excel documents?

Does anyone know if SharePoint stores it's version numbers inside the files for Excel files? I would assume that it does not. This is what I need: I have an Excel file stored in a SharePoint document library. The file will eventually be distributed and must be able to function offline. The file is somewhat macro-intense, and I would...

Print a range of hyperlinks

How can I get this to print the hyperlinks files found in columns "D:E" by selecting the rows in column "A" Sub Print_Hyperlinks() Dim rng As Range Dim row As Range Dim cell As Range Dim LastRow As Long LastRow = Range("A2").End(xlDown) 'Print only selected rows in "A" Set rng = Range("D2:E" & Last...

Where is Actionsettings in TextRange2 ?

I need to extract Hyperlinks from text Runs in PowerPoint 2007. I know I could do so using: TextFrame.TextRange.ActionSettings[PpMouseActivation.ppMouseClick].Hyperlink However, my code, which is quite a large one, uses TextFrame2 and its corresponding TextRange2, and I could not find ActionSettings in TextRange2. Anyone knows where i...

VBA code to create a report in MS Access

Can anyone help me create a code satatement that will allow me to create a report with the sQ statement below? The problem I'm having is that my form allows you to input a Cost center, but when I click on the command button to execute the code it asks me to input the cost center again before it shows me the report. I want to eliminate ha...

I'm getting an Error "runtime error 2105 access you can't go to the specified record"? please help me

Private Sub cmd_New_Click() Dim Response% If Me.Dirty Then Response = MsgBox("Save changes to the job record?", vbYesNoCancel, scAppTitle) Select Case Response Case vbYes SendKeys "+{Enter}" Case vbNo Me.Undo Case vbCancel Exit Sub End Select ...

compare excel and access to update data

Hi All, I am using Remou trick shown here... to compare excel data with access table to update changes. Is there a way to have excel to update any new data found using the same batch technique. Also can I incorporate it in the below mentioned code in any way. Sub UpdateMDB() Dim cn As Object Dim rs As Object strFile = Workbooks(1).F...

vba collection maximum size

here's my code: Sub isdofsodjisf48023jroi23f984444444jiodfiosj12348023jroi23f98() Dim colFiles As New Collection RecursiveDir colFiles, "C:\Documents and Settings\Alex Gordon\Desktop\testing\files\", "*.xls", True Dim vFile As Variant For Each vFile In colFiles Call writeincells(vFile) Next vFile End Sub P...

MS Access 2003/2007 - Subform as control panel, closing parent form with global like reference??

I am sorry if the title is wrong, but I think that is what I mean to ask. So I have a subform created that I would like to use, sort of like a control panel, that allows user to select a range of different forms. So the same subform ends up in a lot of different parent forms. I would like to use simple docmd.close acform but i am lo...

MS Word - Work with two VBEs at once

I've just taken over maintenance of some pretty scary legacy vba at work. When I have spare time I'm essentially restructuring and rewriting it in new templates. Every now and then, I've managed to exploit a glitch of sorts and have two different instances of the VBE open at once. I don't know exactly what I did to make this happen, but ...

Profiling / debugging API for VBA?

I am currently involved in porting a large and complicated VBA application to .NET 4.0. In .NET I have access to the Profiling API, which I have used to instrument an assembly to extract information about when classes are constructed, methods called, etc. Is there an equivalent for VBA? That is, some sort of callback system so I can...

How to find words in a memo field with microsoft access

Hi This is more complex than I thought as I need to do it with VBA. So here is my problem:- I have two tables in an MS Access DB, content and adjectives. The content table has over 5,000 text snippet rows in a memo field (content) and a blank text field (adjective). The adjectives table has 120 adjectives with the field (adjective)....

list of VBA OOP Concepts

Hi All, I am building some material for OOP (object oriented programming) in VBA, so can anybody list me the OOP concepts which are available in VBA? for example from my reading I discovered that: inheritance is not available in VBA !!! encapsulation concept is there as you can use access modifier "private" and build a public propert...

MSXML XHTML and embedded CSS

I have an Excel workbook that is used as a starting point to generate a user-fillable form in our internal system. As an aide to the users creating these workbook, I'm trying to add a preview function, that takes that spreadsheet, does some VBA magic to generate an HTML file, and then display that in their browser. I have the basic stru...

working with HUGE spreadsheet

i have about 300,000 records in this spreadsheet. and there are a couple hundred columns!! one of the columns is the social security number and i need to replace it with some random identifier. i cant really do a vlookup because that is too taxing so i think i am going to write a macro can anyone please suggest to me how do i do this? ...

Macro in Delmia

Hi , I am programming some VBA macros in Delmia with interface to make easier the life of the user. I know, in Delmia, there is the option to "Start Recording" macro, then I can make some operation in delmia and see the code generated by these operations. But when I click, by example, on "Restore initial state". There is no code genera...

running regsvr using VBA

Hi guys Is there a way I can run regsvr32.exe to register a dll using VBA? My software is in access (dont blame me, blame the company). Access for some reason always references the old version of the DAO library. After about 2 hours of searching the internet, someone suggested registering the library, and viola it worked. It cut down ...

Set textbox text to Today/Tomorrow/Next Day/etc. automatically?

I'm new to programming in VBA, but what I'm trying to do right now is have a PowerPoint slide that updates every day. It's a weather forecast slide that is displayed in our lobby, and currently I manually update the seven day forecast each day I come in. This means that until I come in, it shows the current day as yesterday's date, and t...

Invalid Argument Error: MSAccess and SQL

I am trying to access certain lines from my SQL database from MSAccess and I keep getting an Invalid Argument Error on this line: Set rs = CurrentDb.OpenRecordset("SELECT TimeID " & _ "FROM tblLunchTime " & _ "WHERE ProductionID = prodSelect AND EndTime is NULL AND StartTime < dateAdd('h', 3, NOW())", [dbSeeChanges]) Is someth...