c# 问题? 我想在控制台上,利用 ConsoleKey的一些属性; 控制光标的移动 如按: 向上键,光标向上 向下键,光标向下等等; 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 ConsoleKey 枚举型,指定控制台上的标准键。LeftArrow 向左键UpArrow 向上键RightArrow 向右键DownArrow 向下键 光标控制CursorLeft CursorSize CursorTop CursorVisible 我的博客 欢迎交流 http://www.ideaext.com 这个意思?using System;using System.Collections.Generic;using System.Text;namespace ConsoleApplication1{ class Program { static void Main(string[] args) { Console.WriteLine("123123123123123123"); Console.WriteLine("123123123123123123"); Console.WriteLine("123123123123123123"); Console.WriteLine("123123123123123123"); Console.WriteLine("123123123123123123"); Console.WriteLine("123123123123123123"); Console.WriteLine("123123123123123123"); Console.WriteLine("123123123123123123"); Console.WriteLine("123123123123123123"); while (true) { switch (Console.ReadKey(true).Key) { case ConsoleKey.UpArrow: if(Console.CursorTop!=0) Console.CursorTop--; break; case ConsoleKey.DownArrow: Console.CursorTop++; break; case ConsoleKey.LeftArrow: if (Console.CursorLeft != 0) Console.CursorLeft--; break; case ConsoleKey.RightArrow: Console.CursorLeft++; break; } } } }} 为什么保存文件的时候会加上程序的路径(不保存到绝对路径) 用IE,firefox看网页 遍历comboBox中value的问题 安装项目类型(.vcproj)的应用程序,提示程序为安装 C#读取串口条码扫描枪出现问题 关于网页的命名问题 生成可执行文件 请教怎么样在C#中调用MFC自动化组件中有VARIANT*为参数的函数. 哪有免费发短信的软件下载?至少有三个月时间是免费的哦 送分来了!请问C#如何开发Visio插件哦 讨论,做的TCP通讯程序当一个服务器负荷满足不了时,再加一个服务器程序应如何处理? 关于数据访问层的数据检查
LeftArrow 向左键
UpArrow 向上键
RightArrow 向右键
DownArrow 向下键
光标控制
CursorLeft
CursorSize
CursorTop
CursorVisible
我的博客 欢迎交流 http://www.ideaext.com
using System.Collections.Generic;
using System.Text;namespace ConsoleApplication1
{
class Program
{
static void Main(string[] args)
{ Console.WriteLine("123123123123123123");
Console.WriteLine("123123123123123123");
Console.WriteLine("123123123123123123");
Console.WriteLine("123123123123123123");
Console.WriteLine("123123123123123123");
Console.WriteLine("123123123123123123");
Console.WriteLine("123123123123123123");
Console.WriteLine("123123123123123123");
Console.WriteLine("123123123123123123");
while (true)
{
switch (Console.ReadKey(true).Key)
{
case ConsoleKey.UpArrow:
if(Console.CursorTop!=0) Console.CursorTop--;
break;
case ConsoleKey.DownArrow:
Console.CursorTop++;
break;
case ConsoleKey.LeftArrow:
if (Console.CursorLeft != 0) Console.CursorLeft--;
break;
case ConsoleKey.RightArrow:
Console.CursorLeft++;
break;
}
}
}
}
}