152 Posted Topics

Member Avatar for ltkillekar

This appears to be an exact repost of [URL="http://www.daniweb.com/forums/thread161674.html"]this[/URL] DaniWeb post...?

Member Avatar for mcriscolo
-1
96
Member Avatar for nazerb

Check out this link: [URL="http://stackoverflow.com/questions/1011339/how-do-you-make-a-http-request-with-c"]http://stackoverflow.com/questions/1011339/how-do-you-make-a-http-request-with-c[/URL].

Member Avatar for pseudorandom21
0
127
Member Avatar for raidernation

Hmm... seems to work fine for me (Mac OS X 10.6/g++) Random stuff... you mean a lot of 'a' characters? When I ran your program as-is, here was the output (my input file has 2 lines - "a dog" and "a cat"): [QUOTE]aa adaoagaaa acaaata[/QUOTE] Of course, that's because each …

Member Avatar for raidernation
0
1K
Member Avatar for maac2002

Just make a new instance of the "Service1SoapClient", like this: [CODE]Service1SoapClient myWS = new Service1SoapClient();[/CODE] Then, you should see your methods on the "myWS" variable: [CODE]string sResult = myWS.CelsiusToFahrenheit("25");[/CODE] You may have to include the namespace, if you did not put it in the "using" section: [CODE]ServiceReference1.Service1SoapClient myWS = new …

Member Avatar for maac2002
0
886
Member Avatar for cousinoer5

Your seekg positioning is off. When you add records, you use: [CODE] fio.write((char*)(&t1), sizeof(t1)); fio.write((char*)(&active), sizeof(active));[/CODE] but when you look for records in your modify and delete, you use: [CODE]fio.seekg((number + 1) * sizeof(t1));[/CODE] all well and good, but you are not accounting for the 1 byte boolean (active) that …

Member Avatar for cousinoer5
0
485
Member Avatar for plang007

Because the "else" condition for your invalid character check is only on the "if (fare == 'C' || fare == 'c')" statement. If the user enters an "s" or "S", it does everything you want, but then falls to the "if" statement for "C", and, failing that, it shows the …

Member Avatar for mcriscolo
-1
637
Member Avatar for GAME

Start here: [URL="http://www.csharp-station.com/Tutorials/AdoDotNet/Lesson01.aspx"]http://www.csharp-station.com/Tutorials/AdoDotNet/Lesson01.aspx[/URL]

Member Avatar for GAME
0
157
Member Avatar for VernonDozier

Really? I ran this and I got 0x01. Here's the code (Eclipse Helios on Windows 7): [CODE]public class ArrayRefTest { public ArrayRefTest() { //Default Constructor } public static void main(String[] args) { ArrayRefTest a = new ArrayRefTest(); a.foo(); } public void ChangePrimitiveArray(byte bytes[]) { bytes[0] = 1; } public void …

Member Avatar for VernonDozier
0
216
Member Avatar for jonnod123

Check out this thread: [URL="http://www.pcreview.co.uk/forums/desperately-seeking-ability-add-new-row-my-datagridview-t3223011.html"]http://www.pcreview.co.uk/forums/desperately-seeking-ability-add-new-row-my-datagridview-t3223011.html[/URL] It sounds like a similar issue.

Member Avatar for jonnod123
0
107
Member Avatar for darkseid

Perhaps this: [CODE]try { FileSystem.CopyFile(fSource, fTarget, UIOption.AllDialogs, UICancelOption.ThrowException); // Throw exception if user cancels foreach (ListViewItem checkItem in listView_left.Items) { if (checkItem.Text == lItem.Text) { listView_left.Items.Remove(checkItem); } } listView_left.Items.Add((ListViewItem)lItem.Clone()); reload(lItem, fSource); } catch (OperationCanceledException ocex) { // The user canceled }[/CODE]

Member Avatar for mcriscolo
0
139
Member Avatar for writecharlie

Well, a couple of things: 1) After you've selected from the first choices, you go into the "checksize" function. Here, you state that you can enter 'restart' to restart the ordering process. Your function is expecting a number (diameter of the pizza) - but if the user enters 'restart', they …

Member Avatar for mcriscolo
0
132
Member Avatar for Duece_68

Is there a reason why you have to set up the methods to take a type of "Object"? Will your "main" program accept DLLs that pass structs/classes of many types? Even if that's the case, your main project will still have to know about them in order to cast the …

Member Avatar for Duece_68
0
334
Member Avatar for hmnetonline

Does the "ref" value for the variable "SessionNumber" that gets returned to your calling program get set to "ERROR", or does the whole thing blow? If so, you may want to trap the exception to see what its giving you. [CODE]try { System.Diagnostics.Process.Start(target); SessionNumber = "SUCCESS"; } catch (Exception ex) …

Member Avatar for mcriscolo
0
105
Member Avatar for MrCapuchino

Are you checking the contents of the output file while the program is still running? Normally, when the file is closed (either explicitly, or when the object is disposed and the GC cleans it up), the buffers will be flushed. If you want to check the status of your output …

Member Avatar for kvprajapati
0
218
Member Avatar for MARKAND911

Try this link: [URL="http://www.dotnetblogger.info/center-form-run-time-net/"]http://www.dotnetblogger.info/center-form-run-time-net/[/URL]

Member Avatar for kvprajapati
0
429
Member Avatar for moshe12007

You really want to try to develop a query for your data. Searching serially through a database defeats the purpose of using a database in the first place. See this post: [URL="http://vbcity.com/forums/t/112704.aspx"]http://vbcity.com/forums/t/112704.aspx[/URL] to see how to set up C# code to query an Access database. You can either use a …

Member Avatar for mcriscolo
0
95
Member Avatar for jlivvers

Depending on the complexity of the task, I can think of 2 ways off the top of my head: 1) Write a C# process that does your check and updates the required tables (most likely a Windows Console application). Set it up to run on your server as a Windows …

Member Avatar for mcriscolo
0
231
Member Avatar for tripleD

The ListView supports the "DragLeave" event. Would this help? Once the event fires, you can check to see what's being dragged and if its an item from the ListView, you can remove it.

Member Avatar for tripleD
0
807
Member Avatar for agam360

You can search through the items in a ListView, by iterating through the "Items" collection. Further, each item has a SubItems collection. So, with code like this, you can look for an item in a ListView and do something with it. In this case, I have a ListView called "lvBatters" …

Member Avatar for mcriscolo
0
90
Member Avatar for stevanity

Your problem seems to be twofold, but related to the same thing: Both solutions are named the same thing. When I pulled them down, it renamed the folder for one of them (the DLL project) to "PermutationGenerator.1". However, when I looked in the "References" item for the main project, you …

Member Avatar for stevanity
0
139
Member Avatar for HeartBalloon

First, that semicolon on line 8 (between the end of your method implementation and the curly brace) is going to be a problem.... "blabla.date" is "const char *". So, one of 2 things: either cast the return value as (char *), so it will match the method prototype: [CODE]return (char …

Member Avatar for HeartBalloon
0
382
Member Avatar for scottdurica

Scott, Well, it depends what you want to do with the file after you're done.... however, once you write a PNG file to the back of a TXT file, it's really not a TXT file anymore. You could write out your data as binary, then tack the PNG onto the …

Member Avatar for mcriscolo
0
736
Member Avatar for Singlem

Nonsense! Forms are your friend! Here's how you can get it to work, provided, that Form2 acts as a dialog - that is, you display Form2 wait for the user to exit the box, then close Form2 and collect the information from now hidden form. In Form1 (in the button1_Click …

Member Avatar for Mitja Bonca
0
171
Member Avatar for Nandomo

When you call "displayPlayerInfo", you are not referencing the array "players" that was created in main. You reference "pInfo", a new and uninitialized array of PlayerInfo structures. Pass the "players" array into the "displayPlayerInfo" and change the loop to use that, and you should be all set.

Member Avatar for mcriscolo
0
128
Member Avatar for Vikas Sharma86

Have you seen this post: [URL="http://code.activestate.com/lists/perl-win32-admin/6938/"]http://code.activestate.com/lists/perl-win32-admin/6938/[/URL]

Member Avatar for mcriscolo
0
98
Member Avatar for zachattack05

Other than the details you gave in your post (so I don't know the *real* complexity of your app, or your budgetary constraints), might I suggest that you actually convert the data for your app to use a database? That is (and again, I'm not privy to the reasons why …

Member Avatar for mcriscolo
1
251
Member Avatar for shajis001

You do have the word "double" in your regex string twice (once near the beginning and once near the end). But that doesn't fix the issue. Modify your token string to look like: [CODE]string tokens = "\\s(auto|int|struct|break|else|long|switch|case|enum|register|typedef|char|extern|return|union|const|float|short|unsigned|continue|for|signed|void|default|goto|sizeof|volatile|do|double|if|static|while)\\s";[/CODE] This will cause it to make sure each token is preceded and followed …

Member Avatar for mcriscolo
0
132
Member Avatar for MasterGberry

Current screen size/resolution. You will need some more code to check the display driver capabilities. Check this out: [URL="http://www.news2news.com/vfp/?example=374&ver=vcs"]http://www.news2news.com/vfp/?example=374&ver=vcs[/URL]

Member Avatar for MasterGberry
0
249
Member Avatar for CHOCHOCHO
Member Avatar for vigneshkbv

You may want to try the MaskedTextBox. It allows you to specify a mask to use in the control. Also, this will be smoother for handling things like editing in the control (backspaces, user clicking in the middle of the text and making changes, etc.) To set the mask, do …

Member Avatar for vigneshkbv
0
444
Member Avatar for Mr.BunyRabit

Have you tried setting the "DataSource" property of the DataGridView to null? [CODE]tblAllEntries.DataSource = null;[/CODE]

Member Avatar for Mr.BunyRabit
0
135
Member Avatar for MasterGberry

Lots of great examples here: [URL="http://stackoverflow.com/questions/236129/how-to-split-a-string"]http://stackoverflow.com/questions/236129/how-to-split-a-string[/URL] Good luck!

Member Avatar for MasterGberry
0
2K
Member Avatar for Mr.BunyRabit

Try this link: [URL="http://www.switchonthecode.com/tutorials/csharp-tutorial-binding-a-datagridview-to-a-database"]http://www.switchonthecode.com/tutorials/csharp-tutorial-binding-a-datagridview-to-a-database[/URL] Looks to be a good example of exactly what you need.

Member Avatar for Mr.BunyRabit
0
167
Member Avatar for Dekea

Use the "CompareTo()" method of the string class. It compares two strings and returns an integer, thusly: [CODE]int iCmp = Text[i].CompareTo(Text[i+1]); if (iCmp < 0) { // Text[i] is "less than" Text[i+1] } else if (iCmp > 0) { // Text[i] is "greater than" Text[i+1]; } else { // Strings …

Member Avatar for Dekea
0
204
Member Avatar for MindTrixz

Look at line 33 - is this the correct way to call a function? See line 24 for a good example... But you have a second problem. Look at where "firstNum" and "secondNum" are declared (in the function "displayMessage"). These will not be visible in your main() function. You either …

Member Avatar for Valaraukar
0
112
Member Avatar for harish_s

Looks like someone over at "social.answers.microsoft.com" is already answering this.... But, to be complete, I pasted the code into a new VS2008 project and ran it on my 64-bit Windows 7 installation, and it ran just fine. On a subsequent run, I deliberately messed up the machine name but in …

Member Avatar for harish_s
0
238
Member Avatar for Wikedshorty

This is going to sound like I'm being an a**, but I don't mean to be... sometimes it helps to just put stuff down on paper and visualize it. Write 2 columns of ascending (sorted) numbers on the paper (you can use 10 values, but less will suffice for illustration). …

Member Avatar for Wikedshorty
0
2K
Member Avatar for abcdabid

It looks like you may be off a node when you issue the delete. Here's a console app that will do what you want - you can adapt the code as you see fit: [CODE]using System; using System.Collections.Generic; using System.IO; using System.Text; using System.Xml; namespace XMLDelete { class Program { …

Member Avatar for papanyquiL
0
91
Member Avatar for vilas_tadoori

The only potential issue I see is that if you call "addnode" twice. The method does not check to see if "start" is pointing at anything. If called a second time, you will lose the context to the node that was established in the first call. You can really just …

Member Avatar for vilas_tadoori
0
155
Member Avatar for bill_kearns

Is the data coming in to you sorted? Or, can you sort it? If so, then you can use standard break totaling. That is, you have "holder" variables for the vendor and the budget period. Then you process each row of your set, totaling up the values for your financial …

Member Avatar for bill_kearns
0
1K
Member Avatar for fellixombc

On line 58 of your server.cpp, you are hanging on the "accept" call. That is, first time through, you accept the connection from your first client. It's running through your loop below, but there's no data, so it goes back to the top and hits the "accept" again, waiting for …

Member Avatar for fellixombc
0
491
Member Avatar for tiger188

You could try this: [URL="http://axiom3d.net/wiki/index.php/Main_Page"]http://axiom3d.net/wiki/index.php/Main_Page[/URL] or here is an (older) tutorial that uses the TrueVision 3D library: [URL="http://www.codeguru.com/csharp/.net/net_general/graphics/article.php/c11375/Creating-an-Interactive-3D-World-in-CNET.htm"]http://www.codeguru.com/csharp/.net/net_general/graphics/article.php/c11375/Creating-an-Interactive-3D-World-in-CNET.htm[/URL] Good luck!

Member Avatar for ddanbe
0
598
Member Avatar for geoNeo_

You will have to handle the "Draw" event for the tooltip and render it yourself. See the link below for the code: [URL="http://social.msdn.microsoft.com/Forums/en-US/winformsdesigner/thread/19994c9f-bdaa-4c4c-bcb4-5c60cb241134"]http://social.msdn.microsoft.com/Forums/en-US/winformsdesigner/thread/19994c9f-bdaa-4c4c-bcb4-5c60cb241134[/URL]

Member Avatar for mcriscolo
0
116
Member Avatar for khan17

If I understand correctly, rather than having the user press a button to bring up the page in the WebBrowser control, you could put "webbrowser1.navigate" statement into the "Form_Load" method of the form. Just double-click in a blank area of the form and the code window will appear, with the …

Member Avatar for mcriscolo
0
151
Member Avatar for jellybeannn

Have you hand-run your SQL statement to see what results it produces? It appears to me that the statement will only return a single column. However, in your statements after the "reader2.Read()", you are accessing multiple columns. If there's only one column in the result set, that code will definitely …

Member Avatar for jellybeannn
0
385
Member Avatar for Mitja Bonca

If it's a Windows Forms app, yes, you can use the Timer object and set the "Interval" property to the desired value, in milliseconds, then call the "Start()" method to start the timer. It will fire the "Tick" method when the interval is reached. From there, you can call any …

Member Avatar for mcriscolo
0
933
Member Avatar for khan17

[QUOTE]can i transfer the data in text file to sql to be in table format not as a whole textfile.[/QUOTE] That depends on how you need to access the data afterward. You could shove the entire text blob into a database table as one column, or, if you've split out …

Member Avatar for mcriscolo
0
109
Member Avatar for aju982007

The .NET Framework, in conjunction with Visual Studio has a facility to generate a proxy class for a WSDL-based SOAP web service. First, can you reference the WSDL of the service? You should be able to get to it with HTTP syntax like: [icode]http://www.somesite.com/someservice?WSDL[/icode] That will differ from site to …

Member Avatar for nrrbalaji
0
421
Member Avatar for adam2009

You could use the "Startup" folder for a user. Be aware that folder will be at different locations based on the OS being used (XP, Vista, Windows 7, etc.) However, even though your scripts are written in C#, you may get more answers if you post this in the "Microsoft …

Member Avatar for adam2009
0
171
Member Avatar for tookerello22

First, does the IDE tell you what line you're getting the NULL reference exception on? Not sure how you want this to work, but when you check the XML node in your first "if" statement - if it's true (that is, the node is NOT null), you do this: [CODE]c …

Member Avatar for mcriscolo
0
174

The End.