Accessing a windows share with groovy - groovy

Hey i'm trying to access a windows share to get a given XML file that I need to do some work on.
I'm trying to do this with a groovy script that will run in soapui, but i can't see how I can access the share without adding something like JCIFS or another external lib.
Is there anyway to access the share without external libs and if not could somebody point me to an example of how you access the share.

Okay I have tried with the jcifs and that works, but would not be the best.
But we can access with just a normal windows share access.
So if i use: " \\\\<ip>\\c\$\\folder" i can get to my files.

Related

Does Ghostscript absolutely need root access on Linux?

I made a program trying to see how many color pages are on an uploaded PDF file, using Ghostscript. Now, it worked perfectly on my local environment, but I can't put the site online, as the web hosting service I use tells me that any application that needs root access cannot be installed on the server. Is it the case with Ghostscript, and if so, is there any other way I can use it ?
I'm new to all this, and I know now I should have asked the web hosting service first thing, but I'd really like to not have to put my work in the bin over this !
No Ghostscript doesn't require root privileges and I've no idea why they would claim it does. Also, I would strongly urge you to review the AGPL license.

How to access code of my Azure website?

I dropped my hard drive which contained all my code and now it won't plug in to my computer. I need the code to my Azure website which I deployed earlier asap. Is there a way for me to access this code?
Yes, there are multiple ways.
Using the deployment credentials you can connect via FTP and download the files.
Using Git source control you can add your azure web app as a remote reference and clone it locally.
It's not going to be pretty but once you get your binaries via FTP you can use a Reflector library to decompile your binaries and generate source code from them.
It won't be as good as the original source code, but it'll be functionally equivalent and will make it easier for you get back to where you were.

Using DirectXTK to save screenshots in Windows Store app (Metro)

I'm working on a C++ Windows Store DirectX app and I'm trying to save screenshots to disk every so often.
I am using the DirectX Tool Kit (DirectXTK) and the function SaveDDSTextureToFile which returns an HRESULT.
The problem is that the returned HRESULT is always:
E_ACCESSDENIED General access denied error.
I assume this is some permissions/capabilities thing (it being a windows store app) but I can't find what I need to ask for permission for to be able to save files to disk.
The DirectX ToolKit says it is for Windows store applications as well as desktop applications but I can't find any information on their codeplex either.
Does anyone know what I need to have permission to do for this to work?
Thanks for your time.
Windows Store apps are sandboxed and have fewer permissions than desktop apps, especially when it comes to file access. By default, apps only have access to write to the local storage directory, which isn't easily accessible from the shell. If you want to save to the Pictures or Documents library, you will need to specify this access in the package manifest. Additionally, you will need to use the WinRT file APIs to write the DDS files. To do this, use SaveDDSTextureToMemory, then write the resulting raw DDS data to the StorageFile. Check out the File access sample for more info on the WinRT APIs involved in writing this data as a file.
I've managed to find a way to do it. Basically as MooseBoys says you cannot save to anywhere because the app is sandboxed.
You can however save to the TempState folder of your apps package in AppData, which is all I need because I'm using this feature for debugging.
So the line I call is:
DirectX::SaveWICTextureToFile(deviceContext, texture2D, GUID_ContainerFormatPng, L"C:\\Users\\USERNAME\\AppData\\Local\\Packages\\PACKAGENAME\\TempState\\test.png");
And this works great.

How do you access an external lotusscript file

I'm reviewing a Lotus Notes application in my company. In some agent code, I saw lines like: Use "Q:\external\exfile.lss". I cannot find these exfile.lss inside the database, so I assume that it is located somewhere in the server. How do you make an external lotusscript file accessible to a LN database? Thanks in advance!
When you use the Use syntax:
Use "Q:\external\exfile.lss"
the compiler will bring in that file content and compile it to object code. If you want to see the source you will need access to the original external file.
This technique can be used to protect access to the source code. Also to centralise the code as a means of source code management.
It is probably not
Use "Q:something.lss"
what you saw, but
%Include "Q:something.lss"
inside a script library.
Indeed it's used to hide the implementation of proprietary code. Which means that, if you don't have the file, you can't see nor change the implementation.

Win32: HtmlHelp doesn't work from a network share. What's the alternative?

Since 2005, when Microsoft prevented HtmlHelp functioning off a network share, e.g.:
\\appserver\tos\PointScanner.exe
\\appserver\tos\PointScanner.chm
What are we supposed to do instead?
(Given that the application is not installed locally.)
To rephrase: What is Microsoft's intended, supported, out-of-the-box, help solution?
You can allow access via the Registry setting described here:
http://support.microsoft.com/kb/896054/
If you don't want to open any security vulnerabilities by modifying Registry settings your application could also create a local copy of the .chm file, e.g. in the users temp folder (%TMP%) and open the help from there. You can remove the file again when your application exits (in case you don't want to leave anything behind on the user's workstation)
I started with the registry change mentioned by divo. Eventually I moved from network folder based chm files to actual "html help". This was easy for me since I use RoboHelp which can generate either format from the same source code.

Resources