Topics
-
i've just started tinkering with gdi and have a very basic question. attached is form class that fills a rectangle and it works but when i resize it the information from the original rectangle is retained therefore causing it to look less than great. any info on what i'm missing here would be nice.Form1.txt
Last reply by barski, -
-
- Administrators
- 2 replies
- 1.2k views
I downloaded the VB 2005 express edition and went right to work checking out the MY namespace for networks. The My.Computer.Network.IsAvailable returns an expected true, so hooking up to the newtork I went about making an applet to ping machines on my network. All appeared to be OK, I can ping with network AND machine up and connected, it seems to work fine. Disconnect the network, still fine. BUT shutting off the target machine STILL doesn't generate any error. Heres the code from MSDN: If My.Computer.Network.Ping("198.01.01.01") Then MsgBox("Server pinged successfully.") Else MsgBox("Ping request timed out.") End If I presume that the meth…
Last reply by gnappi, -
-
-
- Administrators
- 3 replies
- 990 views
I need to update a field in code using a method similar to the old adodb method of recordset.addnew recordset("field1")="eee" recordset("field2")="rrrr" recordset.update I am having trouble getting adonet to do something similar. I did research and was pointed to something like the following: Dim SQL As String = "SELECT * FROM table1" Dim cmd As New SqlCommand(SQL, ADOCnn) Dim DA = New SqlDataAdapter(cmd) Dim DS As New DataSet DA.SelectCommand = cmd DA.Fill(DS) Dim table As DataTable = DS.Tables(0) ' Use the NewRow method to create a DataRow 'with the table's schema. Dim newRow As Da…
Last reply by FZelle, -
-
-
- Administrators
- 1 reply
- 1.4k views
When I use SQL Server 2005 in my program, and When someone else wants to try my program, does he have to have SQL Server 2005 installed? Or can he run my program without SQL Server 2005?
Last reply by PlausiblyDamp, -
-
-
- *Experts*
- 4 replies
- 3.2k views
I can create a textbox and assign the control at runtime, and retrieve data with no problem. Is there a way I can assign one of my functions in my code at designtime as the event handler for the new control at runtime? In other words, I want to create a data validation keypress event, at designtime, and at runtime create a textbox and assign it's keypress event to the one in the module. Please help, thanks.
Last reply by Cags, -
-
-
- Administrators
- Leaders
- 8 replies
- 3.4k views
Hi Guys, How do i capture content from a browser based on a specific URL.. Lets say i navigate to google.com, how do i capture the whole content into a variable.. for some reasons im generating some xml file on server side, so i want my users to actually access the data from the window application.. Appreciate if some guidelines/reference can be provided to get me started with this. thanks
Last reply by a1jit, -
-
-
- Leaders
- 1 reply
- 1.8k views
I'm going to suggest an idea that I'm not even sure I like myself. Whilst I know the idea of these forums is to help people with any programming problems they might encounter, I would quite like to see a section allowing people to showcase their work. By this I mean a forum where people can post (or post links to avoid using up the forums bandwidth) applications/games they have made so other people can use them and post feedback. I say I'm not sure I like the idea because I feel it could easily be abused for advertisement purposes, as opposed to the intention of allowing amateur developers to showcase their work. I thought this suggestion might have been posted before,…
Last reply by snarfblam, -
-
-
- Administrators
- 2 replies
- 1.4k views
I'm using the code below to create an instance of a particular type, defined in the assemblyPath file. Dim objDLL As [Assembly] Dim objPlugin As Object objDLL = [Assembly].LoadFrom(assemblyPath) objPlugin = objDLL.CreateInstance(typeName) I am trying to change my application to be able to overwrite the .dll at assemblyPath without restarting. This code puts the .dll into use, so I can't overwrite the file after this stage of execution. Is there any way I can release assemblyPath so I can overwrite it without restarting my app? Thanks in advance.
Last reply by VPiattelli, -
-
-
- *Experts*
- 4 replies
- 1.1k views
I'm not quite sure why I'm bugged by this, but does anyone have an opinion as to why the .NET rules regarding custom Event Arguments is that the 'sender' parameter be typed 'As Object'? Why not strong-type it to the actual type of the sender? For that matter, why have a separate parameter at all; why not have it included within the 'e As EventArguments' parameter, and then the handler can utilize 'e.Sender' as needed? Any thoughts on this? For the life of me I can't think of one good reason for keeping 'Sender As Object' and so I'm thinking of strong-typing my Events... However, this would be non-standard, so I was wondering if anyone knew or could explain the ratio…
Last reply by Mike_R, -
-
- 0 replies
- 837 views
I have data that can be bound to a control. However, depending on types of records, I need to change how DIFFERENT fields (<td>tag) are displayed. For example, I have accounts and if the AccountType field is Total its number field should underlined and children of subheadings must be indented. I also need to allow user to change # of columns (time periods). I was using render blocks but this needs to be a re-usable control.
Last reply by onez, -
- 1 reply
- 2.9k views
(Abridged code for example purposes) Class ABC Public Property XYZObject() As XYZ End Class Class XYZ Property SomeValue As String End Class --- I have a combo box where I'm setting the DataSource to an array of ABC objects. I'd like to use the SomeValue property of the XYZObject property of the ABC objects as the DisplayMember of the combo box. When I try to do this (combobox.DisplayMember = "XYZObject.SomeValue"), it doesn't recognize it as being a valid property (combo box instead shows ABC.ToString(), which happens according to the documentation when the property can't be resolved) Is what I'm trying to do possible or can I only reference prop…
Last reply by Cags, -
-
- Leaders
- 5 replies
- 5.2k views
Hi again, I've got another quetion. In Visual Basic .NET, On your project properties page, you had an option to chose when the application should exit (when main form closes or when last open form closes). But I can't find this option in C#. How can I do this?
Last reply by MrLucky, -
-
- 1 reply
- 605 views
I've got a listbox. The listbox has a x count of items. If i press the button on one of it there is some code executed. But if number 2 is selected and i press the up or down keys. The other item is getting bleu.. but the code that should be executed doesnt. If i do the code (fill_customer();) on the onload part, it is executed, but for the old one, so it runs 1 event after. My code: private void lstKlant_KeyDown(object sender, KeyEventArgs e) { fill_customer(); } private void lstKlant_KeyPress(object sender, KeyPressEventArgs e) { fill_customer(); }
Last reply by Cags, -
- 2 replies
- 1.4k views
With a user control, or a class which inherits a control, how can I tell if the New() event is occurring in a designer at design time, or is occuring at run time?
Last reply by rbulph, -
- 9 replies
- 1.9k views
Hi I'm trying to create an negative image. This is the code I use to do it. I got it from the Bob Powell FAQ. private void button2_Click(object sender, EventArgs e) { if(this.pictureBox1.Visible == true) { Image img = this.pictureBox1.Image; Bitmap copy = new Bitmap(img.Width,img.Height); ImageAttributes ia = new ImageAttributes(); ColorMatrix cm = new ColorMatrix(); cm.Matrix00 = cm.Matrix11 = cm.Matrix22 = 0.99f; cm.Matrix33 = cm.Matrix44 = 1; cm.Matrix40 = cm.Matrix41 = cm.Matrix42 = .04f; …
Last reply by jo0ls, -
-
- Administrators
- 5 replies
- 2.6k views
Hi all I am attempting to use javascript to validate the data submitted by the user. I have a single textbox, a custom validator, and a validation summary control on my page. User should be able to place a numeric value in the textbox (I'm ignoring alpha characters at the moment), if the value is between 2 and 3, then the value is correct, otherwise I want to set the custom validator to false and display the error message in the validation summary. I have succeed in displaying the error in a javascript alert box, but I am unsure on how to move on with the custom validator. Here is the code I am using so far... function ValidateData(){ var data = document.…
Last reply by mike55, -
-
- 2 replies
- 1.1k views
I have a very simples user control for a user to enter a date. I know i should use the datetimepicket but i got this project where they already used this control. The control has 3 dropdownlists that are day, month and year. Each of these dropdownlists theere is a default value with a string saying Day, Month and Year respectavly. and besides that, the control does not see if the motnth has 31 ou 30 days. my problem is that i can only validade the date inputed pu the user after a submit and i wanna change that. I would like to be able to validate this before a submit, just like a asp.net validator does. any sugestions on how to acomplish this? P.S --> i p…
Last reply by rfazendeiro, -
-
- Administrators
- 9 replies
- 1.4k views
I'm building a Login sript zo people can acces the data base but need some tips or tutorials The user has to fill in a Username, Password, And the database he/she want's to acces.. now I Thinks I should load some session of some kind.. cause there are more then one departments.. with different rights.. whit this session or some kind of.. I let them go into the next form.. this form contains a Few buttons.. But if the user is from department A he can nog see all the buttos.. Same story for department B. should I use some kind of sessions? where do i put this sripting (a config form or in each form or the database trigger of view) hope you could me some…
Last reply by Voldron, -
-
-
- Leaders
- 1 reply
- 1.3k views
I building a winform C# project and now I want to use frames or some kind. I've noticed there where dockstyles that can be used but this is only for 2 frames. i'd like to call them frames. But in the dockstyle i can use top and bottom or fill.. but i need 3 frames, a bottom, middle and top. how can i do this. can this be done or should i use some other functions?
Last reply by snarfblam, -
-
- 0 replies
- 1k views
I have a datagrid that uses a template column. The column is basically a hyperlink to the page but with request variables. These variables are used to load a form at the bottom of the page. What I'm trying to do is go to the bottom of the page when a link is clicked on in the datagrid. I was trying to use an anchor but it only works without variables and for some reason I can't find an adequate solution. I thought about using javascript but what if the user does not allow javascript?? Is there another possible way to automatically have the screen scroll down to the bottom of the page?? Appreciate any assistance.
Last reply by jccorner,
-
Who's Online 0 Members, 0 Anonymous, 57 Guests (See full list)
- There are no registered users currently online