Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Compiling myprogram.cs
Message
From
29/12/2006 13:15:49
 
 
To
29/12/2006 13:09:34
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
General information
Forum:
ASP.NET
Category:
Deployments
Miscellaneous
Thread ID:
01180878
Message ID:
01180929
Views:
11
So I take it that C# can connect to VFP8.0 tables? Which is good new for me.

Thank you.


>Then use Ctrl+F5 otherwise console applications do not wait after outputting their results. ie:
>
>
>// Add these to top
>using System.Data;
>using System.Data.OleDb;
>
>
>  static void Main()
>  {
>  string strConn = @"Provider=VFPOLEDB;Data source=
>C:\Program Files\Microsoft Visual FoxPro 9\Samples\Data\testdata.dbc;";
>
>  string strQuery = "select * from customer where country = 'USA'";
>
>  OleDbConnection cn = new OleDbConnection(strConn);
>  cn.Open();
>
>   OleDbCommand cmd = new OleDbCommand(strQuery,cn);
>   OleDbDataReader rdr = cmd.ExecuteReader();
>
>  while (rdr.Read())
>   {
>    Console.WriteLine("{0}, {1}, {2}",
>      rdr["cust_id"],
>      rdr["Company"],
>      rdr["Contact"]);
>   }
>   rdr.Close();
>   cn.Close();
>  }
>
>Cetin
>
>
>>Hi Cetin.
>>I pressed F5 and it did "blink" like it was doing something, but no out put.
>>I'm trying to connect to a foxpro table and updating a row.
>>
>>And I even put
>>
>>
>>.
>>.
>>.
>>}
>>Console.WriteLine("Hello .NET World");
>>{
>>
>>
>>in my code to see if I can get any response... but no response yet.
>>
>>
>>>>>>greetings.
>>>>>>
>>>>>>Is there a way to compile a .NET program in the .NET interface (is the right term) rather then doing "csc MyProgram.cs" on the command line?
>>>>>>
>>>>>>TIA.
>>>>>
>>>>>Sam,
>>>>>
>>>>>Do you have Visual Studio .NET or Visual C# Express installed on your PC?
>>>>
>>>>
>>>>I'm at home and all I have right now is Express.
>>>>I'm expecting the 2005 Professional "Academic" edition next week.
>>>>
>>>>thanks
>>>
>>>Doesn't matter really. F5 would compile and run. Or build (doesn't express menu have it?).
>>>Cetin
The American Republic will endure, until politicians realize they can bribe the people with their own money.
- Alexis de Tocqueville

No man’s life, liberty, or property is safe while the legislature is in session.
– Mark Twain (1866)
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform