Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Banned
 
Posts: 3
Default capture date at another sheets using Marlett

I need an expert like you to solve my problem.

I have a Attendant Table for Staff, which consists of Name, Staff ID and so on.
I have already create the code for “Automatic appearance of date in Column D when you Double Click the Column C of attendance column “. The code is like this:

Option Explicit
Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As Boolean)
'Limit Target count to 1
If Target.Count 1 Then Exit Sub
'Isolate Target to a specific range
If Intersect(Target, Range("CheckBoxs")) Is Nothing Then Exit Sub
'Set Target font to "marlett"
Target.Font.Name = "marlett"
'Check value of target
If Target.Value < "a" Then
Target.Value = "a" 'Sets target Value = "a"
Cancel = True
Exit Sub
End If
If Target.Value = "a" Then
Target.ClearContents 'Sets target Value = ""
Cancel = True
Exit Sub
End If
End Sub

Private Sub Worksheet_Change(ByVal Target As Range)
'Limit Target count to 1
If Target.Count 1 Then Exit Sub
'Isolate Target to a specific range
If Intersect(Target, Range("CheckBoxs")) Is Nothing Then Exit Sub
'Select a specific subset of the range "Ckboxes"
Select Case Target.Address
Case Else

If Target.Value = "a" Then
Target.Offset(0, 1).Value = Date
Else:

Target.Offset(0, 1).Value = ""
End If
End Select



Name and staff id already available in sheet2. Sheet2 is the database that will be store all the information. Date that will captured is current date(today date) when double click the Column C of attendance column then date will appear. I will clicking in the row at attendance column. The tick is create by using marlett function. You can refer the coding above.The action should be done is like this, if sheet2 have similar name and staff id like in sheet1 then date is should copy or ??? in sheet2 (column date)


I hope you can help me bout this problem. I attach an image to clear what I need.
I appreciate your help.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 84
Default capture date at another sheets using Marlett

Your worksheet event code works fine. However I don't understand what you
want to do, in particular -

The action should be done is like this, if sheet2 have
similar name and staff id like in sheet1 then date is should copy or ???
in sheet2 (column date)


Try and explain, give alternative examples of data in cells (give addresses
including on what sheet), what you want before and after double clicking.
Also what sheet is the event code run in.

Regards,
Peter T


"niailmar" wrote in message
...

I need an expert like you to solve my problem.

I have a Attendant Table for Staff, which consists of Name, Staff ID and
so on.
I have already create the code for “Automatic appearance of date in
Column D when you Double Click the Column C of attendance column “. The
code is like this:

Option Explicit
Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As
Boolean)
'Limit Target count to 1
If Target.Count 1 Then Exit Sub
'Isolate Target to a specific range
If Intersect(Target, Range("CheckBoxs")) Is Nothing Then Exit Sub
'Set Target font to "marlett"
Target.Font.Name = "marlett"
'Check value of target
If Target.Value < "a" Then
Target.Value = "a" 'Sets target Value = "a"
Cancel = True
Exit Sub
End If
If Target.Value = "a" Then
Target.ClearContents 'Sets target Value = ""
Cancel = True
Exit Sub
End If
End Sub

Private Sub Worksheet_Change(ByVal Target As Range)
'Limit Target count to 1
If Target.Count 1 Then Exit Sub
'Isolate Target to a specific range
If Intersect(Target, Range("CheckBoxs")) Is Nothing Then Exit Sub
'Select a specific subset of the range "Ckboxes"
Select Case Target.Address
Case Else

If Target.Value = "a" Then
Target.Offset(0, 1).Value = Date
Else:

Target.Offset(0, 1).Value = ""
End If
End Select



Name and staff id already available in sheet2. Sheet2 is the database
that will be store all the information. Date that will captured is
current date(today date) when double click the Column C of attendance
column then date will appear. I will clicking in the row at attendance
column. The tick is create by using marlett function. You can refer the
coding above.The action should be done is like this, if sheet2 have
similar name and staff id like in sheet1 then date is should copy or ???
in sheet2 (column date)


I hope you can help me bout this problem. I attach an image to clear
what I need.
I appreciate your help.




--
niailmar


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I capture a date? Capture a variable date & use with text Excel Discussion (Misc queries) 3 November 27th 08 02:40 AM
Marlett font Sledge Excel Discussion (Misc queries) 2 October 29th 07 08:46 AM
How do I capture info from multiple sheets to main worksheet? cempire5 Excel Discussion (Misc queries) 5 September 13th 07 03:36 AM
Capture date for =MAX(a1:a250) formula Rick I Excel Programming 2 September 12th 06 02:20 AM
want to capture date elegantpartner Excel Discussion (Misc queries) 1 January 9th 06 04:20 AM


All times are GMT +1. The time now is 08:00 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"