Pieter Versteijnen's Q&A profile
.NET Development Communication between apps via sockets.
I am trying to set up a communication channel between two Windows apps. Actually there should be 3 of them. One form is local, another form is located on the same machine, the third form is on a different PC connected via a LAN. My first attempt is to send a few strings of bytes from one form to the other locally. On the server side. This code is working : listenSocket = new Socket ( AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp ); int port = Convert.ToInt32 ( "19001" ); IPAddress hostIP = (Dns.Resolve ( IPAddress.Any.ToString ( ) )).AddressList[0]; IPEndPoint ep = new IPEndPoint ( hostIP, port ); listenSocket.Bind ( ep ); int backlog = 2; listenSocket.Listen ( backlog ); StateObjec ...Show All
SQL Server Search Stored Proc
Does anyone know a way to seach through all databases on a SQL 2000 server looking for a particular stored proc by name Say I'm looking for a sproc with ProjectUpdate in the name. Using the code example you provided, how could I make this work All I want to do is find it so I can open it for modification. ...Show All
Software Development for Windows Vista starting application from setup - not as administrator
Hello all: When my application is run for the very first time at the end of the installation process, it is running as administrator, because the setup itself was automatically detected and elevated by Vista. Is there any option to run it from setup at usual (medium) privilege level I have tried manifest with requestedExecutionLevel of asInvoker - to no avail. TIA OTNS Here is the answers I have got from MS: your application running with high privilege can not directly create a low privilege application. The best way to do this today is to first create a medium privilege exe that launches your high and low privilege apps. The medium privilege exe can create a low privilege thread and t ...Show All
.NET Development Get worksheet by name from an excel worksheet
Howdy, I am working on a project to get data from excel spreadsheets and update an Access database with the new records. The excel spreadsheets are being generated by another department and I have no control over when they are being produced, or how they are being named. I think I have how to access the spreadsheet and extract the data to a DataSet (it seems straightforward). However, to select the data out of the workbook it looks like I need to explicitly name the worksheet that the data is on. Right now there is only ever ONE worksheet in the workbook, but it is NOT named 'Sheet1', the name is automatically generated by the equipment that is outputting the sheets. Here is an excerpt from what I have right now: ' How to get data from ...Show All
SQL Server Splitting string and show in rows
Hello, I have a dilemma. I have made a report which show data from crm (3.0) What I want exactly is the following: I have a table on my report. In the table I want to show data from a field in crm. The data in this field look like this: 12345; 67890; 54321; 11223333; Now the thing is that I want to get this string and split it at the "; " characters Then I want the splitted strings showed in separate rows. I already have splitted the string with the following expression: =SPLIT(Field!new_numberfield.Value, "; ")(0) //The zero at the end stands for the array first entry This is working but showing only one substring. I it possible to do what I want Best regards, Fedor B ...Show All
SQL Server Basic Functionality Questions
We've been trying to implement Reporting Services in our web application. We've run into 2 issues that I'd like to verify: First, HTML rendering. In our application we provide an HTML Editor for formatting . The formatting does not render in the reporting services. I understand that's a known issue with no work around and no timeframe for resolution. Is that correct Second issue comes with tying is the Reporting Services together with our ASP.NET code. Do any of the Reporting Services controls allow you to bind to classes that support the IList Interface Thanks, Frank 1) RS text box control does not render HTML. It supports standard formatting which applies to the entire contents of the text ...Show All
Visual Studio Express Editions Starter Kit Install Errors
I am using Visual C# 2005 Express and Visual Web Developer 2005 Express on a Windows XP SP2 system and when trying to install either CSCardGame.vsi or TimeTracker.vsi I get the message: "Installation aborted because the item was a duplicate of an item already installed." I've checked both programs and they do not show up at all in either "New Project" dialogs. Any documentation on how to manually install these Templates Thanks. Dave Dave - If you rename the CSCardGame.vsi file to CSCardGame.zip, you'll be able to open the CSCardGame.zip. Inside that .zip file, you'll see another .zip file (CardGameStarterKit.zip). If you take the CardGameStarterKit.zip file and copy it to your %My Docum ...Show All
Visual C++ Using Windows API with managed code
I am trying to read data from a Tape using the Tape Backup functions in Win32 in managed code. The problem is that the only function that I can find thah will read data from tape is ReadFile(), whose 2nd argument is an LPVOID. The buffer that I can use to store the tape data is an array<Byte>^ type, thus I need to convert the managed Handle ^ to an LPVOID. I tried using PInvoke, however the MarshalAs:: has no such type, LPVOID, among its parameters to convert. Does anyone know of a solution to this problem You can use pin_ptr ( http://msdn2.microsoft.com/en-us/library/1dz8byfh(VS.80).aspx ), to create a buffer usable by the unmanaged subsystem. I would think that there are alternative ways to read from tapes, ...Show All
Visual Studio 2008 (Pre-release) subgroup in peer mesh
Hi, im doing a p2p chat program, apart from broadcast to whole mesh, i want to one-one and small group chat as well, anyone knows how to implement this in p2p thanks a lot oaix Actually im thinking of push the 1-1 and subgroup logical to 'apps' level. which means every node in the mesh will receive all messages but the apps will only display those that targeted as recipient . in this way, P2P handles all my communicatiion so i no need to worry too much. does trhis make sense or anyone have better ideas ...Show All
Customer Care Framework Basic Web authorization
How can I make basic web authorization for external web site You can see an example of this authorization here: http://www.ljplus.ru/img3/g/a/gaploid/WebAuthentication.JPG Best regards, Victor Thx for the answer. As I understand the user under which I go to URL need to be in AD, but I need a simle basic auth and this user is not present in AD or on this local machine. Or I something did not understand ! ...Show All
Windows Forms Write to a specific place in a text file
Hello everybody I've been programming in C# for a while and done some writing and reading from text files. Now I've come to a point where I want to develop an editor in C#(hehe) and need to know how to insert a string on a specific place in a text file. Lets say that you want to insert a string on a sixth row, six characters from the left side of the screen I hope someone can provide an answer to me. Thx in advance Kind regards Allan H. That's going to make your editor incredibly slow. Each time you insert a character at the top of a 1MB file, you'll have write 1MB-1 bytes to the file. That hourglass is going to get old quickly. Do it like every other editor, edit your data using ...Show All
Community Chat Dynamic Semantics of Document
Hi, Few days ago, I read some articles about MSOffice 2007, and I was puzzled with the term: Dynamic Semantics of Document. Can anybody explain the term: Dynamic Semantics of Document in MSOffice. Is there any tutorial or material about this topic Thank you in advance! ...Show All
SQL Server problem in connecting to sql server Express
Hi to all, i'm installing sql server in my pc as netwrok service. when i try to connect it, it showing me a error sql server does not allow remote connections error 26 error locating server/instance (MS Sql server ) how can i resolve this plz help me out. it not able to connect the server locally. when i try to connect it with .\SQLEXPRESS or localhost\SQLEXPRESS it will connect to the DB But when i use ServerName\SQLEXPRESS it wont connect to DB what the problem plz help me with Regards Amjath Hi, These are the Services , SQL Broswer service required because it gives connection information to client computers, start them and see if it works. And what about the other question i asked !!! When did you ...Show All
Visual Basic CheckBox_Click Name
Private Sub ExcluyeOC( ByVal sender As Object , ByVal e As System.EventArgs) Handles CheckBox1.Click, _ CheckBox10.Click, CheckBox11.Click, CheckBox12.Click, CheckBox2.Click, CheckBox3.Click, CheckBox4.Click, _ CheckBox5.Click, CheckBox6.Click, CheckBox7.Click, CheckBox8.Click, CheckBox9.Click, CheckBox10.Click, _ CheckBox11.Click, CheckBox12.Click Me .strExOC.Add( Me .Controls( "txtNumOC" & Mid( Me .ActiveControl.Name, 9)).Text) Call LlenarContraRecibo() Then I need to set the Checked = True of the CheckBox that fired this procedure. How can I do this I dont know wich one of the 12 CheckBoxes did the job, How can I know :) Actually, I would VERY rarely think to disagree ...Show All
Visual Basic Wait for a file to be created in a command line application
I created, well trying to create, a command line application that waits for a file to be created and then copy it to another folder. I am using the filesystemwatcher. But how do I wait for the event raised by the object in a command line app Now the app returns to the prompt after its started. can you show us some code take a look at this if you have not: http://msdn2.microsoft.com/en-us/library/system.io.filesystemwatcher.aspx you just implement the OnChanged event, as shown in the example, and wait till the event is raised (it does it automatically when the condition has been met) ...Show All
