![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
#1 |
Harper
![]() Join Date: October 6, 2001
Location: Iceland
Posts: 4,706
|
Is anyone here good at Visual Basic for Excel?
I need to do a small application that takes info from cells and puts it into a string and then displays it in a textbox on a form... I have it pretty much figured out but how do I tell it which cell I want to pick up for my string? |
![]() |
![]() |
#2 |
Jack Burton
![]() Join Date: March 21, 2001
Location: Philippines, but now Harbor City Sydney
Age: 42
Posts: 5,556
|
sub XXXX
dim X sheets.("Name of the sheet").select range("cell name").select x= activecell.value msgbox x im taking it up this summer class and have an exam for tom. [img]smile.gif[/img] try it.. it should work i guess
__________________
![]() Catch me if you can.. ![]() |
![]() |
![]() |
#3 |
Harper
![]() Join Date: October 6, 2001
Location: Iceland
Posts: 4,706
|
cool thanks... [img]smile.gif[/img]
I'm going to a class now but will try it when I get back... [img]smile.gif[/img] [edit] Hmm always fun when you think you have class and it's cancelled and everyone knows except you... Anyway, I tried it and it works... I'm trying to do a kind of a book cataloging system, were I can put in the book information into an Excel sheet and then press a button and it takes the information and puts proper cataloging punctuation into it, prints it to a textbox that I can copy and insert into word... [img]smile.gif[/img] Big task, I just realised it will take a lot more time to write the code than I imagined... [img]smile.gif[/img] But I'll try... [ 02-10-2004, 06:58 AM: Message edited by: Jorath Calar ] |
![]() |
![]() |
#4 |
Jack Burton
![]() Join Date: March 21, 2001
Location: Philippines, but now Harbor City Sydney
Age: 42
Posts: 5,556
|
thats great and good luck.. its a big task that im sure. (doing a simple quotation calculation code is such as pain-in-the A$$ for me.) that was my proj for the summer.
oh yeah for mass range selection it would be like ("A1:Z20") that would select everything in its area. since your doing a book cataloging system this might help ya.
__________________
![]() Catch me if you can.. ![]() |
![]() |
![]() |
#5 |
Bastet - Egyptian Cat Goddess
![]() Join Date: September 5, 2001
Location: Calgary, AB
Age: 50
Posts: 3,491
|
Looks like you got your answer. VBA is great, many of companies still use excel so knowing VBA can be very helpful.
One of my problems was I had a ton of data for retail locations. They were divided into sheets by provinces and states. This data is updated often and needs to go up to the web by province and state. I created a little VBA program to loop through each sheet when it is updated obtaining all the data and turning it in to a JavaScript array to be used by the web. Before I got the problem they were retyping all the data all the time, which is insanity. I had to do some JavaScript to access the data when someone clicks a link. But that is extra and if you wanted you could have just turned the data straight from excel into formatted HTML pages using VBA. Just imagine cutting the time of a task from days to seconds. Anyway this is a practical application of VBA. Good luck!!!!! [ 02-10-2004, 10:47 AM: Message edited by: pritchke ] |
![]() |
![]() |
#6 |
Galvatron
![]() Join Date: January 22, 2002
Location: california wine country
Age: 61
Posts: 2,193
|
you can also reference cells by row and column, this is really handy if you have to process a whole table cell by cell.
cell(R,C) Where R = the row number and C = the column number and both are integers.
__________________
“This is an impressive crowd, the haves and the have mores. <br />Some people call you the elite. <br />I call you my base.”<br />~ George W. Bush (2000) |
![]() |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Excel question | ZFR | General Discussion | 2 | 03-28-2007 05:16 AM |
Need help with Excel.. | Kakero | General Discussion | 3 | 11-15-2005 06:13 AM |
Need to create a drop-down checklist box for EXCEL... | quietman1920 | General Discussion | 1 | 07-14-2005 02:25 PM |
Help with excel and logarithmic scales | philip | General Conversation Archives (11/2000 - 01/2005) | 8 | 12-31-2003 07:22 PM |
Excel...Some Help Needed... | FelixJaeger | General Conversation Archives (11/2000 - 01/2005) | 4 | 04-22-2003 08:58 AM |