How to get data from PHP into C# Windows Application? [modified]
-
Hello everyone, I have a PHP file which is holding some data which I would like to enter into an Windows Application written in C#. I have no clue what so ever and I have no idea where to start. Could you be kind enough to tell me how this can be done and where I need to start? I am not sure if this is even possible to be honest with you. Maybe I cannot use PHP and should get ASP.NET for this?!!! Anyways, I welcome any suggestion. Thank you very much and have a great day. Khoramdin -- modified at 22:05 Monday 19th March, 2007
-
Hello everyone, I have a PHP file which is holding some data which I would like to enter into an Windows Application written in C#. I have no clue what so ever and I have no idea where to start. Could you be kind enough to tell me how this can be done and where I need to start? I am not sure if this is even possible to be honest with you. Maybe I cannot use PHP and should get ASP.NET for this?!!! Anyways, I welcome any suggestion. Thank you very much and have a great day. Khoramdin -- modified at 22:05 Monday 19th March, 2007
How about a Webservice?
Vasudevan Deepak Kumar Personal Homepage Tech Gossips
-
How about a Webservice?
Vasudevan Deepak Kumar Personal Homepage Tech Gossips
-
Hello everyone, I have a PHP file which is holding some data which I would like to enter into an Windows Application written in C#. I have no clue what so ever and I have no idea where to start. Could you be kind enough to tell me how this can be done and where I need to start? I am not sure if this is even possible to be honest with you. Maybe I cannot use PHP and should get ASP.NET for this?!!! Anyways, I welcome any suggestion. Thank you very much and have a great day. Khoramdin -- modified at 22:05 Monday 19th March, 2007
I'm not quite sure if I understand. Do you want to take the PHP file and put into a datagrid? Or do you just want to display it as a website? (I don't know what a PHP file is) To open it you can do this....
Filestream file = new Filestream(YourPHP.PHP); StreamReader sr = new StreamReader(file); string s = sr.ReadToEnd(); //Here is where you actually do stuff with your file (put in datagrid?) sr.close(); file.close();
But you don't do that if you just want to display it in a WebBrowser. Hope this helps, but if not, let me know. :) -
Hello everyone, I have a PHP file which is holding some data which I would like to enter into an Windows Application written in C#. I have no clue what so ever and I have no idea where to start. Could you be kind enough to tell me how this can be done and where I need to start? I am not sure if this is even possible to be honest with you. Maybe I cannot use PHP and should get ASP.NET for this?!!! Anyways, I welcome any suggestion. Thank you very much and have a great day. Khoramdin -- modified at 22:05 Monday 19th March, 2007
You can put a webbrowser control into your site and just point the URL to your PHP site. A web service is a program that passes data over the web, not through pages, but as XML. Google will tell you more.
Christian Graus - Microsoft MVP - C++ Metal Musings - Rex and my new metal blog "I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
-
You can put a webbrowser control into your site and just point the URL to your PHP site. A web service is a program that passes data over the web, not through pages, but as XML. Google will tell you more.
Christian Graus - Microsoft MVP - C++ Metal Musings - Rex and my new metal blog "I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
Hello Christian, Thanx for the reply. That is exactly what I am doing as I placed a webbrowser control in the Windows Application which is pointing to my php file. Now I have the executed php file displayed in the webbrowser control, containing the information "data" that I need to have available in the Windows Application as variables. How on earth I can get the displayed data into the Windows Application and use those variables in the C# programing? Thank you very much for your help. Khoramdin
-
Hello Christian, Thanx for the reply. That is exactly what I am doing as I placed a webbrowser control in the Windows Application which is pointing to my php file. Now I have the executed php file displayed in the webbrowser control, containing the information "data" that I need to have available in the Windows Application as variables. How on earth I can get the displayed data into the Windows Application and use those variables in the C# programing? Thank you very much for your help. Khoramdin