searching VB6 code - events

I've inherited a ASP/VB6 code base (not my forte... yet) and I'm trying tease it apart to figure out the cause on an error message I'm receiving when running the app.
I've traced it back through an event that is being raised in on of my classes. Is there away in windows I can search the bulk of the code base for where it is being consumed?
Ctrl-F (and selecting Current Project) has not sufficed.
The linux geek in me is saying dump it to a insert distro box and just grep for the sucker. But there's got to be some way in the IDE to do it... right?

But there's got to be some way in the IDE to do it... right?
No. There are some plugins for the IDE, such as the MZ Tools that might help. Otherwise, just use the find tool from the Windows command line. Not nearly as comfortable as using grep, of course.

If you have any new version of VS (2003,5,8) installed, just use the "Find in Files" feature and point it at the VB6 folders.
Other than that, most "notepad" replacements (textpad, notepad+) offer a "Find in Files" as well.

Check out http://www.mztools.com/index.aspx
MZ-Tools 3.0 is a freeware add-in for Visual Basic 6.0, Visual Basic 5.0 and the Visual Basic For Applications editor.
It is essential for anyone still working with VB 6.0
It has an enhanced find feature as well as a calling Procedure similar to .net Find usage.

I have a large legacy code-base in VB6 which needs maintenance from time to time and I have used Microsoft Desktop Search on my local copy to help find variable and method names across the code files.
Also Grep is available for Windows.

Related

Fortran .for file and Microsoft Visual Studio. How Can I Run It?

I'm new in Fortran and I need your help.
I'm a space engineering student and I'm used to code in MATLAB.
Right now I'm writing my MSc thesis and I have to deal with a code written in fortran77 (I'm guessing it by its extension ".for"). The code has already been tested and used in other occasions.
I use Windows 10 as an operating system and I know that sometimes an old code could show problems depending on the system in which it is run (for instance I've heard about the need of running old versions of an operating system through emulators to solve some problems).
I hope I can still use Win10 for the purpose.
So, I have done the following steps (based on what I have found on internet) in order to configure my system:
I have installed the last version of Microsoft Visual Studio Community 2019
I have installed Intel OneApi Basic Toolkit and then Intel OneApi HPC Toolkit (the last one is an add-on that contains the fortran compiler).
It seems that both are well configured/integrated and I think they are working properly.
Now, when I try to open the project from Visual Studio, the .for extension isn't apparently recognized.
So I've tried to open it as a simple file, and in doing so, I can visualize it on VS.
I don't know If It is the right procedure, and I don't know if it works as it should.
How can I prove it?
I try to run it, but nothing seems to happen (no error flag by the way).
I'm totally new in this field, so any "obvious" suggestions will be really appreciated.
I'm open to any tips, even If it is better to change compiler (I've heard about gfortran) or use other kinds of softwares. I would be also grateful if someone could suggest me a beginner useful guide.
Thanks to whoever wants to help me out.

Latex plugin for visual studio 2010

I am looking for a latex plugin for Visual Studio 2010 (preferably free) .
Features it must have:
Code folding
Syntax highlighting
AUTOCOMPLETION
Error Handling
I do not think there is anything available for VS.
As an alternative, I use eclipse with the texlipse plugin. It has all of the features on your list. I do not use windows but ubuntu with eclipse, R, MySQL and Sweave is sufficient to cater for all my data connection, management, manipulation, analytical and reporting needs. All the tools listed are available on Windows with sufficient connectivity to SQLserver with RODBC.
I do not think that there's anything that comes close to what you want to do. But as far as I know, you can - in principle - use Visual Studio with any programming language. If you have enough time to configure it properly.
You can create your own LaTeX-specific language service. Moreover, you would have to create own build rules.
But since I think that is too much work, I recommend TeXnicCenter, a freeware program that has syntax highlight, autocompletion and error handling. I'm not sure about code folding, but I think it does not have this.
Another freeware is LEd (LaTeX Editor), that should have all the features you like, but as far as I remember, I was not that happy with code completion.
A good choice for a LaTeX Editor is TeXWorks. You should try it, since there is no LaTeX support for Visual Studio.
Actually I think MS VS has been developed as a programmers 'editor'. Of course it's much more than just an editor, but editing (la)tex files doesn't fit into this model. So it's better not to waste the time and to try other solutions. I suggest open-source Lyx which is available on Linux and Windows (and AFAIK on Mac OS) platforms and easy to use. Just try it while waiting for other (possibly better) answers.
Visual Studio Code with LaTeX extension is available. It is free of charge as well.

Quick and simple programming language

Is there someone that can suggest me a programming language that allows you to write quickly GUI programs (on windows platform)?
P.S. I am interested on only languages that do not rely on virtual machines and then have a compiler that produces executable code directly on the machine
I would go with AutoIT, it's a very easy to learn windows scripting language with tons of functionalities: http://www.autoitscript.com/autoit3/index.shtml
I'm using it to automate some tasks, but it can do way more than that.
EDIT
Just to make things a little bit clearer for everybody:
You can create new applications using AutoIT and the Aut2Exe compiler provided. The .exe files created are stand-alone, thus require no other files but the files that you might need in your app. Everything is free and the AutoIT scripting language has a BASIC-like syntax.
The GUI that you'll use are standard Windows controls. Among the functionalities you have the possibility to automate keystrokes/mouse movements, call the Windows API and external .dlls, manipulate windows and processes and through user created libraries (called UDFs) you can even acces local databases, manage networking tasks, encryption, archiving and many more.
All I can say is that it's worth take a look and the first app I built with AutoIT was done in roughly 8 hours since I started learning. It took a folder as the source and copied everything in a chosen directory, copying files in folders named as the date when the files were created. So the destination directory would have a series of subfolders like:
11.11.2010
whatever.txt
whatever.png
12.11.2010
archive.zip
and so on. Just 8 hours and got me rid of a lot of effort ordering the files myself.
Any .NET will probably be what you're after.
Start with VB.NET which is now called Visual Basic CCYY eg (Visual Basic 2005, Visual Basic 2008, Visual Basic 2010).
If you want something not using .NET framework, you might as well go back to older version of VB and if you want something compilable that'd be like C++ with their MFC (Microsoft Foundation Class).
You need to give more info on the type of gui and what you're using it for. This could be accomplished with Microsoft Access forms and VBA, or you could make an HTML Application (.hta).
I'll put in a vote for Delphi. You can easily write applications by dragging and dropping components on to a form and doing minimal coding in Pascal, which isn't hard to learn. Later, if you decide to go deeper, you can do pretty much whatever you want. And it compiles to native executable code.
Is an executable bundler, that combines the script with the framework/interpreter, good enough?
If so, you might look at Tcl/Tk or Lua.
http://www.powerbasic.com/
http://www.powerbasic.com/aboutpb.asp
Seems like it has a RAD GUI and of course it's BASIC, plus it compiles down to .exe (as I understand it.) Might be worth checking out.
A 'quick and simple' language will only allow you to do 'quick and simple' things - and for those, having a VM or not wont make much of a difference to you.
For quick and simple & native code, about all I can think of is RealBasic. Its cross platform Windows/Mac/Linux. I find their IDE to be difficult to work with due to its inflexibility and the help system last I looked wasnt that great, but the underlying language isnt bad and does compile to native code. So it might do the trick for you.

Need some pointers/hints in writing a Windows Application

I want to create applications in windows that has complete portability (within windows OSes of course). I have tried using one application written in Visual C++ but I had a real tough time in making it run in other windows OS (like it required .net framework libraries to be installed). This put me on the back foot because I had to copy a set of DLLs from one machine to another and most of the time something works some does not.
And I am TOTAL amateur in writing windows based applications since my technological forte is mostly Java. Where to kick off? (like which tools/IDEs to begin with since I am seriously into writing my own utilities/tools).
I am open to clarification should you guys feel my question is vague/blunt.
Thanks.
Visual C++ should be easily able to do what you want. It sounds like you created a C++/.NET project, which will generate a dependency on the .net libraries. You need to choose a different project type when the wizard starts up.
If you have a paid version of Visual C++, you might try clicking on "MFC Application". A lot of people are down on MFC these days, but it's still a quick way to get a C++ Windows app off the ground. Make sure you choose the option to statically link the MFC libraries, or you'll have another dependency.
MFC isn't included in the free version of Visual C++, so you'll need to go old-school and work directly with the Windows API or find another package such as QT or Wx to link with.
You can use .NET, and if you stay in 2.0, use standard components, it should work fine. You may need to make a few changes to work anywhere, buy very possible.
http://www.mono-project.com/Main_Page
You could either use Visual Studio or the free IDE. Sharp develope or Mono Develope.
If you really want it to work on every version of windows your best bet may be to go the route of full cross-compatibility. Grab the Boost, QT, and possibly ACE libraries and stay away from making OS calls directly. There's a free version of Visual Studio which is probably what you want for an IDE for personal development, if you're doing commercial stuff then get the full version.
Why not use Java. The JVM is on more systems then .NET and now your app will work on any OS not just windows. Plus java is easier for a beginner then C/C++ and less chance that your program will cause BSODs.

What's in your Utility Toolkit? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 9 years ago.
Improve this question
Some of the most efficient engineers, developers and IT professionals I know usually carry around a common "toolkit" of useful programs, add-ins or utilities which help them for day-to-day debugging, developing or designing.
The question is:
What is in your utility toolkit.. What tools couldn't you live without?
Unix Utilities for Windows
Ack
Its like grep, but better, faster, and does more what you want to generally do with large source collections. Written in Perl, and does complete PCRE because of this. Recursive traversal is default, and it intelligently skips files that are unlikely to match using file-type identification to short cut.
( This means it automatically avoids traversing .svn/.hg/.git directories and thus gives massive speedups )
ack "function\s+foo\s*\(" --php
# find the definition of "foo" in all php files
# decendant of the current directory
Total Commander (GREP, FTP, ZIP, it's all here...I'm not even starting on this one)
Notepad++
WinMerge
Python. Seriously. I use it for a lot of small stuff. I also like to use the command line module for creating easy little project specific "shells" that I drop in frequently used queries etc. (show all tables in the projects db, search for stored procedures etc. - yeah, doing a lot of t-sql lately...)
I tend to accompany big c#/t-sql projects with a little python script that extends the cmd.Cmd class to give me a small collection of helpful queries etc. that I can use to poke around in the database.
Also, I often use python to modify input data (often csv files, but any junk will do) into insert statements etc. Or do plausibility tests on that data.
Currently on my thumbdrive (not ALL software):
Notepad++
.NET Reflector
develop (incase I need a quick IDE setup on a different computer)
C# Default Keybindings pdf
Math tables pdf
Boo Primer pdf
MSDN C# & VB Example projects
My Utility toolkit would have:
1.) Hex Editor - XVI32, or any other
2.) Beyond Compare - Comparison of files
3.) Cygwin shell installable complete with perl, gcc,gprof,gcov,gdb and related tools,bash,vim, development/debugging tools
4.) A model makefile for *nix platform
5.) Winzip utility
6.) Source insight or any other good code browsing tool
7.) Ghostscript and GSView
8.) PDF reader
9.) Good quick antivirus tool/exe
-AD
Currently in Thumbdrive\Tools.
"Edit Plus 3" - lightweight editor that I've been using for ages.
"F# - 1.9.6.2" - great for when I need to throw something togheter since it's usable without an IDE, also a great language for many tasks.
"ildasm"
"Sysinternal Procmon" - great for debugging and getting a feel for what the machine is really doing.
I have the following tools on my USB thumd drive:
SysInternals Suite All their great troubleshooting tools in one download, in case I might need a tool that I didn't download before
WireShark setup
VNC binaries (so I can run the viewer directly from USB) and setup
A couple of Portable Apps:
Notepad++ Portable
Putty Portable
FileZilla Portable
7-zip Portable
Sumatra PDF Portable
WinMerge Portable
I use/carry with me:
.Net Reflector
The SysInternals
Suite (particularly Process Explorer, Debug View etc)
Exescope
Orca (Windows Installer)
Depends
Spy++ OleView
Resourcer
Ethereal
IE Dev toolbar
Depends .Net
DocView
LDP (For LDAP)
Just to name a few
I do a full install of cygwin. It gives me 95% of the stuff I need and hard drive space is cheep. It's a lot easier to install everything then get emacs, gcc, gdb, perl, utilitys such as grep and awk, not to mention the servers it comes with like Apache and MySQL if you want to try something out quick.
grep gives you the biggest bang for the buck. You can use it to search on any type code and many forms of data. It is fast, and very powerful. In code it can locate what you're looking for in variables and function names, but also in comments. You can also pipe results into it, and can thus enhance the utility of many tools available on site.
With some clever hints you can easily make grep search for a specific type of an identifier. For instance, "^function_name" will often find in C code a function's definition, because these start with the name of the function at the beginning of the line. If a search pattern gives you too many false matches, you can filter those out, by piping the result through grep -v.
Many years ago I was stranded debugging COBOL programs on a 1970s-era Perkin Elmer machine running OS/32. The machine lacked programming tools, but had an ancient C compiler (so old, it would accept =+ as the original form of the += operator). I ended up writing a rudimentary grep program, which immensely improved my productivity.
Notepad ++
FF + Firebug
Jquery + bunch of plugins
DBManager
Cygwin for error tracking
Google for help
Docs in CHM & Cheatsheets
I always seem to have a bootable Linux Distro on me in SOME form or other. Whether it be the bootable Pen Drive I keep attached to my Keys, or the multitude of LiveCDs I have for various "diagnostics" - I find that if I am in a situation, generally, where I'd need some sort of tools... a reboot into a Live environment provides me with near enough everything I need, and more
PE Explorer
FAR Manager (great file manager especially when working with lots of ftp sites)
FlexHex
Ida
OllyDbg
Emacs. It's my "does list of things" tool, helpful with quick calculations, with mangling configuration files (I work as a network engineer, there is an awful lot of configuration to be done, lots of it bordering on trivial to generate with either small snippets of code or careful use of keyboard macros).
Here's the tools I use to make Sharepoint solutions:
Visual Studio Team Suite 2008
VSTS Database Edition GDR
Sandcastle
DocProject for Sandcastle
.net Reflector
GhostDoc
CSS Vista
Sharepoint Inspector
Sharepoint Explorer
EditPadPro
CodeSmith 2.6 Freeware (with my own .net 3.5 SP1 gui)
Indigo Rose MSI Factory
Wix
Nmap
Wireshark
Fiddler
Adobe Photoshop CS3
Expresso (Regex tool)
VMRCPlus
Powershell 2 CTP
Quest PowerGui for Powershell
IIS Resource Kit
HyperV
Tools I use because you do not have to install, just drop on system and use:
Agent Ransack
7-zip
PSPad
Robocopy : Need to extract from Windows 2003 resource kit (just grab the .exe)
Fast image viewer that has been around for a long time and proven to work.
IrfanView
ide: visual studio / netbeans (zip file!, almost portable)
editor: notepad++ (portable) with monaco font
file comparison: winmerge (portable)
source control: subversion, tortoise
ticket control: redmine
file manager: free commander (portable)
explorer: IE, FF (portable), chrome (portable), iron (chrom without google crap, also portable), qtweb, arora,
FF plugins: firebug, web developer, xmarks
imclient: pidgin
mail client: gmail
download manager: free download manager (portable)
sites: STACKOVERFLOW!!!, gotapi... and google, all the time...
miscelaneous: launchy (can't live without it!)
virtualization: virtual box (I have a machine image for every environment)
office: openoffice (portable)
lamp stack: xammp (portable!)
disk usage: windirstat (portable), scanner (portable)
pdf viewer: foxit (portable), sumatrapdf (portable)
uncompressor: 7-zip portable
M$ sql comparison tool: sql delta
M$ sql management: visual studio sql manager
mysql
mysql management: phpmyadmin, manager provided with mysql
uninstaller utility: revo unistaller (portable)
registry cleaner: ccleaner (portable)
ftp: filezilla (portable)
as you may have noticed, I have a special predilection for portable applications...
gVim
VS2010 Express
Firefox + Firebug
System Rescue CD
A collection of very useful utilities on a Live CD
There are two tools I simply can't work without
PowerShell
GVim (or really any vim style program)
These tools are so heavily ingrained into my daily routine and greatly increase my productivity.
Since I'm often working on different workstations, I've got into the habit of tagging the stuff that I install on delicious:
http://delicious.com/DavidSchmitt/stdsw
wc.exe (from http://unxutils.sourceforge.net/) so handy.
WinRAR and puTTY. That is all I need (i'm assuming internet doesn't count).
.Net Reflector
Powershell
Stackoverflow.Com
I like to program in Python so I have created a portable Python programming environment on a thumbdrive.
Portable Python 1.0
SPE Python editor
wxPython in Action ebook
Python How to Program ebook
Several Python ebooks from O'Reilly
Various tutorials for Python tools I don't use often
Development Tools
Subversion
Tortoise SVN
Useful tools/utils
Virtual Cd Control Tool
Linq Pad
Reflector
Subversion Commit Monitor
BGInfo
SourceGear Diff Merge
Unlocker
MWSnap
Paint.NET
WinRar
FireFox Add Ons
Firebug
ColorZilla
Visual Studio Add Ins
GhostDoc
The utility toolkit or the Tools List that every developer should have described in the following link from Scott Hanselman:
Scott Hanselman's Ultimate Developer and Power Users Tool List for Windows
I use Espresso (I got it with the MacHeist bundle!), and Firebug for coding. I use Photoshop if I need any images.
I manage my projects with The Hit List.

Resources