Jump to content

Excel Macro question


Recommended Posts

Hello,

I have an interesting feature request that I hope someone can point me in the right direction.

I am acquiring data using LabVIEW and storing the data into excel. I have an excel template that I am copying and I am populating the data into the excel template. This works great!

My customer wants the excel template to contain a macro that filters the data.

The data filter algorithim would act like a trigger.

The algorithim would look at a user specified channel until it found a trigger value (i.e. number greater than 2). Once it found that value the algorithim would hide the excel rows from time 0 to time x (x being the trigger value).

Is there a library of excel macro's that might have something similar to the functionality described? Would this be difficult to develop an excel macro to do what I described.

Thanks

Dan

Link to comment

OK I think I figured out a cool solution.

I recorded a macro using excel's filter capability.

1. I recorded a macro in excel and named it Trigger

2. Using excel's filter function I selected the column of data I wanted and set up the filter parameters (i.e. number greater than 1).

3. Saved the template with the recorded macro

4. In my LabVIEW program after I copy the template and populate the data I can run the excel macro "Trigger" from LabVIEW.

This looks like it works great.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.