Page 1 of 1

Move Cursor to 0,0

Posted: 20 Feb 2014 16:50
by einstein1969
Hi to all,

I need to find the faster method for move the cursor in position 0,0

I have seen many tools that work for this (like Aacini's utility) and the powershell method and i think tha ANSI.SYS can do that, I'm right?

I search for the faster "Bulk" method.

Preferred in the order: internal dos command, external but OS native (exe,com,dll), wsh (how to use the dynawrapper? or other) / mshta.

For whs and mshta or powershell is possible create an method that run continous and wait for a signal?

einstein1969

Re: Move Cursor to 0,0

Posted: 21 Feb 2014 00:51
by carlos
this is cursor0.exe
this left the cursor in position x:0 y:0 that is the same effect of cls without fill the console with space characters.

cursor0.c (for tiny c)

Code: Select all

#include <windows.h>
#include <stdlib.h>

int main()
{
    HANDLE hOut = GetStdHandle(STD_OUTPUT_HANDLE);
    if ((hOut != NULL) && (hOut != INVALID_HANDLE_VALUE)) {
        COORD coord = {X: 0, Y: 0};
        SetConsoleCursorPosition(hOut, coord);
    }
    return 0;
}
For execute:

Code: Select all

tcc -run cursor0.c
Edit: For a windows 10 solution using escape sequences: viewtopic.php?f=3&t=9506#p61583

Re: Move Cursor to 0,0

Posted: 25 Feb 2014 12:58
by miskox
This might help:

viewtopic.php?p=27602#p27602

Saso