using hyperlinks or macro buttons to time stamp

I am currently using this code to time stamp one cell, 

Private Sub Worksheet_Change(ByVal Target As Excel.Range)
With Target
If .Count > 1 Then Exit Sub
If Not Intersect(Range("A2:CL2"), .Cells) Is Nothing Then
Application.EnableEvents = False
If IsEmpty(.Value) Then
.Offset(0, 1).ClearContents
Else
With .Offset(0, 1)
.NumberFormat = "dd mmm yyyy h:mm:ss"
.Value = Now
End With
End If
Application.EnableEvents = True
End If
End With
End Sub


Can I do this to two cells, using a hyperlink, as in:

a1=start timer
a2=end timer

It is being used to track call center transaction times. 

Thanks, all. Lan

--
Message posted from http://www.ExcelForum.com

0
4/10/2004 5:55:53 PM
excel.misc 78881 articles. 5 followers. Follow

2 Replies
640 Views

Similar Articles

[PageSpeed] 40

Hi
you may explain which are the conditions to create a time stamp (if
both cells A1, A2 are filled, etc.)
you may also explain there the time stamp should be stored

--
Regards
Frank Kabel
Frankfurt, Germany


> I am currently using this code to time stamp one cell,
>
> Private Sub Worksheet_Change(ByVal Target As Excel.Range)
> With Target
> If .Count > 1 Then Exit Sub
> If Not Intersect(Range("A2:CL2"), .Cells) Is Nothing Then
> Application.EnableEvents = False
> If IsEmpty(.Value) Then
> Offset(0, 1).ClearContents
> Else
> With .Offset(0, 1)
> NumberFormat = "dd mmm yyyy h:mm:ss"
> Value = Now
> End With
> End If
> Application.EnableEvents = True
> End If
> End With
> End Sub
>
>
> Can I do this to two cells, using a hyperlink, as in:
>
> a1=start timer
> a2=end timer
>
> It is being used to track call center transaction times.
>
> Thanks, all. Lane
>
>
> ---
> Message posted from http://www.ExcelForum.com/

0
frank.kabel (11126)
4/10/2004 6:31:22 PM
If you click the hyperlink in a1, it places the current time in a2
(time start), if you click the hyperlink in a15, then again it place
the current time in a16. A17 would then be the difference between a1
and a2. Total tracked time. This would have to repeate thru to row bb

--
Message posted from http://www.ExcelForum.com

0
4/10/2004 6:49:35 PM
Reply:

Similar Artilces:

Setting up a Macro
What I want to do is record a macro and then have a button on the spreadsheet to click that will run the macro. The macro itself will cause a Solver to be run so it only has to open the Solver and input 2 predetermined cells and one predetermined hard number. I can start and stop a macro recording and set a hot key to run it, but when I run the macro its stops and tries to debug itself unsuccessfully. I know there are only a few steps to pull this off, but I can't seem to get it right. Any help would be appreciated. Post the code you are trying to run and indicate which line is throw...

How can I graph the #of times a certain word is found in Excel?
For example I have a list of reasons of what brand of butter a group of customers choose to buy.... How can I take the number of times "I can't believe it's not butter" is listed as compared to "Brommel and Brown", etc. and graph them accordingly onto one graph so if I have 512 occurances where customers chose "I can't believe it's not butter" and 256 occurances where customers chose "Brommel and Brown" - then I would like the graph is twice as large for the "I can't believe it's not butter". Hi, Just put in an ...

problem restoring to RSG using backup exec 10.1
I have been on and off the phone with Veritas for over 2 weeks now and they still cannot resolve this issue. I have a couple of good backups of our Exchange Information Store and have been trying to resotre just one mailstore to the RSG adn each time get an error message of "The job failed with the following error: Unable to restore some Microsoft Exchange components because one or more of the databases are currently mounted. Use the Exchange System Manager to dismount the databases, and then retry the job." It appears that backup exec is trying to restore the store to the...

Activate Chart Buttons
In an excel file, all the buttons for Charts in the Insert menu are not active. How do I activate them so that I can create new charts? thank you. Hi TJ, Make sure the worksheet is unprotected, that could be one reason for the buttons to be disabled "TJ" wrote: > In an excel file, all the buttons for Charts in the Insert menu are not > active. How do I activate them so that I can create new charts? thank you. ...

About Macros
Dear All, i am itrested to write my own macros, But i dont know anything about macro, i always copy the code and use. i want to make my excel spredsheet, from where to start macros, how to start, and what is macros pls i want to learn macro pls help Try here: http://www.your-save-time-and-improve-quality-technologies-online-resource.com/free-vba-tutorials.html http://www.anthony-vba.kefra.com/index.htm Micky "hitesh" wrote: > Dear All, > > i am itrested to write my own macros, But i dont know anything about macro, > i always copy the cod...

Run a macro when cell value changes
I have a macro that I would like to run, onlly when a particular cel value reaches a pre-defined value. I really do not know how to do this - I have looked on help features but to no avail. any ideas -- Message posted from http://www.ExcelForum.com right click sheet tab>view code>copy/paste this>modify to suit>save Now when cell c1 calculates to >32 your macro will fire Private Sub Worksheet_Calculate() If Range("c1") > 32 Then call yourmacro ' MsgBox "Hi" End Sub -- Don Guillett SalesAid Software donaldb@281.com "Emea training >&quo...

Using Outlook 2002 @ work and home
I have Outlook 2002 running on an XP Pro laptop. At work the laptop is in a AD domain(wired), and at home the laptop is using a Linsys wireless router for connectivity. Using Outlook at work is fine. I can send and receive messages without a hitch. The problem is when I leave my domain at work. I cannot send emails if I try to send mail to a recipiant that dosen't have my suffix of @pellatn.com. The weird thing is that I can receive mail from anyone. I don't understand why I can receive mail from any address, but I'm limited to sending messages to my fellow pellatn...

Mail sent using MailMessage class displays "TO" and "CC" recepients in the message body when sent to large number of recepients
I'm using System.Web.Mail to send an email message from an ASP.NET web page. This is the main section of the C# code. //************* start code ***************************** string[] mailHost = (System.Configuration.ConfigurationSettings.AppSettings.GetValues("mailserver")); //Get data from page string toAddress = ((tbTo.Text==null)||(tbTo.Text.Equals(String.Empty)))?String.Empty:tbTo.Text.Trim(); string ccAddress = ((tbCC.Text==null)||(tbCC.Text.Equals(String.Empty)))?String.Empty:tbCC.Text.Trim(); string subjectLine = ((tbSubject.Text==null)||(tbSubject.Text.Equals(String.Em...

Tricky Toolbar Button?
Is there a way to create a toolbar button that would open up a new mai message with the To: and Cc: fields already filled in? Thanks! : ----------------------------------------------- ~~ Message posted from http://www.ExcelTip.com ~~View and post usenet messages directly from http://www.ExcelForum.com I do not think you can just create a button and make this happen. What you can probably try is to create a form that has the field filled in and then make that form as the default for the new mai message ----------------------------------------------- ~~ Message posted from http://www.Ex...

Change button caption on each click
How to change button caption from "Check All" to "Check None" when clicked, and change back when click again (toggle)? Because of space limitation, I don't want to create 2 separate buttons. When click Check All, I update the field to -1 When click Check None, I update the field to 0 Thanks Something like this in the button's click event. With Me.cmdBtnName If .Caption = "Check All" Then .Caption = "Check None" ElseIf .Caption = "Check None" Then .Caption = "Check All" End If End...

NDR won't time out and keeps killing Outlook
Hi, I have a user who's Outlook has been crashing periodically for about a week. We think we've traced it back to an NDR he has been getting repeatedly for a week from the System Administrator, and I've been able to duplicate the crash on another system. The NDR appears to be in response to a recall request he made on a message to an outside company (not realizing this wouldn't work I guess). Each time the NDR comes into his mailbox, his Outlook shuts down. He doesn't even have to highlight it. There is nothing in the app or sys log on either the client or the ser...

Interesting problem: serializing in with MFC CArchive, reading out using C# BinaryReader
I've serialized in various variables of various types (mainly CString, int, double) into an instantiated MFC CArchive class and saved it as a binary file. I am able to open the binary file and read out the individual variables fine with an MFC application. However I cannot read the binary file correctly with a C#.NET application, where I'm using the BinaryReader Class. Doing some debugging I noticed that the problem occured at this C# line of code: my_variable_of_type_CString = instantiated_CSharp_binaryreader.ReadString(); When this line of code execute, the binary reads out the EN...

Opportunity Pipeline Stage Time Stamp
I am interested in reporting how long an opportunity takes to close (number of days) as it moves through the sales pipeline. Ideally we would like to see the number of days between each pipeline phase. Then we can analyze how long opportunities stay at each phase. Has anyone done anything like this before? Hi Kenny, You could do simple jscript behind a checkbox that will do a timestamp when checked. When that phase is complete click the checkbox. Create a nvarchar field to store the timestamp. Calling this FIELD1 in code Create a bit field and under properties change it to checkbox. Call...

Help: I need a macro to add words every 3 lines
Hello, I understand nothing to macro but I am sure that a macro can resolve my problem. I have the following columns, for example (it is for a dictionary database): House Maison [empty line] Car Voiture [empty line] Dog Chien [empty line] etc..... The first word is always in English and the second is always french. There is only 1 column but many lines. I would like to add "\en" in front of each English word, and "\fr" in front of each French word (in the same cell - I do not want to add a colum)... as a result I should get : \en House \fr Maison \en Car \fr Voitu...

Macro to auto save file using the format YYMM
Hi, I recorded a macro that automatically saves a file then change the formula in cell A1 to today's date, ie =today(), then save the file. I have a problem with the last part...is there any way I can set the macro such that the file will be saved as "c:\YYMM ABC" where 'YYMM' is the format of the date (probably can be taken from cell A1) and 'ABC' is my own file name? Thanks! You can get the date right in the code: dim myFileName as string myfilename = "C:\" & format(date,"yymm") & " ABC.xls" activeworkbook.saveas fi...

Using WORD document as report
Hi, I have a registration form that was created with Word. It contains information such as player name and address and contact info, etc etc. I'd like to somehow import this form into Access so I could have a database instead of having to print the Word form for each new player and then entering everything by hand. Am I making sense ? Basically I don't want to have to redo my form, I want to import it into Access to use as both a form to enter new info AND as a report. I also want to print both the completed form as well a a receipt once the info has been entered. Can anyone ...

Mail Merge macro
How can I record a macro, with a pause, and then resume the macro to make a mail merge. Data for merge is stored in Excel. Form is set up in Word. I can't get the macro to record. I'm not sure if this is true, but I think I'd record the macro while in MSWord. I would think that it would be easier there (from someone who hasn't done this). If you think that it might be true, you may want to post in one of the MSWord newsgroups. Wonder Women wrote: > > How can I record a macro, with a pause, and then resume the macro to make a > mail merge. Data for merge is...

Macro shortcut for Database Add-In
I am trying to create a macro that turns my F12 key into a shortcut for ALT-S-R in all my workbooks. I use that series of keystrokes often through Essbase, a Database add-in used through Excel. ALT-S-R are the keystrokes to retrieve data out of a database. If no range is highlighted it puts the top left corner of the data in the active cell; however, if you hit ALT-S-R while there is a range of cells highlighted, you will only populate those cells in the highlighted range with the data. I know at least some version of what I'm trying to get is possible. I had it working for a little whi...

How can I bybass sending to the Junk E-mail folder using IMF.
We would like any suspect messages to be sent to the users Inbox and not the Junk E-mail folder. Is there a way to do this? Also, what's the most popular scl settings? We're using 8 for the gateway setting and and 7 for the junk e-mail setting. -- tigerfanlsu On Mon, 18 Jul 2005 09:30:23 -0700, "kk" <kk@discussions.microsoft.com> hired a team of monkeys to write: >We would like any suspect messages to be sent to the users Inbox and not the >Junk E-mail folder. Is there a way to do this? >Also, what's the most popular scl settings? We're using...

Time Card Report?
How in the world do you run an accurate Time Card Report? Any & All Suggestions Welcome! -- Thank You,; Vince There's a time card report under Utilities/Crystal Reports, but it's not very flexible. There's an Active Report on the Reports Library of Customer Source that usually works better. If you already have those, what are you finding inaccurate? -- Glenn Adams Tiber Creek Consulting http://www.tibercreek.com glenn@tibercreek.com ---------------------------------------------- Please DO NOT respond to me directly but post all responses here in the newsgroup so that...

Copy Shape text to Custom properties using VBA
I want to copy the shape text to custom properties using VBA. Any help will be appreciated. Hello VB, Have a look at this post, which deals with something similar and let me know if you have any questions: http://groups.google.co.uk/group/microsoft.public.visio.general/browse_thread/thread/3712a3eb1daebc0e?hl=en&ie=UTF-8 Best regards John John Goldsmith (Visio MVP) www.visualSignals.typepad.co.uk www.visualSignals.co.uk "VB" <VB@discussions.microsoft.com> wrote in message news:D95EA556-60D3-413C-8C18-03854C74DEFC@microsoft.com... >I want to copy the shape text...

Real-Time Charting
Could someone please help me. I have setup my Excel spreadsheet to obtain real-time stock quotes. I would like to graph the stock price, especially during the day . How can this be done since I only have one cell that is constantly updated, and also is there some way to show multiple graphs, for instance, intra-day, past 30 days, past year etc. Thanks to everyone. I don't believe you can plot data that haven't been saved somewhere. -- Regards, Tushar Mehta, MS MVP -- Excel www.tushar-mehta.com Excel, PowerPoint, and VBA add-ins, tutorials Custom MS Office productivity sol...

Using POP for incoming, SMTP for outgoing
In Outlook Express, I could set up an account that used my company's POP3 mail server for incoming and my ISP's SMTP mail server for outgoing mail. I have set all the same types of settings in Outlook 2002 (I've downloaded & installed all the lastest patches, fixes, etc.). It won't let me send. I can receive, but it won't send Any ideas or further resources are appreciated. joezeppy wrote: > In Outlook Express, I could set up an account that used my company's > POP3 mail server for incoming and my ISP's SMTP mail server for > outgoing mail. I h...

OneNote 2007 What is the best way to create or use onenote for the following
I am trying to creat a Notebook that I can keep a reference about the applications I work with: The structure of the Information is as follows: Software Application 1 Informations Module 1 information Module 2 information Application 2 Informations Module 1 information Module 2 information and the list go on What is the best way to do that and I am a little bit confuse about what is the different between section and section group Thank your help and recommendat...

Clicking on restore window button changing the freeze pane in exce
Hi, In our application after clicking a button in excel , we are programmatically setting the freeze pane for excel workbbook.This click event takes some time even it calls webservice.But in mean time if the user clicks on "Restore" window in inner part of excel, this freeze pane setting is changed from the requires setting that has been done during programming. rn=toSheet.get_Range(sqlReportProperties.FreezePane,missing); ((Excel.Range)rn.Cells[1,1]).Activate(); excelApplication.Windows[1].FreezePanes=true; Can any one please urgently help on this. thanx sriram ...