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
-
0
votes1
answer1201
viewsHow to return the data processing in Matrix passed as parameter for routines in VBA/Excel?
I need to pass separate matrices for a routine that sorts its elements and receive other treatments, and after that I want it to return those ordered and treated values to the original matrix; for…
-
0
votes1
answer184
viewsvba Pastespecial does not work
I’m cutting the values out of one spreadsheet and moving on to the other. The clipping is done without problems, the data is going to the clipboard, but I’m not able to paste. Code Private Sub…
-
0
votes2
answers1832
viewsHow to concatenate or use & commercial with date and text?
I am using the following code to present only the day and month. Range("AB2").Select ActiveCell.Value = "=Now()" ActiveCell.NumberFormat = "yy/mm" ultima_linha = Range("A" &…
-
0
votes1
answer63
viewsHow to convert multiple sheets . XLSL to . CSV of a book and export individually to the desktop?
I intend to store multiple sheets on the desktop by their name. And that they are converted from . xlsx to . csv (separated by comma).
-
0
votes1
answer62
viewsHow to convert Pounds to Euros VBA?
CONVERSION: The conversion will be in Pounds x 1.17 = Value in Euros. To add a percentage the formula will be Pounds x 1.17 x (1 + percentage). METHOD APPLIED: Replacement of the £200 column.50 to…
-
0
votes0
answers50
viewsLabel with transparent background
I’m making a program all in VBA, in Excel (office 2016), and suddenly some components fail to work properly. The main, and essential, change was that no field gets the transparent Backstyle (it used…
-
0
votes1
answer405
viewsDASHBOARD - Can you export to Browser?! (Any language to the web)
How do I import this DASHBOARD made in VBA in EXCEL, to run in browser? In HTML, CSS, Javascript, php... Whatever, I just want you to run it in the browser.…
-
0
votes1
answer117
viewsHow to copy the validation rules in vba?
If Range("L9") > (Range("I9") + Range("J9")) Then Range("B8:O8").Interior.Color = RGB(255, 0, 0) here i want to copy the validation rules if this happens End If…
vbaasked 7 years, 4 months ago Amadeu Antunes 3,331 -
0
votes0
answers214
viewsVBA integration with IE, return Value where Value=""
I have a problem in a macro to return me the value of a web page, my doubt is established by the value shown in the HTML code is always null, but in the reply box gives me the requested value. Even…
-
0
votes1
answer236
viewsHTML controls problems on a web page with VBA
I am trying to fill the controls on a web page with an interaction between VBA and IE, I am not able to find and popular the fields related to the date of validity of the minutes. URL Of Page:…
-
0
votes0
answers751
viewsExtracting two information via Selenium and pasting into only one cell in excel
I’m trying to extract some web information Via Selenium, the point I’m catching is this: I can direct the information from Selenium searched on the internet and save it within a specific cell, but…
-
0
votes1
answer190
viewsI am unable to go to the "main2" frame. VBA and Selleniumwrapper
I am trying to access a web page and manipulate its controls via VBA and Selennium Wrapper, however, these controls are within a frame with the "name = main2", follows the code VBA: Sub z() Dim…
-
0
votes1
answer288
viewsReset the counter every time you change line
I have the following problem: I have two counters within my code, but I want every time I change to the next line the countLinha1 (second counter) is zeroed and starts counting again, remembering…
-
0
votes1
answer1001
viewsHow to capture the td of a web page using Selenium vba?
html code looks like this: <table> <tr> <td width="01%" class="tex3b"><img height="14" src="/imagens/tm_bullet.gif" width="6"></td> <td width="20%"…
-
0
votes0
answers299
viewsError while trying to open an Excel file
I am trying to open a document in excel via vbScript. I am not succeeding in running, the following error is generated, without description: -2147417851 The problem occurs when executing the…
-
0
votes0
answers34
viewsError when selecting the second data/Listview information
I’m developing a applying and I am stuck in the following process. The application is called "INFORTGEI" and is for a computer store. When we run the application we can observe a form/main…
-
0
votes1
answer852
viewsSendkeys does not work with accented word in VBA - Excel
I’m developing a script in VBA, in Excel. This code will populate another program, using the data collected in the cells. But cells that contain some word that has accents, are not working. I am…
-
0
votes1
answer516
viewsAccess Site By Loggin
I am not able to access this site below because I can not locate by VBA a way to enter the Login and password. Would anyone know how to access these fields https://www.newspace.com.br/pan/ I tried…
-
0
votes2
answers1621
viewsPass values from one form to another
Expensive I have two A and B forms. A = Has listview and displays base information B = Need to receive form A information and display. (Information that is not displayed in form A) I need to make it…
-
0
votes1
answer333
viewsaccess menu with over effect. Selenium VBA
I am having problems accessing an "interactive menu" using the Selenium library in VBA. follows html code of the page: <html> <head> <meta http-equiv="Content-Type"…
-
0
votes2
answers2117
viewsHow do I change Image via VBA
Hello I would like to change an image in Power Point, I I don’t want to delete and insert another, but do what the command indicated in the image does. Would anyone know what to call this method???…
-
0
votes1
answer2583
viewsCollect HTML tag data with VBA
How can I get the return of an html tag through getElementById? I’m testing in the application below, but I’m not getting it. My intention is to catch what’s inside the tag. Sub teste() Dim IE As…
-
0
votes1
answer481
viewsFilling and importing data with VBA in excel, help in code?
Hello, the situation that I am trying to automate in excel, through VBA is the following: I have two spreadsheets (different excel files), where the two have the same header (with information like…
-
0
votes1
answer6913
viewsExcel VBA - How to use Vlookup with Letters and Numbers to Delete Queues?
Hello! I am going through great difficulty with a problem using Vlookup in Excel VBA. First of all, I am not an expert in VBA but I managed to use Vlookup but I am not having the effect I would…
-
0
votes0
answers28
viewsHow to Delete Queues with User Code?
A little while ago I did this question who has not received any answers: But I got some help from some people and I was able to evolve the code to a certain extent. My code is now like this: Option…
-
0
votes0
answers76
viewsDouble type number sum error - VBA/VB
look at the situation: I have a routine that does a sum of Price * Qty and stores in a variable to show the total. The sum is composed of 226 items. From 215 the partial result of the sum would be…
-
0
votes0
answers27
viewsTxt lp model to run in Gurobi
I created an optimization model through a macro, writing a txt lp template to run in Gurobi. However, when I run on Gurobi, the model appears as infeasible. Someone knows how to help me find the…
-
0
votes1
answer57
viewsProblems transferring data type from Msproject to Excel
Hello. I’m having trouble transferring some dates like Baseline Start, Baseline Finish, Actual Start, Actual Msproject Finish to a spreadsheet in excel. Here is the code snippet. Dim xlSheet As…
-
0
votes1
answer1649
viewsHow to count different names in a vba column?
Good people, I have a question in a work in vba in which, in a column, has four brands of cars: And you’re supposed to put on cell C15 the brand you want to look for and on cell D15 you have to show…
-
0
votes1
answer863
viewsVBA Print by Pdfcreator
I am trying to print an IE file by Pdfcreator, in my searches I could not locate a VBA form to perform this process, I even found an algorithm that says to do this, but I could not solve a problem…
-
0
votes0
answers1102
viewsImport sheet charts to userform (excel vba)
I have to import 3 charts for a userform. I had even managed, but suddenly started to give errors, then I put the code "On Error Resume Next" (but this is not solution, just does not lock my form…
-
0
votes1
answer604
viewsConcatenate Userform text and insert as link in a cell
I’m trying to feed a table with 3 information inserted from the execution of a Userform and, at the end, make a direct hyperlink in the cell with the information inserted. The information is as…
-
0
votes1
answer136
viewsRename a variable and update it in the rest of the project
Have some easy or automatic way to update the rest of your code when renaming a particular variable on the line Dim? What do I have: Dim ABC As String If Range("A2").Value = 1 Then ABC = Range("C2")…
-
0
votes1
answer483
viewsDoes not locate element with findElementById
Expensive, I am trying to fill two text fields (login and password) of a given page. Using the following code. (Both by byID, bySelector, neither works) driver.findElementByName("usuario").SendKeys…
-
0
votes3
answers1426
viewsFind element without tag ID and Name
Expensive, I need to locate the element that does not contain id and name in HTML. Below is the HTML example <button type="button" class="btn btn-primary ng-scope" data-ng-if="novo2()"…
-
0
votes1
answer233
viewsSelect
Expensive, I am trying to select an option in a select with the following code and am unable to find a solution. I can locate the element, but not tell it to select X option. I’m tracing with the…
-
0
votes2
answers2427
viewsSQL Query VBA Excel
Good afternoon! I have a problem with a query in Access via form. The Form is from Excel vba, which connects to the database. Below is the complete code. This is the code of the button. Clicking…
-
0
votes1
answer3999
viewshow do VBA interact with more than one tab in Internet Explorer?
I have a macro in VBA that handles Internet Explorer, at certain point when clicking an item, a new tab opens in Internet Explorer. My doubt is: how to change the focus of VBA to manipulate this new…
-
0
votes1
answer1630
viewsVba + Google Chrome
I have been having doubts for some time and even after several researches I did not succeed. I am creating a function in VBA capable of handling a web page using Google Chrome. Although I set Chrome…
-
0
votes1
answer1517
viewsHow to insert photos from a folder into a cell in Excel automatically?
I need to insert several images in Excel, however it is difficult to insert one by one, are more than 300 photos, and there will be updates of these photos. I was wondering if there’s a way to…
-
0
votes1
answer89
viewsAdd code to the Workbook using a macro
I have a code that records who prints the document, but I have a thousand documents and I have to enter the code, I already have the code to put modules, but I need one to put in the workbook to…
-
0
votes1
answer62
viewsError in Datagridview search
Hello, I have a Textbox in which entered a name automatically does the search in a Datagridview with employee data, for example if I type the letter "a" will appear all names starting with the…
-
0
votes1
answer109
viewsAccess - Update in table without using VBA module
I need to update a table once a month, in which the entered data should be placed in the respective current month. I have been doing this via VBA code, however, as the table has approximately 30…
-
0
votes1
answer143
viewsIs there something wrong with that code?
Function Check() Dim valorA, valorB, valorG, valor2 As String Dim rng As Range valorG = Cells(ActiveCell.Row, "G").Value valor2 = Cells("2", ActiveCell.Column).Value For Each rng In Range("A3:A321")…
-
0
votes0
answers174
viewsEXCEL: Form filled in specific places
In this image I have 7 "blocks" to be filled via form, they are side by side. As I do in vba a function that fills these blank fields of TM1 and TM2 automatically, I want to include this function in…
-
0
votes1
answer115
viewsTranspose data in an automatic way
I have the following problem, I need to create a "robot" that reads the data of a given cell in Excel and enter this data in another software (own software of the company in which I work), but it…
-
0
votes1
answer1976
viewsUse of Transferspreadsheet via VBA
I’m finishing my improvement project and there’s something that intrigues me a lot. I needed to make a report based on the result of an SQL query, which I even questioned in Export SQL query data to…
-
0
votes1
answer73
viewsVBA / Macro - Cleaning Data
Hello, I’m here cracking my head on how to modify a spreadsheet through a macro. Can anyone please help me? I have a spreadsheet (Plan1) that has A1:AF720 formatting. I need to create a macro so…
-
0
votes1
answer3790
viewsCheck if a Listbox item has been selected
I have a list ListBox1 q a check box ChckBox1 in a Userform. I want to activate or inactivate the checkbox (CheckBox1.Enabled = True/False if an item in the list is selected. The check-box is…
-
0
votes3
answers1130
viewsTake the selected value in a cell and subtract with the combobox value in vba
Good afternoon, I have the selected cell and now I want to take the value of that selected cell and subtract it from the combobox value and then take that result and put it into the selected cell.…