Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default How to create a form control over a specific cell

I'm trying to automatically create form controls such as check boxes and put
them on a work sheet.
The function that has to be called appear to be

ActiveWorksheet.Shapes.AddFormControl(xlCheckBox,L eft,Top,Width,Height)

I'd like it to be placed over a specific cell but AddFormControl requires
coordinates in pixels. Is there any way to get the pixel coordinates of a
cell? Do you know any other way to accomplish this task?

Thank you.


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default How to create a form control over a specific cell

"Valerio" ha scritto nel messaggio
...
I'm trying to automatically create form controls such as check boxes and

put
them on a work sheet.


Ok, I found the answer by myself... I'm posting it here if someone else need
it.

Set c = ws.Range("c32")
Set cb = ws.Shapes.AddFormControl(xlCheckBox, c.left, c.top,
c.Width,c.Height)

The properties left / top etc. are what I needed.

Thank you


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
2007 Form Control/ActiveX Control font difference Nikko963 Excel Discussion (Misc queries) 0 April 15th 09 04:21 PM
two questions, Yes/No form control, and how did they create this adjustable area on the sheet... Kelvin[_2_] Excel Discussion (Misc queries) 3 November 29th 07 05:49 PM
two questions, Yes/No form control, and how did they create this adjustable area on the sheet... Kelvin[_2_] Excel Worksheet Functions 3 November 29th 07 05:49 PM
Is it possible to create a dynamic range in CONTROL TOOLBOX (form) [email protected] Excel Discussion (Misc queries) 7 July 27th 07 07:28 AM
How do I create a form in a worksheet with control option buttons. andreah New Users to Excel 2 April 23rd 05 01:12 AM


All times are GMT +1. The time now is 11:16 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"