Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Starting Out


Hello

I have been dabbling with excel spreadsheets for a while and now need
to learn how to use VB (Ineed it to help me reset the values of my
variable cells).

Could you please guide me in the right direction, as to where I need to
go to learn how to write functions and formulas in VB.

Thank you
Trilogy


--
trilogy
------------------------------------------------------------------------
trilogy's Profile: http://www.excelforum.com/member.php...o&userid=36833
View this thread: http://www.excelforum.com/showthread...hreadid=566500

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 16
Default Starting Out

There are many good books available in any good bookstore or on Amazon.

If you need something simple to start with you can simply create a macro,
assign a keycode to it (like Control-K) and put the following code in it:

Sheets("SheetName").Range("a1").value = "InitalValue1"
Sheets("SheetName").Range("b1").value = "InitalValue2"
etc.

Alternatively, you can create some code and a button on a UserForm as follows:

1. create a userform with a button on it. The Button Caption (label) can be
"Reset Values".

2. In the Workbook_Load event you can include the line

UserForm.Show

3. In the button_ Click event, You can simply write the following:

Dim ExcelApp as Excel.Application
Dim MySheet as Excel.Sheet
' set ExcelApp to the existing application
Set ExcelApp = GetObject (,"Excel.Application")

Set MySheet = ExcelApp.Sheets("whateeveryoursheetNameis")

MySheet.Range("A1").value = initalvalue1
MySheet.Range("B1").value = initalvalue2

..
..
..

Hope this helps.

Arif


"trilogy" wrote:


Hello

I have been dabbling with excel spreadsheets for a while and now need
to learn how to use VB (Ineed it to help me reset the values of my
variable cells).

Could you please guide me in the right direction, as to where I need to
go to learn how to write functions and formulas in VB.

Thank you
Trilogy


--
trilogy
------------------------------------------------------------------------
trilogy's Profile: http://www.excelforum.com/member.php...o&userid=36833
View this thread: http://www.excelforum.com/showthread...hreadid=566500


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Starting Out


Thank you Arif

Your help has been invaluable in setting me on the right path.

Thank you

Trilogy


--
trilogy
------------------------------------------------------------------------
trilogy's Profile: http://www.excelforum.com/member.php...o&userid=36833
View this thread: http://www.excelforum.com/showthread...hreadid=566500

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
Starting with a zero? karyd Excel Discussion (Misc queries) 3 October 6th 08 04:28 AM
Starting add-in using vba utmb[_2_] Excel Programming 1 November 7th 04 02:08 AM
Starting add-in using vba utmb[_3_] Excel Programming 0 November 5th 04 04:51 PM
Starting over TyeJae[_15_] Excel Programming 9 June 17th 04 02:23 AM
Starting a userform upon starting the file Fritznel Excel Programming 1 July 28th 03 05:37 AM


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