case

  1. S

    VBA Clear Content based on certain value

    hi all I have a column with a formula and want VBA to clear those cells taht contain the #Value ! error.. I put together below code, which doesn't error but also doesn't do what I want it to do? Dim find As String find = "#Value !" Select Case find Case Cells(2, 3).Value...
  2. T

    If ... then or Select Case ?

    Hi Guys, Does anybody have experience which is quicker - long (If Then Else) construction or (Select Case) ? Thanks in advance. Regards
  3. H

    Simplify Code

    Hi - I have this code in the sheet tab and it executes on a worksheet change. I'm assuming there is a much easier way to do this? Sheets are labeled by their codenames. Thanks! If Not Intersect(Target, Range("A3")) Is Nothing Then Rows.Hidden = False Select Case Target.Value...
  4. B

    Get email recipients (FROM / TO / CC / BCC) from outlook mail item

    My code I have creates a table from getTable method but I have recently learned there is no MAPI property to return the email addresses of these so my table columns are useless for this part. It seems the only way to do it is via the mail item object. However, I notice with my code below which...
  5. D

    dynamic report header

    Access 365 I have a QBF with a combobox "CboGrouping" that tells the report the tow grouping the user wants. (code from Allen Brown) Now I need to add the correct fields in the Header area... i.e. if case 1, then District Header would be [District] and District Header would be [District]...
  6. K

    Userform TextBox Case and number formating

    Hi. I have a User Form to add information in a data list. In some of the textboxes, I want the information to be added to the list in a certain format. For example: 1. the engine model to be all in UPPER CASE 2. the manufacturer to be in Proper Case, unless user entered all information...
  7. Y

    VBA Chart colour change using case select and wild card

    Hi all VBA experts out there, I have a chart where a macro is able to change the series color using case select. However when I try to introduce wild card into this case select, I am hitting a road block. Below is what I got working, as you can see I would like to introduce a wild card...
  8. J

    Delete selected Range in selected Sheets

    Deleteselected Range in selected Sheets Cananyone help with a code that deletes a Range starting in "A7" to bedeleted in all Sheets except two in the workbook? Rangecan vary in number of Rows. Afterall Sheets are deleted, cell "A7" must be active on all sheets thathave been deleted...
  9. D

    object required error

    office 365 ms access Form f_Site and subform f_site_variation. Form uses list box to find records of a specific alphabet. Also allows the new Site record. Sub Form adds a variation of the Site name, if any. Getting an "Object required" error when clicking add site variation button. This...
  10. willow1985

    VBA: Run macro Yes or no prompt, Case without Select Case Error

    Hi, I have the following VBA code but it is giving me a Case without Select Case Error. I am not sure what I am missing and hope you will be able to help. Here is the code: Sub NewData() ' ' Paste Macro ' If ThisWorkbook.Sheets("New Data").Range("A2").Value = "" Then MsgBox "Work Order # has...
  11. A

    Excel VBA for running consecutive loops

    I have created an excel userform to record pallets of rejected product on a production line. The user fills in details and prints out a label to insert on the pallet of rejected product. On occasion, the production line may be able to reuse rejected product within the production area and there...
  12. countryfan_nt

    Compile Error: compile error constant expression required.

    Hello friends, Hope all is well! Please help me with the bug below. the code converts Arabic numbers to text. When I apply the code I get: Compile Error: compile error constant expression required. The highlight is on: .Value of the line: Private Const MyBegTx As String =...
  13. P

    Compile error: Invalid or unqualified reference and For Loop Doesn't Loop

    I have a userform with six option buttons and and three textboxes. I would like the code to loop through column G until it finds the first value that equals the value of textbox 3 then offset back three cells and check if that value equals the value in textbox1. Whether it contains the value or...
  14. P

    Runtime Error 91 Object variable or with block variable not set

    On my userform, I have six option buttons and three textboxes. When I run this code I get the following runtime error '91. Option Explicit Dim sPath As String, sFile As String Dim wb As Workbook Dim ws As Worksheet Dim rng As Range Private Sub cmdbtnOpen_Click() sPath =...
  15. D

    VBA Code simplification - Creating folder with month/year

    Hi all I have some long code here that I want to try and simplify/shorten, if possible. It's attached to a button on one of my forms. The code works great as it is though. Any suggestion? It checks if a directory exists before moving a spreadsheet and adding the date at the end of it before...
  16. M

    Charts won't maintain series color when only changing values with VBA

    When I attempt to use the following to update series values using an array, The series don't maintain their coloration and defaults to one of the available presets. With Chart_Dictionary.Item("Non-C").Chart For L = 1 To 4 .FullSeriesCollection(L).XValues = Date_Range...
  17. T

    Select Case - Squishy spot on forehead

    After digging through umpteen references - I'm still trying to figure out what I'm doing wrong here. Per the comments in the code: I have a workbook where on one worksheet there is a named range - _FST with a drop down select for yes or no. Based on the answer I want to perform a SUM of 40 -...
  18. T

    VBA Assigning workload evening to available users

    Hello, I'm trying to work on creating a spreadsheet that will automatically assign cases to available users evenly (Assigned user goes in column A) For the attached example I have 217 cases and 13 available users. I need items assigned out as a priority as follows: Cases with "Late...
  19. F

    VBA Cutting/Pasting from one column to another depending on variable

    Good Evening, I'm still fairly new to VBA and my googling hasn't gotten me results. I'm trying to move data from 3 columns to a different 3 columns, same workbook and sheet, even the same row. The column data is being moved to depends on what is in the first column, from what I can tell this...
  20. Mackeral

    ERRORS in VBA FUnctions "InputBox" & "Select Case"

    These 2 VBA expressions do not function as it the are documented to, and I found that these had been recently implimented and broke code I've been running for years. INPUTBOX The docmentation says that if you hit the "Cancel" key that the routine returns a FALSE. It now returns an Empty String...

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top