Topics
-
- 0 replies
- 1.3k views
Hey all, Does anyone have a clue on this one... When I serialize my object to a binary file, and read it back (without closing the app) everything works fine, but when I serialize my object, close the app, and then try to deserialize the file back to the object I allways get an invalid cast exception... Is this security related??? Thx in advance,
Last reply by TripleB, -
-
- Leaders
- 1 reply
- 965 views
Hi guys. Mi Asp.Net page creates some textboxes on load depending from records it retrieves from a db. Here is a simplified version (actually I used more control even some of Microsoft.Web.Ui.WebControls assembly): Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load If Not Page.IsPostBack Then dbConn.ConnectionString = Application("ConnectionString") dbConn.Open() Dim cmd As New SqlCommand("select content from textboxes where page = 'home' order by presentation_order", dbConn) Dim myReader As SqlDataReader myReader = cmd.ExecuteReader() While…
Last reply by snarfblam, -
-
- 0 replies
- 926 views
ok heres the thing... I have been asked to create a program that will log all messages sent and received via "MSN Zone Messages". For those of you unfamilliar the messages are individual messages sent with the message text in what appears to be a label and a text box area for a reply. i have used a simple keyboard interupt to obtain keystrokes for the reply and api calls to getwindowtext. My problem is logging incoming messages. I am unsure where to start. Should i be trying to intercept the message before it gets to the zm program? should i try to do some sort of capture when the message is active? I think the main issue i have is I do not know how the tex…
Last reply by Dill, -
- 8 replies
- 2k views
Hi, I'm quite new to the idea of threading and was wondering what was the best way to handle the following... I have an application that is going to accept socket connections from various other remote devices. I want to create a new thread to handle each of these connections. I'm OK, I think, on how to do that, it's just the best way to handle the threads to keep track of them, for example if another message comes in from one remote device, I need to route that message to the correct thread for processing. What would be the best way to handle that? Any suggestions appreciated. Also as a side note, this may be a really stupid question, but if I have and applica…
Last reply by mjohnson3091, -
- 2 replies
- 995 views
hi all, I want to display number of rows in grid in each page like "starting row to end row of total rows" i am using paging in the grid. I manged to do so by using shared variables for staring row , end row nd total rows and incrimented and decrimented correspondingly when navigated to next page. But if i took two browsers then as i used shared variables i am getting problems. Can any one give me a suggestion to do this. Thanks
Last reply by smriti, -
- 1 reply
- 1.1k views
I want to be able to send a notification to all other running instances of my .NET app whenever its options are changed, so the other instances can reload them. If I don't mind using the win32 api, this is really easy. All I have to do is call RegisterWindowMessage, then call another api function to broadcast the message to all windows, and then I could override WndProc in my form to receive it. But I'm wondering if there's something built into the .NET Framework to handle this, or at least somehow get the same effect. I'm doubting it, but I decided to ask anyway, just in case..
Last reply by Wraith, -
- 0 replies
- 1.6k views
Dear fellow programmers, I need a favor here. I'm trying to build a word processing application. Well, it's not exactly like Microsoft Word, but of course much more complex than a simple notepad :D. Let's say I'm trying to build an application similar to mail merge. My application needs to create a standard template, which will be filled in by the user, and then prints them. I'm thinking crystal report ... but I don't think it'll work. I'm thinking of using some COM, but I don't know how to use it. Any tips? Thx in advance.
Last reply by amir100, -
-
- Administrators
- 6 replies
- 1.3k views
Hi, I trying to make a flexible config file using XML, but I'm not sure how I should read it... This is the way it looks: <Settings> <ComPorts> <IO1> <PortName>COM2</PortName> <BaudRate>19200</BaudRate> </IO1> <IO2> <PortName>COM4</PortName> <BaudRate>4800</BaudRate> </IO2> </ComPorts> </Settings> There can be any (up to 10) number of IO:s and for each IO I need to create a SerialPort. My Q is how I read a file with unknown number of IO:s? Should I add an element that contains the number of IO:s? XML is supposed to be so simple and flexible. I only fi…
Last reply by kejpa, -
-
-
- Leaders
- 3 replies
- 1.6k views
I have a struct named "Screen." By best guess is that my problems are somehow related to a name conflict with the System.Windows.Forms.Screen class. Here is my problem: I have shared (static in c#, i believe) members with initializers in the declaration (Shared i As Integer = 7 / int i = 7; ). I am recieving errors that "initializers on structure members are valid only for constants." When I change the name of the struct, all my errors dissapear...
Last reply by HJB417, -
-
-
- Leaders
- 3 replies
- 1.6k views
In one form of my VB.NET Windows application, I have a picturebox. I need to draw a line (using known coordinates) on picturebox when the form is loading. Following is the code I wrote in my Form_Load event. Private Sub frm_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Load PictureBox1.Refresh() Dim g As Graphics = CType( PictureBox1, PictureBox).CreateGraphics Dim myPen As New Pen(Color.Red) myPen.Width = 2 g.DrawLine(myPen, 0, 0, 100, 100) myPen.Dispose() g.Dispose() End Sub But it's not displaying the Line when t…
Last reply by dhj, -
-
- 5 replies
- 12k views
--Using [VS C#.NET]-- Given an Integer value (nOffset) which originates from a 2-byte message. I need to do the following: - Extract the Least Significant byte (LSB) from the Integer (nOffset) and store it in an array (baArray[0]) by bitwise-anding nOffset with 0x0F (0F in HEX) - Bitwise-Shift the Integer (nOffset) by 8 (to move the MSB to the LSB of the Integer) - Extract the new Least Significant byte (which was originally the MSB) and store it in the array (baArray[1]) by bitwise-anding nOffset with 0x0F (0F in HEX) Currently I have the following code: :: CODE :: // Load LSB and MSG in Byte-Array baArray[0] = nOffset & 0x0F; nOffset = nOffset…
Last reply by Shaitan00, -
- 0 replies
- 1.1k views
Hello, I'm using the System.Xml.Serialization for serializing/deserializing objects. Now I thought that using ID and IDREF automatically worked? But when i use them, it simply loads a new instance of the object rather than the one referenced by IDREF. Can anyone help? Is this something I have to code in myself? -Hypnotron
Last reply by Hypnotron, -
-
- Leaders
- 1 reply
- 886 views
Hello! Is there any way to use MonthCalendar, but in "smaller" mode (like the dateTimePicker control for example)? I have a win form that is full of controls, and I wish to keep the space on it, and only when I need, show the MonthCalendar control. Thanks! Tom.
Last reply by snarfblam, -
-
- 2 replies
- 1.2k views
In last week's Code Project Newsletter there was a poll asking the question "How many people do you program with?" Nearly 50 (48.9) percent of the 1754 respondents selected the "I Code Alone" option. Two to four person teams were the runner up with 22.3 percent of respondents making that selection. In fact, all respondents that made selections from "one other person" to the maximum of "more than ten" only add up to 46.5 percent. As one who codes alone, I find this a little disheartening. Though I have some proven projects under my belt as the lone developer, I have no formal software engineering education and know that I would only benefit from peer review and su…
Last reply by michael_hk, -
- 1 reply
- 905 views
What would you guys say are the best books for a beginner to learn ASP.NET? I'm mostly interested in Web Applications. I was at Barnes & Noble yesterday taking a look at some books and thought Karl Moore's bookr of Tutorials was pretty good. I'm looking mostly for tutorials since I learn much faster and better with tutorials since it's more hands on. Thanks in advance for any suggestions, and I'm sorry if this is not the right forum for this question.
Last reply by michael_hk, -
- 1 reply
- 835 views
I've been tinkering with the whole n tier "business layer" concept for a few months now. I found two articles that I really liked so I've tried to combine the two. The reason for not using one or the other is that I really prefer to let the dataset/dataadapter object communicate with the database for updates, inserts, deletes but want a collection to deal with validation type things etc.... http://www.microsoft.com/belux/nl/msdn/community/columns/hyatt/ntier2.mspx http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnadvnet/html/vbnet02252003.asp Now my problem as i see it, I'm sure others could find other problems, is when to use remove or delete…
Last reply by barski, -
- 0 replies
- 927 views
Hi guys, A couple of questions in one post. Sorry about that...... 1) Connection Strings..... When im building a windows Application in dot net, I want to add a connectionstring into my app so that I do not have to keep making the connection everytime I call it. Like when you set a connectionstring in the global.asax file in web application. Firstly, is this possible and secondly can someone provide an example? 2) Log in form. I have built one but is there a template type one somewhere. Basically, when i log in, I want to store the user_id somewhere so I can say Welcome user_id when I log in. Any help is appreciated as always. Andy
Last reply by andycharger, -
- 1 reply
- 1.2k views
Here is my situation: I have a bunch of installation EXE files that I have created using InstallRite. For those who don't know, InstallRite creates quiet installation programs that run quickly for deployment, instead of running the standard installation setup for each application. I am creating a front end in Visual Basic .NET for these EXEs that will let the user pick which programs they want to install. I am to the point where I can produce a list of the EXEs that the user selected. But what I want to accomplish is this: I would like it to run the first installation that the user selected. Once that one finishes, and the installer closes, I'd like my progra…
Last reply by coldfusion244, -
- 2 replies
- 1.6k views
I continue to search for a .net developer job and so far I havn't found anything. I'm constantly getting my hopes up and then dashed again. I keep seeing headings like ".Net Developer Needed" "VB.Net Developer wanted", etc. Then you click (or read further for you non-technical job searchers) on the ad and it's like "looking for someone who can develep .net web pages" !? Sometimes you get "Looking for ASP.Net developers" in the description... I'm probobly just whiney, but I think it's annoying to see "VB.Net Developer Wanted" and then click on the add and it's for ASP.Net. True, some just advertise ASP.net. Where I am (NY) it seems that there are MUC…
Last reply by AFterlife, -
-
- *Experts*
- 2 replies
- 2.4k views
Hi! I have a program in Visual C++ .net that fills up a triangle with ellipses. I need to be able to change the colors of each ellipse within a loop, calculating different RGB values each time. Any idea on how I can change the brush color using the new RGB values each time? Thanks!! Jenn
Last reply by SamuraiJenn, -
-
Who's Online 0 Members, 0 Anonymous, 72 Guests (See full list)
- There are no registered users currently online