boolean

  1. L

    VBA Frustration

    I inherited a project from an ex-coworker and part of it involves an Excel workbook with a VBA code. I am only just learning VBA and out IT department is useless so I figured I’d try here. I’ve been able to fix most of the compile errors but these 2 errors persist and I can’t figure out how to...
  2. L

    VBA Troubles

    I inherited a project from a ex-coworker and part of it involves Excel with a VBA code. I am not well versed in VBA...actually not versed at all and our IT department is useless so I figured I'd try a forum to see if anyone could help. I continue to get error messages from the code and no matter...
  3. H

    Boolean True/False values not recognised in Countifs formula

    Hi, I am running an SQL statement query via Azure directly into Excel. The data is from Salesforce and some of the columns contain Boolean values shown as true or false (left aligned all lower case). An example of the data set is below: Salesman Converted Date Fred...
  4. C

    VBA Modifcation

    Good afternoon, Could someone possibly help with amending the VBA below as our VBA guru has left our company. All I need the amendment to be is in Column J add the comment "To be updated" (from cell J2 onwards for each row where there is data in the prior column) Thank you Private Sub...
  5. K

    Validate

    Why wont this script color the column M if it meets both criteria: Sub Validate() Dim found As Boolean found = False For Each cell In Range("F2:M1000").Cells If cell.Value = "FT Hourly" And "<40" Then found = True End If Next If found = True Then...
  6. T

    BeforeSave Crashing When Closing Workbook

    Hi all, If I save my workbook during my session the below code works perfectly, refreshing the query quietly in the background. The problem I am facing is that when I am prompted to save on close the macro will start running (I can see that it starts because of the "retrieving data" status...
  7. S

    VBA code that will comment out other vba code?

    So I've got a worbook made for others to use that has the "save" disabled, to preserve the workbook. I'd like to make a button or something that will open the 'save as' command but also comment out/disable the 'save disable' code, that way, they can save-as a new file in their own folder and...
  8. A

    Automatically Email worksheet when saved

    Hi all I hope you can help me, I have managed to make my workbook automatically send an email when the workbook is saved using the code below, however the only problem is that the selection on the email is massize and spreads across 2-3 pages, meaning that it can not be printed, can I add...
  9. J

    Overwrite msgbox Yes/No issue

    Hello I am in need of your help, I am trying to add a message box popup in VBA that when a user selects file>save or ctrl+s, it prompts them with a message box that states "Do you really want to overwrite this file?" Yes button to continue to save, No button to cancel and close the message box...
  10. B

    I need help with Boolean

    Sub isempty() Dim i As Integer Dim LastRow As Range LastRow = Range("A65536").End(xlUp).Row For i = 1 To LastRow If isempty(cells(i, 1)) Then cells(i, 1).Resize(1, 4).Interior.ColorIndex = 1 End If Next i End Sub is empty is a boolean function Here is the attachment link...
  11. S

    COUNTIF = "True" as string, not boolean

    I run a report from our HR system that outputs a True/False column as a string (verified using =TYPE() formula). When attempting to do the countif formula below on the column it does not count them: =COUNTIF(TermList[Is Voluntary?],"False") It works when I change the column to a Boolean and...
  12. P

    Get the value of a Boolean variable by passing its name as text

    I would like to Get the value of a Boolean variable by passing its name as text. The following line works for me in another file lablnam = Me.Controls(StrArrOptBtnLblNam(ctra, 1)).Caption Is there an equivalent as the above or something else to get value of variables using the names of the...
  13. R

    Trouble with a boolean statement using textbox value

    Greetings ~ I am trying to create a Boolean condition with the value of a textbox which has its value expressed in "hh:mm:ss" format. Below is the conditional statement which simply will not read correctly If Format(.TextBox74.Text, "hh:mm:ss") > "3:00" Then .TextBox74.BackColor =...
  14. B

    Referencing a Shared Calendar

    Hi Guys, I was just wondering if anyone knows how to reference a shared calendar location in the below code. the location i am trying to reference is "\UK Public Folders\Customer Services\UK Customer Services Calendar" Sub CreateOutlookAppointment() Dim strCategory As String, strTopic As...
  15. kpasa

    Pass boolean to userform

    I am trying to pass a boolean from a sub into a userform. I want to activate a userform with a boolean named PrintVal set to true by this particular macro. On userform_activate, If printval is true then i want to run a special bit of code. Else just launch the form like normal. How can I...
  16. B

    VBA test to check if a specific Button (Form Control) was clicked

    I have a button (form control, not ActiveX). I renamed this button "butVA03". I also have 15 other buttons in my excel sheet, but I want a test to check if "butVA03" was the button that I clicked. Is this possible? My suspicion is that I'm not defining "butVA03" correctly as a specific button...
  17. B

    Conditional SUMPRODUCT where condition is met in any of multiple columns

    I'm currently using the following formula for a weighted average to great success: =SUMPRODUCT(--($V$3:$V$200=$Z5),G$3:G$200,$P$3:$P$200)/(SUMIF($V$3:$V$200,$Z5,$P$3:$P$200)) where the bold criteria is something I need to alter for another weighted average. My problem is that the set of...
  18. I

    Analyse Data Table

    Hello all I am working on analysing accident data listed in a table, not a range (Excel 2010 Win7). The data get imported (VBA) to that table from single sheets with which accidents are recorded. Where for example an injury is ticked, the corresponding cell contains a boolean true/false value...
  19. C

    VBA Email when save problems! Need help with attachments and multiple email address'

    I have this code in VBA which currently works perfectly fine but I want to add to it and cant seem to get my head around it. As it stands, when you press save on the workbook it automatically sends an email to the email address in the code stating the date and time the work book was updated...
  20. D

    Seeing if a value is on another Sheet function

    Hello all, I'm trying to write a function for one of my reports that would perform a boolean function to see whether or not a cell's value is on another sheet in the workbook. Pretty much (If it's on that sheet, Yes, if not, see if it's on this sheet). Here's what I have so far Public...

Some videos you may like

This Week's Hot Topics

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
Top