writing to MS Office 2016 Excel file in Windows 10

Christie Widget Designer Version 6 - Q&A

Moderator: Moderator Group

Forum rules
When asking make sure to include the operating system and the revision of Widget Designer you are using.

writing to MS Office 2016 Excel file in Windows 10

Postby chrisr » Wed Oct 11, 2017 3:18 pm

All,
Just curious if anyone has been successful with the above mix. I have tried writing to MS Office 2016 Excel file, I have saved the file as a .xls, and I do have .net framework on the machine. There are a couple of things that are kind of on my radar. So I can not find a way like with earlier releases of Office, to select complete install and custom. Then be able to choose to instal Interop assemblies.

Anyways, just tossing it out there. Seeing if anyone has been successful with Windows 10 and Microsoft Office 2016 Excel.

Here is a bit from Dennis from a couple years back

http://forum.coolux.de/viewtopic.php?f=80&t=3016&p=8770&hilit=xls#p9481

Thanks!!
Thank You

ChrisR
SurfacePro3 - 2GHz i5 - 4GB ram - Windows 10 Pro - WD Pro 4.7 Rev2500 and WD 6 Rev6322
Sager Laptop - Intel 2.4GHz i7 3630QM - 16GB ram - Windows 7 Pro Svc Pack1 - Offline Manager V5.1_Rev13378 & V6_Rev15101
chrisr
 
Posts: 127
Joined: Tue Jan 26, 2016 10:50 pm

Re: writing to MS Office 2016 Excel file in Windows 10

Postby Benni_M » Wed Oct 11, 2017 4:10 pm

The Exel input/output is a little bit strange in wd.
i don't know if it works correctly in the V6 or with office 2016.
I always used office 2010 and the V4.7.

But at least it is easier to write a server with ADODB implementation to open .xls files and send datas from and to the WD.
and another good point is that you don't need office ;-)

Best,
Benni
Benni_M
 
Posts: 103
Joined: Thu Apr 12, 2012 3:45 pm

Re: writing to MS Office 2016 Excel file in Windows 10

Postby chrisr » Wed Oct 11, 2017 6:06 pm

Benni, thanks so much for the insight. So after speaking with my boss, we are going down the path of writing a .txt document. My thought is lets write it as a CSV this way I can import the csv into any version of excel or google sheets etc and organize at that point. So the only thing I'm working on now is figuring out how to do a carriage return / line feed after each data entry that excel / google sheets recognizes as a new line within the CSV data.

Thanks again for the help Benni

Chris
Thank You

ChrisR
SurfacePro3 - 2GHz i5 - 4GB ram - Windows 10 Pro - WD Pro 4.7 Rev2500 and WD 6 Rev6322
Sager Laptop - Intel 2.4GHz i7 3630QM - 16GB ram - Windows 7 Pro Svc Pack1 - Offline Manager V5.1_Rev13378 & V6_Rev15101
chrisr
 
Posts: 127
Joined: Tue Jan 26, 2016 10:50 pm

Re: writing to MS Office 2016 Excel file in Windows 10

Postby Benni_M » Thu Oct 12, 2017 8:44 am

Hi Chris,

add a label to your widget.
the content should be:
\n

add the label at the end of your variable.
append it to the file.

cheers,
Benni

here is another topic from the V4.7 but it's kindly the same.
http://forum.coolux.de/viewtopic.php?f=80&t=4367
Benni_M
 
Posts: 103
Joined: Thu Apr 12, 2012 3:45 pm

Re: writing to MS Office 2016 Excel file in Windows 10

Postby chrisr » Thu Oct 12, 2017 5:23 pm

Benni-
I have definitely tried all those iterations. \n, \r\n, "\r\n", (\r\n) etc etc. I couldnt get anything to sing. So I have another work around, I'll just do a find / Replace text in NotePad++, I can find my \r and replace with a CRLF that the document sees. Once that is done, when I import into a spreadsheet program it sings nicely... its an added step but I was able to move on. I can revisit this later to clean up...

Here is a screen shot of the string

Image
Thank You

ChrisR
SurfacePro3 - 2GHz i5 - 4GB ram - Windows 10 Pro - WD Pro 4.7 Rev2500 and WD 6 Rev6322
Sager Laptop - Intel 2.4GHz i7 3630QM - 16GB ram - Windows 7 Pro Svc Pack1 - Offline Manager V5.1_Rev13378 & V6_Rev15101
chrisr
 
Posts: 127
Joined: Tue Jan 26, 2016 10:50 pm

Re: writing to MS Office 2016 Excel file in Windows 10

Postby Benni_M » Thu Oct 12, 2017 5:49 pm

Hello Chris,

sorry they changed the command that \n don't work animore.

The New command is [CR]

Testline [CR].png
You do not have the required permissions to view the files attached to this post.
Benni_M
 
Posts: 103
Joined: Thu Apr 12, 2012 3:45 pm

Re: writing to MS Office 2016 Excel file in Windows 10

Postby chrisr » Fri Oct 13, 2017 8:49 pm

Benni... You're a rockstar. That worked perfect. Man, I tried so many iterations.... oh well. Thanks so much!! Below, when you open the file in Notepad++ it sees a line feed. Which means when you open this in Excel, and tell it to use the space as a comma, it puts everything neatly into a cell, and then starts a new row after each OSC packet recieved.

Image
Thank You

ChrisR
SurfacePro3 - 2GHz i5 - 4GB ram - Windows 10 Pro - WD Pro 4.7 Rev2500 and WD 6 Rev6322
Sager Laptop - Intel 2.4GHz i7 3630QM - 16GB ram - Windows 7 Pro Svc Pack1 - Offline Manager V5.1_Rev13378 & V6_Rev15101
chrisr
 
Posts: 127
Joined: Tue Jan 26, 2016 10:50 pm


Return to Widget Designer V6

Who is online

Users browsing this forum: No registered users and 2 guests