Hello Guest it is July 06, 2020, 09:14:39 AM

Author Topic: Running macro and testing them  (Read 13517 times)

0 Members and 1 Guest are viewing this topic.

Offline Hood

*
  •  25,846 25,846
  • Carnoustie, Scotland
    • View Profile
Re: Running macro and testing them
« Reply #50 on: May 11, 2008, 07:33:15 AM »
The thing about VB is you could ask 100 guys to write a macro  to do a certain thing and you would get 100 different macros, some would be more elegant and some would be long winded but all would work, kind of like the difference between mine and Grahams, Grahams is the elegant one just in case you never noticed :D.
 The way I have picked things up is by looking at the VB used in the wizards etc, you can open a wizard and choose edit VB Button from the user menu and clcik on one of the flashing buttons to get the VB within it. Takes a while to see whats going on but eventually you will start to see things.
Hood

Offline Hood

*
  •  25,846 25,846
  • Carnoustie, Scotland
    • View Profile
Re: Running macro and testing them
« Reply #51 on: May 11, 2008, 07:39:45 AM »
Oh I also have a book called VB in a Nutshell, at first it was no use whatsoever as I think it expects you to know VB and is really just a reference manual. When I was doing the toolchange routine for my lathe I was trying to get the PLC to keep indexing the turret until  the correct inputs were seen in Mach, thats when I found the Do Loop statement that I used in mine, Panaceabeachbums and yours.
Hood

Offline CJEls

*
  •  69 69
    • View Profile
Re: Running macro and testing them
« Reply #52 on: May 12, 2008, 01:48:44 AM »
Hood I think you must know the do and do not`s. Like you said you have to have a book to look at what code  you can use.

Offline CJEls

*
  •  69 69
    • View Profile
Re: Running macro and testing them
« Reply #53 on: May 12, 2008, 02:06:54 AM »
Hood I think A guy Like me does not have a clue to what Mach Can and Can not do.Like the OEMTriggers I do not have the Know how to Understand the Functions it does in Mach.The only way I think Is to play With Mach.Now that the Turret is working I have to Set up a hand wheel System for the Machine But because I have used most of the inputs for Lpt 1 and 2 I will have to use  serial Modbus. The reason I want to use that is on the Video`s they show you how to setup A pot for spindle overide and that Can also be used for feedrate overide.I`ll be using the forum a lot as I have two Milling Machines that I want to convert to mach3. Both of the Machines is Old and the controls shot And all of this just so I can Machine Spares for my Other Hobby .I am more a mechanical man Because my Day time Job is to repair Nc machines.To All the Guy`s reading this forum I you Have a problem Some one that Knows what they doing will Help you If they can and with out payment Thanks to Hood And Graham.

CJ