Live Chat & Podcast at 1:00PM Eastern on Sunday!
There's no such thing as a stupid question, but they're the easiest to answer.
JoinTour
Login
Search
Business Applications
Tag Cloud
access acer asus bios bsod computer crash desktop driver drivers error ethernet excel freeze gaming hard drive hardware hdmi internet laptop malware memory modem monitor motherboard network printer problem ram registry router security slow software sound toshiba trojan ubuntu 11.10 uninstall usb video virus vista wifi windows windows 7 windows 7 32 bit windows 7 64 bit windows xp wireless
Search
Search for:
Tech Support Guy Forums > Software & Hardware > Business Applications >
Creating Macro/script in Excel

Reply  
Thread Tools
Couriant's Avatar
Distinguished Member with 27,146 posts.
 
Join Date: Mar 2002
Location: Chillin in AZ
Experience: B.S. in M.I.S
29-May-2008, 04:37 PM #16
Quote:
Originally Posted by Zack Barresse View Post
Ok, gotcha. One thing I would like to know though, how and where do you want this code to execute from? Is this something you'd like as an Excel add-in? Where it's always available, perhaps its own custom menu item (or Ribbon if you have 2007)? Would you like this to be in a specific file, so users must open it, then run the code? Would you like this in a VBS file where users can double click it and run the program (would take some restructuring)?

We can either walk you through installing the code, or do it for you (i.e. if it's an add-in). From the sounds of it thus far, I'd recommend an add-in, but it's up to you. Before we go any further we'd need to know that.
Hmm... decisions decisions...

Actually I think an 'add-in' would be better for the client. The simpler the better.
Zack Barresse's Avatar
Computer Specs
Distinguished Member with 5,030 posts.
 
Join Date: Jul 2004
Location: Oregon, United States
Experience: I'ma learnin'!
29-May-2008, 06:38 PM #17
Okay, so let's get the UI out of the way. What version(s) of Excel do you want to run this on? Put it this way, are you 97-2003, and if so what is the earliest version this will run on.. or do you run 2007? Do you want a custom menu, custom toolbar, custom ribbon? Do you have faceID preferences (button icons) and/or button text preferences? The file you presented is in 97-2003 format, so I'll assume you're not working with 2007. I don't think we're doing anything that won't run in all three versions, but it would be nice to know.

Oh, and what do you want it to be called?

Edit: And btw, yes I did notice you said you were using 2007, but don't know if your users are. We can do this in 2007 custom Ribbon if you'd like.

Last edited by Zack Barresse; 29-May-2008 at 06:43 PM.. Reason: Additional note.
Couriant's Avatar
Distinguished Member with 27,146 posts.
 
Join Date: Mar 2002
Location: Chillin in AZ
Experience: B.S. in M.I.S
29-May-2008, 11:06 PM #18
The client is using MSO 2003, and I have MSO XP (2002) as well as 2007. I can use my earlier version for this instance.
Zack Barresse's Avatar
Computer Specs
Distinguished Member with 5,030 posts.
 
Join Date: Jul 2004
Location: Oregon, United States
Experience: I'ma learnin'!
30-May-2008, 01:43 PM #19
Okay, make available for 2002. Gotcha. While I'm coding this up, is there anything else you wish to input about your UI? I.e. what the buttons should be called or anything?
Couriant's Avatar
Distinguished Member with 27,146 posts.
 
Join Date: Mar 2002
Location: Chillin in AZ
Experience: B.S. in M.I.S
30-May-2008, 03:02 PM #20
Whatever you feel a novice would understand
Zack Barresse's Avatar
Computer Specs
Distinguished Member with 5,030 posts.
 
Join Date: Jul 2004
Location: Oregon, United States
Experience: I'ma learnin'!
30-May-2008, 03:22 PM #21
Okay, check out the file. It's pretty basic, let us know what you think. I called it "CSV Importer". Of course you can change to whatever you like. I can post the code to this thread if you like, just let me know.

HTH
Attached Files
File Type: zip CSV Importer.zip (19.9 KB, 50 views)
Zack Barresse's Avatar
Computer Specs
Distinguished Member with 5,030 posts.
 
Join Date: Jul 2004
Location: Oregon, United States
Experience: I'ma learnin'!
30-May-2008, 03:45 PM #22
Oh! I forgot to add this code to the ThisWorkbook module...

Code:
Option Explicit

Private Sub Workbook_AddinInstall()
    Call CreateMenu
End Sub

Private Sub Workbook_AddinUninstall()
    Call DeleteMenu
End Sub
Then you need to install the add-in (as opposed to opening it).
Couriant's Avatar
Distinguished Member with 27,146 posts.
 
Join Date: Mar 2002
Location: Chillin in AZ
Experience: B.S. in M.I.S
30-May-2008, 09:09 PM #23
Quote:
Originally Posted by Zack Barresse View Post
Oh! I forgot to add this code to the ThisWorkbook module...

Code:
Option Explicit

Private Sub Workbook_AddinInstall()
    Call CreateMenu
End Sub

Private Sub Workbook_AddinUninstall()
    Call DeleteMenu
End Sub
Then you need to install the add-in (as opposed to opening it).
Where do I put this code?
Zack Barresse's Avatar
Computer Specs
Distinguished Member with 5,030 posts.
 
Join Date: Jul 2004
Location: Oregon, United States
Experience: I'ma learnin'!
02-Jun-2008, 02:57 PM #24
If you have the file open (as opposed to installing the add-in... if you have it installed, after saving the file uninstall it, close and restart Excel) in the VBE (Alt + F11), ensure you have the Project Explorer open (Ctrl +R). Find the file (CSV Importer.xla) and expand it, expand the folder and look for the ThisWorkbook module. Double click that and paste the code in that module. Save and close out Excel.

As stated above, if you have the file already installed, save it with the changes, uninstall it, then reinstall it. If you do not have it installed and you just opened the file, just save and close the file then install the add-in. If it's easier I could put the code in the file and repost. Sorry bout the confusion.
Couriant's Avatar
Distinguished Member with 27,146 posts.
 
Join Date: Mar 2002
Location: Chillin in AZ
Experience: B.S. in M.I.S
02-Jun-2008, 04:32 PM #25
Is doing right click small icon next to File the same as ThisWorkbook Module?
Zack Barresse's Avatar
Computer Specs
Distinguished Member with 5,030 posts.
 
Join Date: Jul 2004
Location: Oregon, United States
Experience: I'ma learnin'!
02-Jun-2008, 05:43 PM #26
Yes, right clicking that icon and selecting View Code (Excel 97-2003) will bring up the ThisWorkbook module. Remember though, if you're trying this with an add-in, you won't be in the right module - not even the right workbook. Add-ins have a visible property set to False, which is the big difference between them and a normal workbook. You must do it from the VBE to access its ThisWorkbook module.
Zack Barresse's Avatar
Computer Specs
Distinguished Member with 5,030 posts.
 
Join Date: Jul 2004
Location: Oregon, United States
Experience: I'ma learnin'!
06-Jun-2008, 09:15 PM #27
Did this ever work for you?
Reply

Tags
column, delete, excel, macro

THIS THREAD HAS EXPIRED.
Are you having the same problem? We have volunteers ready to answer your question, but first you'll have to join for free. Need help getting started? Check out our Welcome Guide.

Search Tech Support Guy

Find the solution to your
computer problem!




Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
WELCOME TO TECH SUPPORT GUY! Are you looking for the solution to your computer problem? Join our site today to ask your question -- for free! Our site is run completely by volunteers who want to help you solve your computer problems. See our Welcome Guide to get started.
Thread Tools



Facebook Facebook Twitter Twitter TechGuy.tv TechGuy.tv Mobile TSG Mobile
You Are Using:
Server ID
Advertisements do not imply our endorsement of that product or service.
All times are GMT -4. The time now is 11:53 PM.
Copyright © 1996 - 2011 TechGuy, Inc. All rights reserved.

Powered by Cermak Technologies, Inc.