MathGroup Archive 2011

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Problem with Patterns and Integrate

  • To: mathgroup at
  • Subject: [mg123296] Re: Problem with Patterns and Integrate
  • From: A Retey <awnl at>
  • Date: Wed, 30 Nov 2011 07:04:51 -0500 (EST)
  • Delivered-to:
  • References: <> <jb4pfb$gtj$>


> I have recently discovered the power of the command SystemOpen[].
> (Using SystemOpen[] you can make very handy buttons that open, say,
> PDF file *with Acrobat* with, e.g.,
> Button["fileName", SystemOpen["pathToFileName.pdf"],  Background ->
> RGBColor[  0.5, 0.5, 0.7]],
> or Word docs in Word with Button["fileName",
> SystemOpen["pathToFileName.doc"],  Background ->  RGBColor[  0.5,
> 0.5, 0.7]].)
> It is the general version of NotebookOpen[], which opens .nb and .cdf
> files (in Mathematica).

... not exactly,  I think...

> I have just now tested a hypothesis, and found that SystemOpen[]
> opens .nb and .cdf files too, so it would seem that SystemOpen[] is
> all one needs. (?)

NotebookOpen does open .nb and .cdf files within the running Mathematica 
(or player) instance. That is very different from what SystemOpen does: 
SystemOpen uses the operating system to open files -- with whatever the 
system settings will do with them. Usually .nb files are opened by 
mathematica and for most modern OS things are set up such that it will 
reuse a running instance of that program, so it will be opened also in 
the running Mathematica instance. But if you would e.g. have your 
setting such that a .nb file would be opened with a text editor, 
SystemOpen would open it with that, while NotebookOpen would open it 
with the running Mathematica, no matter what the OS settings are. The 
same is of course true if you have multiple versions of Mathematica or 
Players installed: SystemOpen will use the operating systems settings, 
which could be another version of Mathematica or Player than the one 
calling SystemOpen, NotebookOpen will always open within the calling 
Mathematica/Player instance.

> My questions:
> I intend to set up Parallels Desktop or VMware Fusion running on a
> MacBook Pro (lots of RAM and disk), giving me access to Mathematica
> running under Lion, and at the same time a
> never-to-be-ported-to-Mac-Windows-only program (uses filename.odc
> files) installed under Windows 7.
> (i) Can SystemOpen[] reach across the divide - given sufficient path
> details - and launch (with the Windows-only program) a filename.odc
> file in the Windows 7 "partition"?

I don't know the combination of MacOS and Parallels/VMWare well enough, 
but whether that is possible or not has nothing to do with Mathematica: 
If you can set things up that a double click on a .odc file will open it 
within the virtual machine, then I would expect SystemOpen to do exactly 
that, too. So you might want to ask how to set this up in other groups 
than this. If you have your settings up and running and SystemOpen will 
still not work it would become something that people here or at WRI 
could probably help you with...

> (ii) Can Import[] then reach across the divide - given sufficient
> path details - and read in a file newly created in the Windows 7
> "partition" by said Windows-only program?

that depends again mainly on what Parallel Desktop and VMWare offer as 
integration of the virtual machine and the hosting OS. Usually there are 
means to share file systems among the hosting OS and the virtual 
machine, if you write to one of those shared file systems, you can of 
course read from there from both sides. See the documentation of the 
virtualization software you use to learn how that works.



  • Prev by Date: Re: How to simplify ArcSin formula
  • Next by Date: Re: gives different result compared to 1/Diagonal[Normal@A] when A is sparse
  • Previous by thread: Re: Problem with Patterns and Integrate
  • Next by thread: Re: Problem with Patterns and Integrate