From 04:00 PM CDT – 08:00 PM CDT (09:00 PM UTC – 01:00 AM UTC) Tuesday, April 16, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Labview to push a button in excel

Solved!
Go to solution

Dear all,

 

I have developed a Labview VI but now I need the VI to activate an excel add-in at a certain moment. The add-in allows to start a measurement with a device which I was not able to control by labview (Lightmeter SEKONIC C-7000), and the measurement should start at a well defined moment. So what I need to do is to push a button into excel to start the measurement, while the VI is running.


Is it possible to interact into excel using labview? After the VI has done some initialization, I would need that it goes into excel and push only one button to start the measurement.....

 

THanks to all for the support....

0 Kudos
Message 1 of 14
(3,812 Views)

Its quite possible to Read from/write into excel using LabVEW, what do you mean by push button in excel or do you mean the excel interaction to be happened after push button is being triggered?

----------------------------------------------------------------------------------------------------------------
Palanivel Thiruvenkadam | பழனிவேல் திருவெங்கடம்
LabVIEW™ Champion |Certified LabVIEW™ Architect |Certified TestStand Developer

Kidlin's Law -If you can write the problem down clearly then the matter is half solved.
-----------------------------------------------------------------------------------------------------------------
0 Kudos
Message 2 of 14
(3,806 Views)

Thanks for your quick answer!

 

In the excel menu, I have an add-on which allows to control the measurement device SEKONIC C-7000.

 

 

What I need to do is to periodically push the button "measurement start" - please see the image attached... Is this possible?

0 Kudos
Message 3 of 14
(3,795 Views)

can you share the excel file instead of image, so that we can try ourself .

and i have never tried this earlier but i think it sholud be possible by invoking excel application.

----------------------------------------------------------------------------------------------------------------
Palanivel Thiruvenkadam | பழனிவேல் திருவெங்கடம்
LabVIEW™ Champion |Certified LabVIEW™ Architect |Certified TestStand Developer

Kidlin's Law -If you can write the problem down clearly then the matter is half solved.
-----------------------------------------------------------------------------------------------------------------
0 Kudos
Message 4 of 14
(3,768 Views)

The excel file is a generic, empty excel sheet.... It will be then filled up with the measurement results...

0 Kudos
Message 5 of 14
(3,765 Views)

The Reason i asked to share your excel is, LabVIEW can able to invoke the inbuilt excel functions, but you have added Measurment start and Measurement abort so need to confirm whether the customized buttons can be accessed via LabVIEW

----------------------------------------------------------------------------------------------------------------
Palanivel Thiruvenkadam | பழனிவேல் திருவெங்கடம்
LabVIEW™ Champion |Certified LabVIEW™ Architect |Certified TestStand Developer

Kidlin's Law -If you can write the problem down clearly then the matter is half solved.
-----------------------------------------------------------------------------------------------------------------
0 Kudos
Message 6 of 14
(3,758 Views)

Here is one generic excel file filled up with some measurement....

However I am afraid that, if you do not have the special add-on for excel to interact with the SEKONIC instrument, you won't see the "measurement start" button

0 Kudos
Message 7 of 14
(3,754 Views)

You are correct -- I do not see Measurement Start.

 

However, you might be able to "have your cake and eat it, too".  Action Buttons in Excel execute a linked Macro when they are pushed.  This suggests that your Workbook (showing the button) has VBA code associated with it that runs a specific named Macro when the button is pushed.  If you examine your Workbook and determine the Macro, you should be able to get LabVIEW to execute it (the easiest way being using the Excel Run Macro function found in the Advanced sub-Palette of the Report Generation Toolkit).

 

Bob Schor

0 Kudos
Message 8 of 14
(3,743 Views)

It looks like a cake too difficult to prepare!!!
I am not able to determine the name of the macro associated with the push button. Any suggestion how to do that?

0 Kudos
Message 9 of 14
(3,695 Views)

Not experienced with Add-ons in Excel but try this.

 

In Excel under the Developer tab, enter design mode then look at the properties for the button.

Also under Devloper see if the Add-In functions can expose anything of use.

 

Edit- Forgot to mention that the code or macro name may be visible via the Visual Basic or Macros selecyions under the Developer tab.

 

-AK2DM

 

 

~~~~~~~~~~~~~~~~~~~~~~~~~~
"It’s the questions that drive us.”
~~~~~~~~~~~~~~~~~~~~~~~~~~
0 Kudos
Message 10 of 14
(3,685 Views)