Excel – Auto increment ID row column cell on insert
Can this scenario be achieved in Excel so I get automatic ID column increment every time new row is inserted? (no matter in which place – at the beginning, in the middle or at the end of sheet):
Excel, while loop with variable loops
Good evening all,
Compare a number array with existing records in Excel or VBA
I have a sheet with 3k+ lines and 15 columns. Each column is filled with a random number from 1 to 25. Very much like lottery results, where each column is a number drawn from the lottery. (from 1-25)
Sum Bottom of Colum(s) with Dynamic Formula
I am working on a vba code that places the sum of a column (F) dynamically at the bottom. I would like this formula to loop through the remaining columns in the worksheet up to column AM (E.g. Columns G,H,I etc.) How do you suppose I do this?
See my code below:
Sub SumColumns()
Dim LastRows As Long
How To Count Unique Data In Long Range Row
I have data with a row length of around 20,005 and want to count the number of unique data in that row.
Copy automatically data from sheets to another
I would like to know how to transpose automatically (if vba, no button) the data of 10 identic tables (B5:E100) in the same excel file into one central table on the last sheet (Sheet 11), without taking into account the empty lines.
Macro efficiency vs. Progress Bar
I have 2 macros where the first macro asks how many rows I wish to insert which then calls my second macro below. This setup works great, however, if I wish to add 100 rows it takes some time to complete and gives the user an impression that excel is broken.
I have complex formula in excel and don’t know how to sort it out. Can you assist me to fix my below formula?
Here is the time range
Start Time End Time
Row L6 9:00:00 Row M6 09:57:15
Row L7 9:57:15 Row M7 10:21:07
Row L8 10:21:07 Row M8 14:48:19
Row L9 14:48:19 Row M9 19:00:00
Row L10 9:00:00 Row M10 13:27:12
Row L11 13:27:12 Row M11 17:37:02
Row L12 17:37:02 Row M12 19:00:00
Row L13 9:00:00 Row M13 09:34:19
Here is the solution that I want
START DATE WİTH TİME END DATE WİTH TİME
Row N6 20.06.2024 9:00:00 Row O6 20.06.2024 09:57:15
Row N7 20.06.2024 9:57:15 Row O7 20.06.2024 10:21:07
Row N8 20.06.2024 10:21:07 Row O8 20.06.2024 14:48:19
Row N9 20.06.2024 14:48:19 Row O9 20.06.2024 19:00:00
Row N10 21.06.2024 9:00:00 Row O10 21.06.2024 13:27:12
Row N11 21.06.2024 13:27:12 Row O11 21.06.2024 17:37:02
Row N12 21.06.2024 17:37:02 Row O12 21.06.2024 19:00:00
Row N13 24.06.2024 9:00:00 Row O13 24.06.2024 09:34:19
Start Date is located in cell H5 and has only Date and No Time.
When the time is 19:00:00 in the “End Time” range, you should increment the day by 1 day for the next row day and start from 09:00:00 as mentioned in the Start Time
Saturday and Sunday is weekend. If both dates fall to weekend you should skip 2 days and start always from Monday.
The range to find weekends is
Row T2:AR2 for the weekday name
Row T3:AR3 for the weekday date
The weekend is called “HS” and Holiday is “TT”
How to set NumberFormat via a VBA function?
I’m trying to set the data type for data in a cell (in the case of the function I wrote for the cell calling the function). Below is my code and it does not work but I’ve seen that for example setting NumberFormat
via a macro (so a sub, not a function does work although in that case I hardcoded the cell address in the macro). I use a sub to try set the number format exactly because I saw this work via a macro. I would expect to see the double returned by the function display with only two decimals but number format for the caller cell remains unchanged and set to “general”.
Excel for M365: calling the StockHistory function in VBA code makes the XLSM unable to be saved
I was testing calling the StockHistory
function from VBA (available only in Microsoft 365 versions of Excel) and I noticed that afterwards Excel started complaining about the workbook being corrupted and completely failed at being able to save the workbook once more. I initially thought the issue was caused by the updating of data in the workbook I was doing but after having removed all code apart the call to the StockHistory function I realized that it is the call itself that is destabilizing Excel. Below the stripped-down function to reproduce the problem. Force multiple executions (at least two) of the function by clicking CRTL+ALT+F9 and then try to save the workbook.