WIndows XP SP1 copy command in terminal not working - move

C:\WINDOWS\system32>copy c:\Inetpub\wwwroot\accesschk.exe c:\Documents and Settings\
copy c:\Inetpub\wwwroot\accesschk.exe c:\Documents and Settings\
The syntax of the command is incorrect.
This has become very annoying as I see examples, and I see videos of yes, this is indeed the correct syntax. Im in the OSCP labs trying to move a file. The OS is Windows XP SP1. Can someone just tell me im a fool or I am going crazy.

Related

Compiled Visual Basic Application gets Runtime Error 52 in Windows 8

The application that I compiled via Visual Basic 6 can run on my Windows XP computer. But when I execute the same executable on my other computer that runs Windows 8, I always get Runtime Error 52-Bad File name or number as soon as I launch it. I can't run the program even if there is no "Shell command" in that program which leads to a "Bad file name" error.
I used "Package and Deployment wizard" for the packaging process.
And also I registered the needed DLL's on the Windows 8 PC manually via the regsvr32 command line utility.
I also cleaned the whole registry via a registry cleaner (Wise Registry Cleaner). I used compatibility mode for Windows XP but nothing solved the problem.
Additional informations:
XP Version - SP 2
Windows 8 Version-8.1
VB - VB 6.0
Assuming that your code is
If Dir("C:/file.txt") = "" Then...
Change it to a backslash ("\")
After some research I found the answer for the problem. That was not a problem in the coding; it was ALL about windows 8 compatibility.
Go to the “Compatibility” tab of the properties window of the file and select “Windows XP SP2” under the “Compatibility mode”. That’s all
Windows 8 no longer allows you to write programmatically in the root of drive C:\ (and in many others 'system' folders like Program Files, Windows, System32, ...).
Try to use a sub-folder.

VB6 Legacy Code can't "Call Shell"

I am working on some legacy VB6 code and I am having my program break with this message:
and it then highlights this code:
I know that the specified locations exist per these screenshots:
I am running this Visual Studio 6.0 on a 64-bit Windows 7 machine. How can I make the program see shell?
command.com does not exist on 64 bit windows.
Try using C:\Windows\SysWOW64\cmd.exe instead. C:\Windows\SysWOW64 is a folder giving you backwards compatibility stuff for 32 bit.
But see the comment below (taken from Euro Micelli).
Really you should use %SYSTEMROOT\System32\cmd.exe instead. First, Windows is not always installed in C:\Windows; you should let the system figure that out. Second, using System32 is always correct for a 32-bit application: when running on Win32, it is the correct folder; when running on Win64, Windows will map %SYSTEMROOT%\System32 to %SYSTEMROOT%\SysWOW64
I use vb6 and windows 7.
I've done the same thing as you but I put the dos command in a bat file.
Login.bat
NET USE W: \\10.48.10.8\e$
Then in the code
Shell ("c:\login.bat")
The vb command is not correct for the OS that you are running. You need to check that that drive is not already mapped, and remove the command.com /c from the command that you are trying to execute.

Launching 32 bit executable from command prompt in Win 7 64 bit OS

I am working on Windows 7 64 bit and have a wierd problem. I installed installAnywhere(a 32 bit application) in c:\Programs(x86) since I did not want to install it in the regular "c:\Program Files(x86)" to avoid the hassles of space in directory.
When I attempted to call the installanywhere from command prompt using the syntax:
cmd /c "c:\Programs(x86)\InstallAnywhereEnterprise\build\build.exe" ...
I get the error "c:\Programs" is not a command. The reason being it is attempting to look to installAnywhere in c:\Programs ignoring the (x86) part.
I did some investigation on launching 32 bit programs vs 64 bit programs from command prompt and tried using %windir%\SysWow64\cmd.exe. When I used "%windir%\SysWow64\cmd.exe",
the %programfiles% correctly points to "c:\Programs Files(x86)" but launching the command I mentioned just gives the same error. The FileSystemRedirector of Windows still
keeps pointing to c:\Programs. I reinstalled InstallAnywhere in the default location "C:\Programs Files(x86)" but I dont know why it does not work with "C:\Programs(x86)".
Does anyone know of a workaround?
Escape the parentheses.
"C:\Programs^(x86)\..."
Why exactly are you not ok with putting it in the regular Program Files directory? Space shouldn't be an issue.

what's your utf-8 console setting when programming Google Go under Windows

We know google's Go default is UTF-8.
I found in my Windows XP. It can not display correct about the UTF-8.
The following code display in wrong.
package main
func main() {
println("中文")
}
I've googled. It said use another font + reg + chcp 65001.
But, I failed.
I've tried cmd and powershell v1 (it is the only provide version under XP).
Both can NOT display well.
Install MSYS
Download mintty and put mintty.exe in c:\MinGW\msys\1.0\bin
Adjust MinGW Shell icon, set target as C:\MinGW\msys\1.0\msys.bat -mintty, then click the icon
Menu->Option->Text->Font, Locale,Character set(UTF-8)
Download go Windows 386
cd /c/go/src ; mkdir ; test your code here.
BTW, setting vim with utf-8
I will try this the next time I'm at a Windows XP machine. I develop mostly on Win 7 and CentOS. One thought, cmd.exe is awfully old on Windows XP. I wonder if it would work better if run from PowerShell. Also, in the last couple days I've switched to using MSys on Windows so that I can take advantage of unified makefiles on Linux and Windows. I'll post an update if I get the command to work on XP or 7.

How to make tasklist.exe run on windows 2000

Can someone please tell me how to make tasklist.exe file run on Windows 2000. I downloaded the file from net & placed under the system32 folder. However when I tried to execute the file it prompted me a message "ERROR:the target system must be running Windows XP or above"
So can someone please tell me how to run this on windows 2000? I badly need this, as I am doing a batch script to find out the foreground processes running in my windows 2000 machine.
Appreciate your help.
I looked but couldn't find a version for Windows 2000. But I did find this article on using an alternative program.
The original tasklist.exe will not work in stock Windows 2000 because it's looking for APIs which don't exist there. You can use a modified version created blackwingcat:
http://blog.livedoor.jp/blackwingcat/archives/1372175.html
Just download and unpack taskcmds.cab.

Resources