![]() |
Limit due to selected cells
G'morning,
I have a to-do-list in Excel consisting of 5 columns (A:E). Every new task is on a new row. If needed I can create tasks in Outlook with the help of commandbutton (which has code assigned to it that extracts the info I need to the body of the task). What I would like to do now is to create an extra statement (within the current statement) that states that if I'm not in a cell in column D the code behind the commandbutton does not work (to prevent faults or tasks that are unclear). Any help would be greatly appreciated. Regards, Basta 1980 |
Limit due to selected cells
Try
If ActiveCell.Column < 4 Then 'your current code End If OR place the below on top of your current procedure If ActiveCell.Column = 4 Exit Sub -- Jacob (MVP - Excel) "Basta1980" wrote: G'morning, I have a to-do-list in Excel consisting of 5 columns (A:E). Every new task is on a new row. If needed I can create tasks in Outlook with the help of commandbutton (which has code assigned to it that extracts the info I need to the body of the task). What I would like to do now is to create an extra statement (within the current statement) that states that if I'm not in a cell in column D the code behind the commandbutton does not work (to prevent faults or tasks that are unclear). Any help would be greatly appreciated. Regards, Basta 1980 |
Limit due to selected cells
Jacob,
Thnx again. Works like a charm Regards Basta1980 "Jacob Skaria" wrote: Try If ActiveCell.Column < 4 Then 'your current code End If OR place the below on top of your current procedure If ActiveCell.Column = 4 Exit Sub -- Jacob (MVP - Excel) "Basta1980" wrote: G'morning, I have a to-do-list in Excel consisting of 5 columns (A:E). Every new task is on a new row. If needed I can create tasks in Outlook with the help of commandbutton (which has code assigned to it that extracts the info I need to the body of the task). What I would like to do now is to create an extra statement (within the current statement) that states that if I'm not in a cell in column D the code behind the commandbutton does not work (to prevent faults or tasks that are unclear). Any help would be greatly appreciated. Regards, Basta 1980 |
All times are GMT +1. The time now is 04:30 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com