ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   creating checkbox through form (https://www.excelbanter.com/excel-programming/291750-creating-checkbox-through-form.html)

yami-s[_5_]

creating checkbox through form
 
Hi,
i have a form where the user fills in information, that by clicking the
submit button the form's information is pulled to the spreadsheet.
In one of the columns, I would like to create a checkbox that based on
the information in the form it can be checked or not.
I can I do it???
Thanks in advance
Yami


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


Bob Phillips[_6_]

creating checkbox through form
 
Yami,

Bit short on info, but a control checkbox can be set with

ActiveSheet.CheckBox1.Value = True

or unset by setting to False.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"yami-s " wrote in message
...
Hi,
i have a form where the user fills in information, that by clicking the
submit button the form's information is pulled to the spreadsheet.
In one of the columns, I would like to create a checkbox that based on
the information in the form it can be checked or not.
I can I do it???
Thanks in advance
Yami


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




yami-s[_6_]

creating checkbox through form
 
Hi bob,
10x for the reply, i'll try to give more details.
1. I need to create the check box form a form.
2. The check box should be created in a cell
3. The check box is part of an off set

I'll put in some code i hope it will help

Private Sub Submit1_Click()

Dim rng As Range
ActiveWorkbook.Sheets("Database").Activate

Range("B2").Select

Do

If IsEmpty(ActiveCell) = False Then

ActiveCell.Offset(1, 0).Select

End If

Loop Until IsEmpty(ActiveCell) = True

ActiveCell.Value = cboConsultant.Value

ActiveCell.Offset(0, 1) = cboCostumer.Value

ActiveCell.Offset(0, 2) = cboSubtask.Value

ActiveCell.Offset(0, 3) = txtDescription.Value

ActiveCell.Offset(0, 4) = txtDate.Value

ActiveCell.Offset(0, 5) = txtHours.Value

ActiveCell.Offset(0, 6) = cboPriority.Value

ActiveCell.Offset(0, 7) = txtMisc.Value

If chkDeliverd = True Then

ActiveCell.Offset(0, 8).Value = "done"
' ActiveSheet.OLEObjects.Add(ClassType:="Forms.Check Box.1"
Link:=True, _
' DisplayAsIcon:=True, Left:=547.5, Top:=130.5, Width:=41.25
Height:= _
' 27.75).Select

I want to repalce the "done" with a checkbox


10x
Yam

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



All times are GMT +1. The time now is 09:41 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com