Questions tagged [vba6]

Visual Basic for Applications (VBA) is an event-driven, object-oriented programming language for writing macros, used for the MS Office suite as well as other applications. VBA is not equivalent to VBA6, VBA7, VB.NET, or VBS. If your question is specifically about programming any MS Office application, also use the appropriate tag: [excel], [ms-access], [ms-word], [outlook], [powerpoint] or [ms-project].

Visual Basic for Applications (VBA) is an event-driven programming language which was first introduced by Microsoft in 1993 to give Excel 5.0 a more robust object-oriented language for writing macros and automating the use of Excel. The language and its runtime quickly matured and began being used in products beyond Microsoft Office applications.

Differences between VBA 6.0 and VBA 7.0?

There's not a whole lot that has changed between VBA6 and VBA7. VBA7 was introduced to support 64-bit versions of both Office and Windows while VBA6 only supports the 32-bit versions of Office.

Reference

Differences between VBA 6.0 and VBA 7.0

139 questions
0
votes
0 answers

How to loop the array in the same time in VBA

My problem is after the the j in the loop is done, the i will just move. I want to the run the 2 loop array at the same time. ReDim ArrayItems(Download_frm.ListBox1.ListCount) ReDim ArrayItems1(Download_frm.accountb.ListCount) For i = 1 To…
His Lombres
  • 13
  • 1
  • 7
0
votes
2 answers

Google translate cell value using VBA

I'm trying to convert other languages to English using auto detect by triggering the below code. Sub transalte_using_vba() Dim ie As Object, i As Long Dim inputstring As String, outputstring As String, text_to_convert As String, result_data As…
Linga
  • 945
  • 1
  • 14
  • 31
0
votes
2 answers

Scripting.Dictionary to fill a column with a string taking in consideration more then 3 criteria

I am trying to fill a column C with the string consider if the consumer on the row matches one of the criteria: If the consumer meets one of these rules, the value should be set to Consider: • Consumer has only 1 Transaction -- (is done) • Consumer…
Fah
  • 207
  • 3
  • 16
0
votes
2 answers

VBa post request from Curl

id have problem with converting the Curl to VBa code what ever i tried the respons is error ,but with postman program i can reach the datat the Curl code is curl 'http://yatirimisletmeleruygulama.kultur.gov.tr/Acente.Web.Sorgu/Sorgu/AcenteBilgi' \…
seyf
  • 3
  • 1
0
votes
1 answer

how to set values between worksheets after IF statement using 2 last rows

I am trying to copy and paste the entire entire columns values from sheet named Hey, to another columns in a sheet named final. I dont want to use copy, paste or select option.However, my code is copying only the 1st line. IntLastRow =…
Fah
  • 207
  • 3
  • 16
0
votes
2 answers

How to end the loop is the variable is empty

Sub max() Sheets(1).Select Sheets(1).Name = "Sheet1" Dim rng As Range Dim celladdress As String Dim celling As Variant Do Until IsEmpty(celling) If celling > "G4" Then Set rng = Range("G3:G1000").Find(what:="Description") …
0
votes
1 answer

Progress bar using VBA

I'm working on excel sheet using VBA: I'm trying to test a progress bar. I already completed the design, as shown below: Below the userForm code: 'PLACE IN YOUR USERFORM CODE Private Sub UserForm_Initialize() #If IsMac = False Then 'hide the…
lagna
  • 3
  • 1
  • 5
0
votes
2 answers

What better for memory usage: define constants in subs or in module

I understand that is some of VB basics, but can't figure out how to ask google: How VBA manage constants? In some languages compiler replace them by values. But how that works in VBA? Will it matter if i declare them in sub/function, not in global…
XoR
  • 3
  • 2
0
votes
2 answers

Sorting filenames by conditions

I want to create a bit of code that saves a file out to a folder (PDF / DWG ) and moves all my files with a lower revision #5 than the current file being saved into a superseded folder. I cannot see how to set a condition for the revision number: I…
Knotwood V
  • 51
  • 1
  • 6
-1
votes
1 answer

Excel VBA : pull picture from web (multiple rows)

I'm new to VBA. I have an Excel file where in column A there is product number (ie 12345, 12346 etc); I want the attached picture from the web as the comment in the specific cell with item number. Picture on the web is on…
Pawel
  • 1
-1
votes
2 answers

VBA Word find text with a special style in heading level/chapter

In the whole doc are data that I need to write in a predefined excel per chapter (headings level 1 - 4) there are findings (text with bulleted style) so if there is a finding in this chapter i have to look how many times so i can write it in excel…
-1
votes
1 answer

Excel Macro to change page number mentioned in javascript:__doPostBack when called by IE.Navigate

I wrote excel macro to fetch data from multiple pages ( here around 25-40 pages ) . I have managed to change pages and scrape all pages from every page . Sub Fetch_Data() Dim IE As Object Dim httpReq As Object Dim HTMLdoc As Object Dim…
New_Coder
  • 13
  • 3
-1
votes
2 answers

Error Catch if DoCmd.SendObject is terminated prematurely

I have a email (SendObject) routine in MSAccess VBA. The code crashes if the user decides not to commit to hit the send button, and simply closes the email form. Private Sub ButtonSupportEmail_Click() Dim varName As Variant Dim varCC As Variant Dim…
NanoNet
  • 218
  • 3
  • 11
-1
votes
1 answer

Which function can i use in vba similar to the one i used in sql

i have tis code in sql and it works but which function can i use in vba to archive the same result. RIGHT('00' + MONTH(lt.LveFromDate),2) --2021-03 --2021-03 --YEAR(lt.LveFromDate)
james
  • 31
  • 6
-1
votes
1 answer

Troubled with VBA version difference: version 6 and version 7

I'm new to VBA and use excel 2010 64bit VBA v6.0 compatible. I pasted the code, trying to download files through VBA. Option Explicit 'Tutorial link: https://youtu.be/H4-w6ULc_qs #If VBA7 Then Private Declare Function URLDownloadToFile Lib…
1 2 3
9
10