Most voted "vba" questions
Visual Basic for Applications (VBA) is an event-oriented programming language with limited object support, used to write macros, available for the entire Office suite.
Learn more…792 questions
Sort by count of
-
4
votes1
answer866
viewsAutomatic Logon in SAP Bexanalyzer by Vbaproject
(UPDATED) In excel I have a supplement that gives access to the BI system, to access / stratify data in a query already specified / structured. In my Vbaproject I am referencing the Add-in to call…
-
4
votes1
answer229
viewsCheck the number of copies that have been printed
Hello, I have a table that when printed generates a record in a txt telling the user who printed, on which machine, on which printer, which document was and when. But I would also like to register…
-
4
votes1
answer81
viewsExcel tabs that were saved in html: how to take up
I made a spreadsheet in excel with several tabs and then saved in html because I want to use in my site. The spreadsheet tabs are at the bottom, the site user would have to scroll down to change the…
-
4
votes1
answer2800
viewsMacro to automatically search images and play in excel
Good afternoon, I have a spreadsheet, where I need to automatically include images. I wonder if there is any way to elaborate a macro, where you join the Reference and color (reference & color)…
-
4
votes1
answer125
viewsHTTP request within a company that uses proxy
I’m sorry if that question is repeated. I always try to get the answer before asking here, and this time I didn’t (I suddenly didn’t use the right keywords, perhaps for lack of knowledge, but…
-
4
votes2
answers372
viewsHow to show 2 rows in Listbox
It’s a simple question, but I did some research, and I couldn’t find anything specific to my case. The code below corresponds to searching for data in a table, but when there is more than 1…
-
4
votes1
answer608
viewsVBA - Automatically Clear Cell Information - Event Change
The script below causes when selecting the column "H11" automatically clear the column "I11". How do I make the same script erase the I12 cell when selecting the H12 cell and so following the same…
-
3
votes1
answer7604
viewsExcel 2007 - Buttons to Create / Remove Rows
I have an excel table with only one row (plus the header) and six columns. The entire sheet is protected except this line. At the end of the table I wanted to have a button (+) that adds a new row,…
-
3
votes1
answer11000
viewsUse the R1C1 property
I want to use the property Range.Formula R1C1 in a check copy form for automatic filling of cheque nominal. How could I use this property for this purpose? I found a code described as follows: Sub…
-
3
votes4
answers11775
viewsDynamically set the Excel column size
I am working with the generation of spreadsheets in EXCEL, and for this I use the framework’s default api. Imports Microsoft.Office.Interop.Excel However, when I have a column with very long text,…
-
3
votes4
answers15143
viewsHow to create an Excel macro to delete duplicate lines
Have someone show an example of Macro in Excel that removes duplicate lines, but comparing all cells of the same, or selecting which compare, example para linha_atual em todas_as_linhas faça para…
-
3
votes1
answer7292
viewsGenerate random number when activating spreadsheet in Excel
I am here because I believe that only with the help of VBA I will achieve what I want to do, which is the following: I am developing a small game in Excel and I have to use random numbers, it…
-
3
votes2
answers8784
viewsVBA Set ie = Createobject("Internetexplorer.Application")
Next, I’m picking up from VBA to browse a web page (can be with Internet Explorer) Basically I found some codes with the Method CreateObject("InternetExplorer.Application"). However, I cannot input…
-
3
votes1
answer1041
viewsSplit a string
I’m trying to make a simple code using the split, but some mistakes are occurring that I’m not able to solve.. no if with asterisk VBA informs me that the subscript this out of range.. Sub…
-
3
votes2
answers357
viewsRestart Numbered VBA Excel Word List
I am trying to create a macro in VBA to create a word document from Excel. Right now I’m having trouble with the lists. I want the list numbering to be linked to my Header1 and Header2 Styles so…
-
3
votes1
answer337
viewsForce numeric/language format to document
Where work is very common we have problems with excel macros, which generate tables and charts, depending on the language and version of Excel the client is using. How to force a language (for…
-
3
votes1
answer795
viewsIs it possible to rename a folder with files inside using VBA (Outlook)?
I have a simple process where a text file arrives by email and I must save it at a certain location within a folder whose name is a date that is within this file. With this in mind I developed the…
-
3
votes1
answer633
views -
3
votes2
answers1138
viewsHow to delete line with information after a blank line in the middle?
I’m running a macro to import txt data. But this macro is bringing the information down after a white line (9 Rows(s) affected) The data information is correct, but it has this line that I need the…
-
3
votes3
answers1827
viewsExcel - Extract only numeric fields from a selection containing text and numbers
Using Excel, I need to extract numerical data from a selection. Example: Coluna 1 123 456 Bom Ruim 789 Ótimo From the above data, I need to extract the following data: Coluna 2 123 456 789…
-
3
votes2
answers5064
viewsHow to use the name of a cell of the Excel spreadsheet in VBA, not to indicate row and column?
How to use the name of a cell of the Excel spreadsheet in VBA, not to indicate row and column? For example, I named "Client Name" to cell B20, when I use this name in VBA to put in label (…
-
3
votes1
answer324
viewsHide results in Excel
Good afternoon, guys. I have the following problem: I have several lines and each one of them is protected with a different password for the edition, each corresponding to a company unit. I need the…
-
3
votes2
answers1938
viewsauto filter Vba
I am developing a macro to perform filters using VBA, however in some columns, I have to uncheck some values, for example: Column Paul Fernanda Carla Láis Renata I want everything that is different…
vbaasked 9 years, 4 months ago Paulo Henrique Gallo 105 -
3
votes2
answers2498
viewsHow to do a google search with vba?
I’m having difficulty setting up a VBA programming that does a google search. I can’t understand the HTML part. The idea is to identify the open internet explorer, go to the google page and search…
-
3
votes0
answers380
views -
3
votes1
answer1667
viewsHow to delete "Code execution stopped." message in VBA
When I am running a VBA macro, eventually the code is stopped, as if there were breakpoints. The message displayed is: Execution of code interrupted. If you accept the message and continue executing…
vbaasked 8 years, 7 months ago Ricardo Madela 41 -
3
votes1
answer1216
viewsSeparate Even, Odd and Equal values in Matrix by VBA (Excel)
how to make a 10x10 matrix, separate pairs and odd and equal without using Mod ?…
-
3
votes4
answers12456
viewsVBA - How to split a word direct mail into multiple files . pdf
Personally, my case is as follows: I participate in the organization of some events in the area of IT and free software and the printing of certificates is always a problem. In the last event I…
-
3
votes1
answer1405
viewsRunning text as code in VBA
The code below calculates the formula contained in the variable Text (String): Private Sub CalculeFormulaNoTexto() Dim Texto As String Texto = "= 90 / 3 + 7 + COS(0) + 1/7" ' A variável Texto recebe…
-
3
votes2
answers3784
viewsWhat is the difference between a VBA project and a VBA macro?
was studying macros VBA and came to me the following doubt: What is the difference between a VBA project and a VBA macro? Are the two the same or have some significant difference between them?…
vbaasked 7 years, 11 months ago Daniel Aristofanes 73 -
3
votes2
answers1433
viewsExcel move un-duplicated values between two columns to a third
I’m having a doubt and I can’t get a plausible answer. I have a spreadsheet in which I would like to make a comparison between two columns and say to it that if there is a value that is not…
-
3
votes1
answer451
viewsHow to delete/delete repeat lines by comparing different cells?
I want to know how to delete a row that is repeat along my table. The image below can help Possible solutions: 1. Browse with Macro from file Excel1 this pass the dice to the file Excel2. Prevent it…
-
3
votes1
answer69
viewsCopy record within the same table by changing some fields
I am trying to copy a record from the table to a new record changing some fields, but still this with error and can not locate, it is possible to see where I made the mistake, follows below the…
vbaasked 8 years, 8 months ago Maurobertos 31 -
3
votes1
answer2178
viewsQuestions about executable program generation in VBA/Excel
I compiled a VBA program that interacts with an Excel spreadsheet. After having no more faults pointed out when compiling, the compilation is executed and no action is presented at the end. I did…
-
3
votes1
answer1348
viewsAuto run macros in Excel/VBA
I made several attempts to execute a macro when starting Excel as indicated in the searches I did, although these indications are very simple, in my case did not work. I followed the following…
-
3
votes1
answer950
viewsErrors in using the Application.VBE object inside the VBA
In support of the solution of the question "How to inherit a VBA form?", executed the guidelines and examples of the site support.microsoft.com/en-us/kb/204330 for the purpose of dynamically…
-
3
votes1
answer1312
viewsSelect an option that is only possible through mouse click with vba
I’m trying to develop a script with vba, no excel, to facilitate a routine we have at work, which inserts about 9,000 data into the internal system. Currently we manually enter this data. This data…
-
3
votes1
answer100
viewsfmBackStyleTransparent does not work in Excel VBA
I have a problem in VBA of Excel, and why I searched other users as well and are unanswered so far, as in this link. Property Backstyle = fmBackStyleTransparent does not work It turns out that the…
-
3
votes1
answer328
viewsCheck module name via VBA
Hello, I need to check the name of a module to change it later. The name of the module changes a lot, depending on each document,and not to run all possible names, because it would take too long.…
vbaasked 7 years, 5 months ago Leandro Felipe Moreira 423 -
3
votes1
answer7859
viewsIncrease list source in Data Validation
Hello, I have a field of my spreadsheet that has a list by data validation, I would like to know how to increase this source, leaving it more visible. NOTE: Without the zoom scheme. That is the…
-
3
votes1
answer5785
viewsHow to change a cell from "General" to "Number" and add a comma?
I am learning VBA and I had a difficulty to transform a column that has values formatted as "General" for number, besides, I need these values to be expressed with comma. Current values (sample): I…
-
3
votes1
answer100
viewsExcel cannot read cell in VB code
x.Range("A1:z1").Select x.Goto Reference:="R2C4" verificaCel = x.ActiveCell.FormulaR1C1 if verificacel then I am not able to read the specific cell in the excel spreadsheet, in which I will send the…
-
3
votes1
answer4263
viewsHow to copy and paste as image with VBA?
I need to copy a chart and paste it as an image in the same spreadsheet. I’m trying to select the range that contemplates all the graphic and paste special as file Bitmap or Enchanced. Follows code:…
-
3
votes1
answer1262
viewsInsert comment via Function
How to insert a comment with the text of a cell through a Function?
-
3
votes2
answers2124
viewsTake values from an excel spreadsheet and display in a pop-up
I’m developing a spreadsheet and I’m having a hard time starting to work with the macros/vba. However I could not find a tutorial that showed me how to do what I need. I have a table that says: nome…
-
3
votes2
answers1241
viewsHow to create a macro that enters the site and takes the data from the last day?
Good afternoon, need to access a website and grab the data from the last day and copy them to a folder in excel, the site is highlighted in the macro below, but I don’t know how to proceed to select…
-
3
votes2
answers1389
viewsOptimization in VBA code?
I have two spreadsheets, both have the same header, with 77 columns. For testing I put 4 rows with data filled in one of the tables. In the table with the data filled, I have the button with the…
-
3
votes1
answer8865
viewsFind last filled cell in a range
It is possible to find the last filled cell in a range and paste a value into the next empty line below? I need a code to search the range ("B5:B35"). I used the following code, but after cell 35 I…
-
3
votes3
answers13786
viewsVBA: Use Excel to rename files in a folder
I’m thinking of using Visual Basic from Excel to standardize the name of 6000 files in a given folder. These files are mixed between photos and documents, so there are a variety of extensions (DOC,…
-
3
votes1
answer205
viewsDoubt Search VBA Record
I have a problem with my application, follow: In my excel I have a sheet called parameters, on it I have two columns, where column A is the parameter name and column B is the parameter value. I…