Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Microsoft Office > Excel VBA > Excel VBA
Password Reminder
Register
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
Excel VBA Discuss using VBA for Excel programming.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Excel VBA section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old February 2nd, 2005, 12:59 AM
Friend of Wrox
 
Join Date: Jun 2004
Location: Chennai, Tamil Nadu, India.
Posts: 449
Thanks: 0
Thanked 1 Time in 1 Post
Send a message via MSN to r_ganesh76
Default Setting Column Width

Hi Experts,

I am new to VBA & Excel Programming.

I am designing some reports to be viewd in Excel. I am using VBA for generating the reports. Can someone tell me how to set the column width and other properties.

I would be happy if someone could send me some good links for Excel-VBA reference.

Regards
Ganesh

Regards
Ganesh
__________________
Regards
Ganesh
http://ganeshprof.blogspot.com
Find your solution here...
Reply With Quote
  #2 (permalink)  
Old February 2nd, 2005, 05:17 AM
Friend of Wrox
 
Join Date: Jan 2005
Location: Bournemouth, Dorset, United Kingdom.
Posts: 180
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Being new to VBA I would recommend you first port of call to be utilising the record macro functionality, known as the Excel Primer. If you go to [Tools]-[Macro]-[Record New Macro] a dialogue box appears asking where you want to record the macro, usually you would set this to "This Workbook" and click continue/OK.
Conduct the processes you want to achieve such as adjusting the column widths as you described, then click on the stop icon represented by the filled square. This stops recording the macro you have just created.

Then go to [Tools]-[Macro]-[Macros] and in the form that appears select the name of the macro you have just created and click edit. You will then be shown the environment called the Visual Basic Editor or VBE. The code displayed in the VBE is what you just recorded. Make yourself accustomed to the different areas and what they are showing you. Look at the code, if necessary step through one process at a time in the code by first placing the cursor within the text of the macro and by pressing the function key [F8] execute on line at a time, if you split your windows into two half screen with both excel and VBE visable you can see the results of the code as it is executed. I found this is the best way to learn the basics.
I now swear by the wrox "Excel 2000 VBA - programmers reference" book. I don't work for them, but I think it is excellent value for money.

If you are having trouble with specific code once you have recorded it and amended it, then post the code with your problem on forums such as this.

Regards


Matthew

Reply With Quote
  #3 (permalink)  
Old February 2nd, 2005, 06:06 AM
Friend of Wrox
 
Join Date: Jun 2004
Location: Chennai, Tamil Nadu, India.
Posts: 449
Thanks: 0
Thanked 1 Time in 1 Post
Send a message via MSN to r_ganesh76
Default

Thanx Mathew for your reply. I will follow what you mentioned

Regards
Ganesh
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Table: width setting for a cell Venki XSLT 2 July 14th, 2008 09:05 AM
Setting the Logical Page Width mitchm Crystal Reports 0 May 24th, 2007 06:03 PM
Setting Column width in Datagrid anita General .NET 2 April 13th, 2005 02:25 AM
Column width immanuelsamuel Oracle 2 March 13th, 2004 10:30 AM



All times are GMT -4. The time now is 03:00 PM.


Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.