473,320 Members | 1,947 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Visual Studios .net Programming environment

Anyone,
I am creating a C++ program that will read in data from a command line.
However, during building I would like to test it from a file. Is there any
way to do output redirection in Visual Studios.net much like the "<" in
Linux?

~thanks
Addam
Jul 21 '05 #1
5 1356
you can do it by using this syntax:
System.Diagnostics.Debug.WriteLine(string);
-----Original Message-----
Anyone,
I am creating a C++ program that will read in data from a command line.However, during building I would like to test it from a file. Is there anyway to do output redirection in Visual Studios.net much like the "<" inLinux?

~thanks
Addam
.

Jul 21 '05 #2
you can do it by using this syntax:
System.Diagnostics.Debug.WriteLine(string);
-----Original Message-----
Anyone,
I am creating a C++ program that will read in data from a command line.However, during building I would like to test it from a file. Is there anyway to do output redirection in Visual Studios.net much like the "<" inLinux?

~thanks
Addam
.

Jul 21 '05 #3
I am sry I just re-read my post. I did not mean to say output redirection I
meant to say input redirection. sry the user will be using a command line
to enter in data. so I am using cin. is there a way to simulate the
command prompt and in its place put a file??

~thanks
Addam
"iman" <im*******@yahoo.com> wrote in message
news:01****************************@phx.gbl...
you can do it by using this syntax:
System.Diagnostics.Debug.WriteLine(string);
-----Original Message-----
Anyone,
I am creating a C++ program that will read in data

from a command line.
However, during building I would like to test it from a

file. Is there any
way to do output redirection in Visual Studios.net much

like the "<" in
Linux?

~thanks
Addam
.

Jul 21 '05 #4
When calling your program, you can use myprog.exe < myfile.txt and that will
be sent into standard in.
-mike
MVP

"Addam Webber" <re***********@excite.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
Anyone,
I am creating a C++ program that will read in data from a command line. However, during building I would like to test it from a file. Is there any way to do output redirection in Visual Studios.net much like the "<" in
Linux?

~thanks
Addam

Jul 21 '05 #5
Mike,
I appreciate the help. However, I want to debug the application.
Therefore I will not be running it from it's final exe form. Does .net
offer any kind of input redirection during debug time??

~thank you
Addam
"Michael Giagnocavo [MVP]" <mg*******@Atrevido.net> wrote in message
news:OR*************@TK2MSFTNGP10.phx.gbl...
When calling your program, you can use myprog.exe < myfile.txt and that will be sent into standard in.
-mike
MVP

"Addam Webber" <re***********@excite.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
Anyone,
I am creating a C++ program that will read in data from a command

line.
However, during building I would like to test it from a file. Is there

any
way to do output redirection in Visual Studios.net much like the "<" in
Linux?

~thanks
Addam



Jul 21 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Ken Janke | last post by:
I am trying to understand something about using visual studios .net 2003. I am trying to find out about the headers in visual c++ .net 2003. Do they have to be without .h at the end? Or should I...
5
by: Addam Webber | last post by:
Anyone, I am creating a C++ program that will read in data from a command line. However, during building I would like to test it from a file. Is there any way to do output redirection in Visual...
5
by: John Tenney | last post by:
If I have a windows form (System.Windows.Forms.Form) open and I push the pin on the toolbox to keep the docked window open, Visual Studios 2003 pegs the processor and basically hangs my computer. I...
1
by: Steve Kershaw | last post by:
This is the oddest problem! When I do a copy (<ctl> C) and paste (<ctl> P) in my C# code I sometimes find that Visual Studios has deleted the first few letters of several consecutive lines...
10
by: yansong1990 | last post by:
well ok, im pretty new to c++, i have -a lot- of exp in programming in VBA (visual basic for app) for excel to make macros so i picked up a new course for computing which handles c++ only, i...
12
by: Udhay | last post by:
I am new to vc++. Whether Visual Studio is a platform independent? Is there any chance of using my application created by vc in MAC or Linux. udhay
4
by: Keith Russell | last post by:
Hi, everyone. I have done a variety of programming in the past in several (mostly older) languages. I also worked for a couple of years about 5 years ago programming in Visual C 6. I have...
0
by: jpturn99 | last post by:
Hello The high school I teach at has recently upgraded to Visual Studios 2005. I am trying to run a simple "hello world" project in C++. I have properly followed all of the steps to setting up a...
1
by: =?Utf-8?B?RnJpZWRp?= | last post by:
Hi everybody, I am studying VB 2005 express and think, very interesting projects can be developed with it. Before I step over and buy the VB full version, can anybody tell me the difference of...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.