Visual Basic Editor

dpeattie

New Member
Joined
Sep 15, 2002
Messages
17
I'm trying to use the VBE command for Import Files, and it's not working.

My assumption going in was that this feature enables me to import any type of file I want from an external source into Excel. However, when I try to do that, I get an error message that says:

"Cannot find the C:PROGRAMFILESCOMMONFILESMICROSOFTSHAREDVBAVEenU13.hlp help file. Check your system to see if this file is installed. If not, reinstall it."

Question one: am I wrong when I think that the VBE feature should be allowing me to import any type of file I want, or is it just certain types of files that the VBE feature will let me import? If so, what types of files can I use this feature with?

Question two: if the help file listed above is one that's necessary to get this feature to work, shouldn't it install automatically when I load Windows and the Excel package?

Question three: if the problem isn't in these areas, then what am I doing wrong?

As always, everyone's help and patience is appreciated!

David
 

Excel Facts

Format cells as currency
Select range and press Ctrl+Shift+4 to format cells as currency. (Shift 4 is the $ sign).
Hi, Vog!

What code? Is this something I need to know programmer-type code to be able to do it? I really am a babe in the woods with some of these things...

David
 
Upvote 0
This is a very confusing post.... it is not really very clear what it is you are trying to do, and specifically, where it is going wrong.
 
Upvote 0
Sorry...I thought I'd made what I wanted to do clear when I started, but maybe not.

Okay. Essentially, I'm trying to learn what each Excel feature is and what it does. Some of them I can figure out on my own, some I can figure out with help from the Excel tutorials, and some I need to ask for help from you folks for. This is one of those times.

From the top: I'm in the process of going through the Tools menu. In the Tools menu there's a feature called Macro. The Macro feature brings up a sub-menu, and one of the choices on this sub-menu is Visual Basic Editor.

When I click on this VBE choice, it brings up a new window with a grey screen. Displayed on this grey screen are two smaller windows, both of which seem to show a display of what Excel is doing or is programmed to do, explained in programmer language. Or at least, it's phrased in a way that I don't understand, so I assume it's programmer lingo.

Now, under the assumption that the things I want to do in VBE don't require me to know programmer language or to work with those windows, I've been closing them and trying to work my way through the pull-down menus on the VBE screen and their miscellaneous options. On the File pull-down menu, the second choice is Import Files. This is the one I'm currently having trouble with.

Again, my assumption is that this Import Files command is supposed to allow me to call up a file from somewhere else...either another Excel file, or maybe files from other systems like MS Word or Access or whatever...and import it/copy it into my Excel workbook. However, I can't seem to make it actually do this, because every time I try it, I get the error message I listed at the start of this thread.

In trying to investigate what it is that I'm doing wrong, I've gotten several hints or clues that just confuse me all the more. One clue is that when I try to use the Import Files command, by default, the dialog box has me looking for files that have a certain suffix attached to them such as .fls or .vba and so on. This made me think that maybe I can only use this command to import files that have that suffix, but my system doesn't list any files with those suffixes.

Therefore, I guess what I'm asking is how does one use this particular feature? Are some or all of the assumptions I've been making wrong? Is there an extra step or two that I haven't discovered that makes it work?
Or just what?

Please don't be afraid to start from the very most basic elements of this. You can safely assume (If you haven't already) that I know absolutely nothing about this part of the program.

Thanks again for any help!

David
 
Upvote 0
actually, the import file command will allow you to import visual basic modules and visual basic userforms into your current VB project. it is not for importing files from word or access and such. and you will also see in research that you can also export code out of your project to a file to use elsewhere.

judging from your posts you are very new at this, but i commend you for taking on the challenge of learning more about excel and VB. i am self-taught (as many people on this board are I'm sure), and sometimes the best way to teach yourself is to just start exploring.

in answer to your inquiry, do you need to know anything about programming the answer is: yes and no. yes, because VB is a programming language and to really understand VB fully and use it to the fullest, you will need to have an understanding of the programming language. you can learn alot from boards like this and the visual basic help file in excel. on the other hand, you can also record macros in excel, where excel will record your key strokes, and convert them into VB code for you to use as a time-saver. this, however, will only take you so far, and to really use VB to the fullest, as i said, you should have a grasp of the language so you can begin to write your own macros from scratch.

hope this helps you and good luck,
kevin
This message was edited by kskinne on 2002-10-02 17:29
 
Upvote 0
Kevin,

What approach did you go down to start learning the VB Code language??

I have been using Macro's for the last three months and began the method you suggested, which is to start using the Macro Recorder, and then trying to understand the code. This gave me a basic understanding - however, lately I want to do even more advanced things in VB, that seem just beyond me.

I purchased a book called "Excel 2000 VBA" by John Green, but I am really struggling with it.

My main trouble is to try and understand how variants work.

For example:
Dim va products as Variant

What does something like this mean???

Cheers,
Greg
 
Upvote 0
The Variant data type is VBA's default data type. It is used if you do not explicitly declare the data type and you can also declare variables as Variant.

Data stored as a Variant changes type depending on what you do with it. It is useful when you do not know what sort of data your variable will contain. For example the Value property of a Range object my return a string or a number.
 
Upvote 0

Forum statistics

Threads
1,214,523
Messages
6,120,031
Members
448,940
Latest member
mdusw

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top