|
Ben Magee wrote: I now understand I need a public class with static variables inside to store data.
I think my previous statement still stands. This is not the way to store data within classes or methods.
|
|
|
|
|
Ben Magee wrote: it generates the last number
Do you mean it goes through all the available numbers and then you try to get one more? When there aren't any more? Don't you want to reset at some point?
|
|
|
|
|
When the form loads, it generates all the numbers, and writes them to a file. When you press the button, it gets a random line from that file, and then the number on it, it then checks if the number is in a file with the numbers already called, if it isnt, it adds it to that file and then displays it.
Forgive me, I am still relatively new to C# - and I am looking up on sharing variables between classes now.
BtM.
|
|
|
|
|
Regardless of the implementation; once you've selected all the numbers, there are no more to select no matter how hard you try. You need to reset.
|
|
|
|
|
Hi all,
I have an asp.menu that is bound to a SiteMapDataSource. The web.sitemap file is built dynamically via the Session_Start method in global.asax. On each Session_Start a query is made to a table called "categories" in my database which contains all the sitemap data. This data is used to generate the web.sitemap file.
I've set a breakpoint and I actually see the web.sitemap file getting rebuilt everytime, however, even when the web.sitemap changes I see no change in the menu. It is not until I make a change to the web.config and save it that the changes to the web.sitemap are reflected in the menu. This tells me it is somehow getting cached.
Can someone please help??
Thanks!
Tim
|
|
|
|
|
i want to make c# program that can connect to the internet by using my mobile as modem,which i will insert "access point" and "user name "
provided by services company like "Fodafone"
please help me
|
|
|
|
|
Anyone who answers you will almost certainly do so after having googled. So why not do so for yourself, try to use what you find and only then ask here with a specific problem, showing the code that causes you a problem and stating the exact error/problem.
Hint: There are some articles here on Code Project that might help you.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
I want to get the number of bytes written into or read out from my disk in the latest minuter.
But I hava no idea . Please do me a favor?
|
|
|
|
|
|
Thank you!
I have checked that class.There are only properties but no methods in it.I still hava no idea how to use it.can you give me a example to show me how to use that class to get what I want?
|
|
|
|
|
I am facing this problem 1st time. I've made a web service in VS 2005 and a windows client application which consumes it without any problem since long time.
Recently we decided to develop the new client application hence i decided to use VS 2008. I copied the methods from old application, which has code to call the web service methods. I added the web reference and I can see all the web service classes and methods in OBJECT BROWSER (by right clicking on the web service reference and clicking on View in Object browser). When I compile the application i get the error on the line where I am declaring the variables of classes in web service
MyAppNamespace.MyWebService.ClassName webObj;
Note that fully qualified name is in my code and same is shown in Object browser. But when I try to type the code in VS 2008, I can not see the web service name space (MyWebService) in intellisense any where. I opened the Reference.cs file of the web service, there also present same name space as i am using. I can open the Web service URL in browser and also old application is still working fine with web service.
Is there any body who can guide me what is wrong? Thanks in advance
Modified:
One thing more for your information. I've 2 projects in a solution. One is Windows Forms project and other is .NET Assembly project (to create the .NET assembly).
If I am adding web reference in Windows Forms project, it is working. i.e. I can use web service classes and methods, but if I add web reference to .NET assembly project, I can not, which is actual problem mentioned above.
Regards
Aftab Sindhi
.NET Application Developer
U.A.E
modified on Sunday, November 1, 2009 2:40 AM
|
|
|
|
|
Hi
I need send and receive information from "single COM port" to "2 COM port", We know COM has 9 pin and with only 3 pin you can send & receive into one device. So physically this is possible. and I want to know how can implement with C#.
Best Regards,
Reza Shojaee
|
|
|
|
|
How to use COM port in C#[^]
Sorry - didn't understand your question properly. My bad.
No trees were harmed in the sending of this message; however, a significant number of electrons were slightly inconvenienced.
This message is made of fully recyclable Zeros and Ones
modified on Saturday, October 31, 2009 7:44 AM
|
|
|
|
|
Having read the Stancrm post, I see what you are trying to do. If you connect two external machines to a single RS232 port, it may work. RS232 is intended for point to point work, not multidrop and its electrical specification is designed for just that. Certainly, the two devices will be able to hear anything you transmit on the port, (at least until the distances from the source port get too big) but it is unlikely that transmissions into the port from one of two connected devices will work - it may, but it will depend on the design of the hardware connected to the port and the physical tollerances of the components. (i.e. it may work with these two devices, but if one of them is changed for an identical model it may not, or it may work but only intermittently).
I would really consider why you are doing this, and look at better technology for it, such as RS485 or USB.
No trees were harmed in the sending of this message; however, a significant number of electrons were slightly inconvenienced.
This message is made of fully recyclable Zeros and Ones
|
|
|
|
|
About possibility or no, I saw this configuration physically & with delphi software.
About using USB or RS485, My devices work with RS232.
Best Regards,
Reza Shojaee
|
|
|
|
|
You can buy RS232 - RS485 converters from about £5 - don't know how good they are.
Similarly RS232 - USB converters, but they are more expensive.
Either solution would work better and be more reliable than multidrop RS232.
No trees were harmed in the sending of this message; however, a significant number of electrons were slightly inconvenienced.
This message is made of fully recyclable Zeros and Ones
|
|
|
|
|
You'll need hardware that can allow to use pre-defined pin(s) as RX/TX.
For most standard uart hardware cards, the UART COM is usings pins #2/#3 (for RS-232). The other pins are used for RS-422/485 & handshake (RTS/CTS etc.) purpose.
If you have any FPGA & VHDL knowledge, you could code yourself some generic UART module that can handle 2 rs-232 on different pins assignments. and then use it as "middle-box" to communicate via it.
Could be some1 made such product already...
|
|
|
|
|
What is the mechanism of converting objects to bytes seqs and recovering them back to send with sockets.
e.g. I need to send some structure over TcpClient and recieve it with TcpListener then send back some more data: strings, structures.
Is serialization used or some other specific approach that works with sockets?
Чесноков
|
|
|
|
|
Message Closed
modified 23-Nov-14 7:24am.
|
|
|
|
|
but serialization uses assembly specific data.
how to do it if the client and server is in different assemblies? but the structure is exactly the same?
I do not want to encode specific assembly to be used as reference in both client and server, that will serialize/deserialize the data.
Чесноков
|
|
|
|
|
|
what is that???
Чесноков
|
|
|
|
|
Hi all, crystal reports are new for me. i need help for creating a report having two parameter which takes Start Date and End Date which contain the range of dates and when i select dates it show related reports.i want to fix date ranges at run time using C# code.
I take a code from an article but it doesn't work.
If u have any article plz give me link i will consult it.
advance thnx 4 help
|
|
|
|
|
i code a connection string in web.config in appsetting now i want to use that connection in dropdownlist which i want to bind through wizard. How i give that connection using wizard to bind it???
|
|
|
|
|
Try the ASP.NET forum
No trees were harmed in the sending of this message; however, a significant number of electrons were slightly inconvenienced.
This message is made of fully recyclable Zeros and Ones
|
|
|
|