|
-
May 15th, 2001, 11:46 AM
#1
Source Code
Is there a way to view the source code VB generates for me when developing my VB Application?
-
May 15th, 2001, 11:54 AM
#2
Re: Source Code
May be I did not understand the question, but the source code is exactly the code you are writing in your forms and modules. If you want to see your executable, you can do it any hex editor and find the hex code of your compiled app.
Iouri Boutchkine
[email protected]
-
May 15th, 2001, 11:55 AM
#3
Re: Source Code
I'm looking for all of the behind-the-scenes code for the controls, etc.
-
May 15th, 2001, 07:32 PM
#4
Re: Source Code
I don't think you can get an vb code from the controls, as some of them are not programmed in vb, but if you know assembly, then you can compile the program and run it in visual C++, which all you to view the assembly code. Sometime, I do use this method to find out how VB perform some function.
HTH
cksiow
http://vblib.virtualave.net - share our codes
-
May 16th, 2001, 07:28 AM
#5
Re: Source Code
I think he means he wants the code to align the create the controls, load them, align them, initialize etc.
In C you will have to do that yourself, in VB it is done for you. The only 'readable' place you can find this is in the .frm file.
Try it, rename a form to txt, open it in notepad, and tada, all your controls, initial values etc.
I use this technique to easely copy a form. Make a copy in explorer, edit it, change the name property and a bit further down the vb_attribute name and you can load the form in your project.
Tom Cannaerts
[email protected]
Programming today is a race between software engineers striving to build bigger and better idot-proof programs, and the universe trying to produce bigger and better idiots. So far, the universe is winning -- Rich Cook
-
May 16th, 2001, 07:43 AM
#6
Re: Source Code
What language is it written in? I don't know what the Begin blocks are doing and the attribute statement. Do you know?
-
May 16th, 2001, 07:57 AM
#7
Re: Source Code
I don't know what language it is, if it even is one.
The begin/end blocks define an object, one you will always have in a form is the
Begin VB.Form formName
This defines an object of the type Form, located in the class VB. If you've ever worked with com, you should notice the dll.component notation.
Actually, now i'm looking at it, this ain't so hard.
You begin an object, everything that follows are properties of that object. You should see the caption, borderstyle ect.
If the object can contain objects itself (read as controls on a form, or picturebox or whatever can serve as a container), there can be other Begin/end block withing the first.
After all the objects (so the form is completely built) come the attributes.
The Attributes are extra information used by the VB compiler.
After the attributes, the code follows, this is the part you can actually see in your codepane.
If you open a project file in notepad, you will see some other stuff, but it's quite readable, except for the objects (used components) and the refferences, which are displayed as their GUID.
Tom Cannaerts
[email protected]
Programming today is a race between software engineers striving to build bigger and better idot-proof programs, and the universe trying to produce bigger and better idiots. So far, the universe is winning -- Rich Cook
-
May 16th, 2001, 08:50 AM
#8
Re: Source Code
Great. Thanks so very much!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|