subasa Posted November 25, 2008 Report Share Posted November 25, 2008 Hi every one I am in a process of converting some C code to LabView. The problem is that my C programming is poor so I am having some problem in translating the C code to LabView. There are no comments available on the program. If any one can help me and convert it for me to LabView, it would be greatly appreciated. Thank you in advance Quote Link to comment
ned Posted November 25, 2008 Report Share Posted November 25, 2008 QUOTE (subasa @ Nov 24 2008, 08:18 AM) Hi every oneI am in a process of converting some C code to LabView. The problem is that my C programming is poor so I am having some problem in translating the C code to LabView. There are no comments available on the program. If any one can help me and convert it for me to LabView, it would be greatly appreciated. Thank you in advance I don't think your problem is your skill in C programming, since the code you posted appears to be VisualBasic. Quote Link to comment
asbo Posted November 25, 2008 Report Share Posted November 25, 2008 Unless I'm really off it, that looks like Visual Basic 6, not C ... I haven't messed with VB6 recently enough to remember exactly what some of those function calls might do, either. Quote Link to comment
subasa Posted November 25, 2008 Author Report Share Posted November 25, 2008 Thanks for the insight. I though it was C but even if it's Visual Basic it doesn't help me much, I am not an expert in programming. I can understand LabView but not C or Visual Basic. So any help would be great. Quote Link to comment
LAVA 1.0 Content Posted November 25, 2008 Report Share Posted November 25, 2008 QUOTE (subasa @ Nov 24 2008, 09:53 AM) Thanks for the insight. I though it was C but even if it's Visual Basic it doesn't help me much, I am not an expert in programming. I can understand LabView but not C or Visual Basic. So any help would be great. I recommend working through the code line by line. There's a alot of overhead in there, so the actual code is not that much. Use Google and online pages for specific information on VB functions. e.g. DIM is simply a declaration/allocation of a variable that will be used later in the code. Begin and End mark a specifc section of code. VB does use objects with their own properties and methods. For example dlg is declared as a UserDialog object. Dim dlg As UserDialog Therefore you will see calls to the properties and method of that object. (' marks a comment line) ' set defaults for dialogdlg.probe_name="probe"'dlg.distance = "60."dlg.phase_min = "0."dlg.phase_max = "-699.5"dlg.fmax="25.00"dlg.probe_name_pec = "probe"dlg.modfile ="3_hexa_structure_PEC"dlg.fmin = "0" You can also pass an object to another function. 'MsgBox datafileDialog dlg As you get going, post specific questions here. Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.