LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

MSComDlg.ICommonDialog Problem with Windows 64-bit system

Hi all!

 

I try to use the common Windows dialog box for saving files. For this I'm using the ActiveX-class "MSComDlg.ICommonDialog" with the propertynode input "Filter" for the file types. It's the standard "SaveAsType.vi" (somewhere in the forum).

Everything works fine on a 32-bit Windows system. But when I run the code on a 64-bit system I can not save my file with the last file-extension in the box field. I always get a error-message: "The file name is invalid!" This happens only when the last box-element is selected. All other run normal.

 

So for example:

If may box array is

 

Matlab Files (*.mat)|*.mat

Text Files (*.txt)|*.txt

Excel Files (*.xls)|*.xls

 

and I select to save as *.xls and write as filename "Hello" in, I get on the 64-bit machine the error:

"Hello

The file name is invalid"

 

When I change the order of the box array *.xls will go but the new last element will produce this error.

 

So, can someone help me?

 

Kind regards,

llpauli

 

P.S. I'm using Win 7 64bit with labview 9 32bit. exe tested on win7 64 bit and win xp 32 bit.

0 Kudos
Message 1 of 14
(15,478 Views)

Hi Ilpauli

 

can you pleas attach the SaveAsType.vi?

I'm unable to find it "somewhere in the forum"

Regards
DianaS
0 Kudos
Message 2 of 14
(15,464 Views)

Hi

 

find attached the SaveAsType.vi!

 

So when you build the exe and call it in win 7 64bit it will work for all extensions fine expect for the last one in the list:  "Calibration Files".

 

Greetings 😉

0 Kudos
Message 3 of 14
(15,458 Views)

Hi

 

I testet it here on Win 64bit but the ActiveX control is not supportet and so the Common Dialog Class not found.

I tried to register the comdlg32.ocx but this did also not work.

Which ocx are you using? Are you able to register it?

Can you attach it?

Regards
DianaS
0 Kudos
Message 4 of 14
(15,442 Views)

Hi,

 

On which Windows 64-bit System have you test it? XP, Vista or 7?

I haven't registered anything additional - it works with the standard setting from my Win7 installation. It's Win7 Professional. Could it be possible that it is working only with the professional version?

My comdlg32.ocx file from C:\Windows\SysWOW64 is attached.

 

Greetings

llpauli

0 Kudos
Message 5 of 14
(15,435 Views)

Hi,

 

comdlg32.ocx will be installed when you install the full version of LabView Runtime engine. It's in the Datasocket package.

 

Regards,

llpauli

0 Kudos
Message 6 of 14
(15,413 Views)

Hi

 

Im using win 7 64bit. I'm able to register the comdlg32.ocx now but can't use it in labview. There are always error messages.

Which one do you use (see screenshots)

Regards
DianaS
Download All
0 Kudos
Message 7 of 14
(15,407 Views)

Hi!

 

I use the Library: "Microsoft Common Dialog Control 6.0 Version 1.2" and from there the object "CommonDialog (MSComDlg.CommonDialog.1)".

 

The last days it works fine, but now when I directly select the class I also get an error "97".

 

But my posted VI is still runing.

 

Regards

llpauli

 

0 Kudos
Message 8 of 14
(15,398 Views)

Hi

 

yes error 97 this is also what I see.

Regards
DianaS
0 Kudos
Message 9 of 14
(15,384 Views)

Here is one more example: http://zone.ni.com/devzone/cda/epd/p/id/818

It says:

NOTE: You must have one of the following programs installed to run this example:

  • Microsoft Office 2000 Developer Edition
  • Microsoft Visual Basic 6.0
  • Microsoft Visual Studio

Do you have one of them installed?

Regards
DianaS
0 Kudos
Message 10 of 14
(15,382 Views)