Topics
-
-
- Leaders
- 1 reply
- 921 views
I have a ListView on Form1 that I update on different times. My problem is that when I am in function Test() I need to call the function UpdateListView. The only way I can this is to make UpdateListView static, but then I get the error "An object reference is required for the nonstatic field method". How do I solve this problem Class Form1 { X x = new X(); TestListView() { x.Test() } UpdateListView() { listView1.Items.Add } } Class X() { Test() { How do I call UpdateListView } }
Last reply by snarfblam, -
-
-
- Leaders
- 1 reply
- 1.5k views
Hi all, I'm having a problem determining if the "New Hardware Found Wizard" is currently running or not. Without going into the long details, my app installs the drivers for a hardware key during the initial run. After the drivers are installed, the app opens and functions normally. For whatever reason, the newer drivers appear to require anywhere from 5 seconds to nearly two minutes (machine speed not related) to run the �New Hardware Wizard� and find the USB hardware key. In previous versions, this never took more than seconds. The current install shows a dialog �no key found, try again?�. Instead of having the end user keep hitting yes, or selecting no wh…
Last reply by dynamic_sysop, -
-
-
- *Experts*
- 1 reply
- 2.6k views
Hello, I have a very clear question. How to Print An Image In VB.Net? I will be very happy if you can help me. Thank you very much.
Last reply by DiverDan, -
-
-
- Administrators
- *Experts*
- 2 replies
- 10k views
Hello, I want to find out how can I run a .exe file from my code? for example, I want to run the file "E:\program.exe" whenever a specific button on my form is pressed. I will be very happy if you can help me. Thank you very much
Last reply by DiverDan, -
-
-
- Administrators
- 1 reply
- 2.6k views
Hey everyone, I've been messing around with some of the API's and trying to get them to work. Can anyone show me how I would use the FindWindow and the FindWindowEx Api to get all Windows and the child windows that are currently running on my computer using these two methods. I've got the FindWindow method working if I specify a particular window, (ex Untitled - Notepad). I'm just wondering how do I get all Windows and their appropropriate child windows if I have don't know the names of the windows. Private Declare Function FindWindow Lib "user32.dll" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Integer Private Declare Function …
Last reply by PlausiblyDamp, -
-
-
- Administrators
- *Experts*
- 14 replies
- 2.2k views
I am having a problem trying to delete a file from within VB.NET. Below is the code I have now.... Can somebody tell me why the deletefile is not accepted. I know you can do a savefile or loadfile... How can i set it to delete a file? Thank you Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click 'Delete Monday Third Shift Job Number Dim textbox3 As String If textbox3 = "4535" Then Dim selecteditem As String = CStr(Me.ComboBox3.SelectedItem) Dim selectedjobnum As Integer = selecteditem.Substring(selecteditem.IndexOf("#"c) + 1) 'Proce…
Last reply by SimDuck, -
-
-
- Administrators
- 2 replies
- 1.1k views
I have a web page in C# 2.0 that i made using studio 05. This page has a user control in it with a button on it. I want the page to be able to tell when the button in the user control is clicked. Can this be done? I googled it and found a few conflciting articles about what event bubbling is as opposed to event delegation. All of the sample code I found was for asp.net 1.1 Folks were adding event delegations in the code. Correct me if I'm wrong but that has changed significantly with the partial class code model, hasn't it? I mean I can't even see my InitializeComponent code can I? Where is the rest of the partial class? Is it created in memory at runtime? If so how…
Last reply by VBAHole22, -
-
- 6 replies
- 3.2k views
I have a previously selfcreated user-control which contains a picturebox and some additional code, also included is a method that changes the displayed Image in the Picturebox on Clicking. This works fine so far. Now I place this user control on a new form and i want it to fire a Click-Event on my form when a user clicks it. The Image in the Pictuebox changes on clicking but the Eventhandler on my form doesnt fire anything on clicking! I need a possibility for the users of my user control to write their own code for a click-event on that control. I read about the possibility to bubble events from a user control to its parent control but it was related to web …
Last reply by VBAHole22, -
- 2 replies
- 732 views
I am looking for a new company to host my site. My current company "uplink earth" is bad. They do not have anyone on staff that knows how to answer technical questions, they have no one that can answer coding questions, and they don't even know what ASP.NET 2.0 is (much less when it will be implimented). All I want is a personal website where I can practice new techniques using ASP.NET, C#, SQL, etc. I already have my own domain name, and I would like to be able to experiment with things like ecommerce solutions at some point. Could I have some feedback from some of you out there that have ISP Hosts that you are particularly proud of? What is the yearly price? Why a…
Last reply by joe_pool_is, -
- 2 replies
- 943 views
i have a class that I've tried to make into a datasource with the wizard. when I do a debug.writeline and step through the each row in the ex: For Each oemail In oEmails Debug.WriteLine(oemail.EmailAddress) Next i see my 27 rows of data. however, when I drag the "Email" datasource as a datagridview to my form.. the data isn't showing up in the grid. What am I not doing that the two are not wired together. I looked in my EmailBindingSource and it says that the datasource is Email... but it's still not working.. also.. when I drop the datasource on the form... no lines of code are added.. I don't know there there are suppose to be any.. but figured I'd…
Last reply by jvcoach23, -
-
- Administrators
- 2 replies
- 722 views
Where can I find out how to do the things that I used with the older ASP.NET Framework? (v1.1) For example, ValidationExpression and onfocus appear to no longer be supported in Visual Web Developer 2005. What have they been replaced with? I used to use ValidationExpression to test email addresses in an <asp:textbox> field: ValidationExpression="^([a-zA-Z0-9_\-\.]+)@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.)|(([a-zA-Z0-9\-]+\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\]?)$" Also, onfocus is a neat piece of javascript, but the new IDEs give a warning that this is not a valid attribute: onfocus="if(this.value=='Enter Text Here')this.value=''; Are these functions …
Last reply by joe_pool_is, -
-
-
- Administrators
- 13 replies
- 1.2k views
Ok, This is for a school assignment. All you need to know is that the user of the program enters values into an input box and then those values go into a listbox with its sorted property set to true. When you enter a 2 digit number it sorts by the first digit and not the second. Is there a way to sort the numbers by their value instead of just the first digit. For Example the listbox would show: 1 12 2 3 35 5
Last reply by PlausiblyDamp, -
-
-
- Administrators
- Leaders
- 4 replies
- 552 views
An application which I have been working on recently started throwing up this error message whenever I try to debug it, has anyone got any idea what it means? An unhandled exception of type 'System.OutOfMemoryException' occurred in system.windows.forms.dll Additional information: Error creating window handle. Stepping through the code shows the constructor of the form steps through correctly, but then it crashes out as soon as entering the Main() method.
Last reply by Cags, -
-
-
- Leaders
- 3 replies
- 2k views
I'm making a tool for one of my computer games and I need to do some drawing on top of a bitmap. I can't make it black because the bitmap might be black. I can't make it white because the bitmap might be white. Is there someway to set a Pen or a Brush to draw an inverted color?
Last reply by Diesel, -
-
- 5 replies
- 886 views
I have two identical pages that list out the contents of two different folders with hyperlinks to each file. One works, the other doesn't. On the one that doesn't I get this error: "Control 'dgFiles__ctl24__ctl1' of type 'DataGridLinkButton' must be placed inside a form tag with runat=server" There are 29 files in the folder with the page that doesn't work. If I set the page size to "20" I get the error above, if I set it to "15" I get the same error but the Control is 'dgFiles__ctl19__ctl1'. If I set the page size to "30" (one more than the number of files in the folder) - it works. The other folder with the same type of page has hundreds of files in it and the paged…
Last reply by bri189a, -
-
- Leaders
- 7 replies
- 846 views
Does the .Net framework have any built-in support for joining arrays? I couldn't find anything useful, and the things I tried didn't work. Is the only way to do it by adding each individual element? byte[] bFirstArray = new byte[6] { 1, 2, 3, 4, 5, 6 }; byte[] bSecondArray = new byte[6] { 7, 8, 9, 10, 11, 12 }; byte[] bThirdArray = null; //bThirdArray = (byte[])(bFirstArray.ToString() + bSecondArray.ToString()); //Doesn't work. //bThirdArray = new byte[] { bFirstArray, bSecondArray }; //Doesn't work.
Last reply by Legend, -
-
- 1 reply
- 704 views
I have a datagrid that loads a dataset when the form is loaded. It displays all of the rows just fine. I am trying to filter rows using a Combo Box List. The Msgbox displays the correct string value selected from the Combo Box. When the dataset is filled with the filtered query in the code below, no rows are displayed in the datagrid. Can anyone help me with this problem. Thanks Here is my code: Private Sub CboBxLocations_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CboBxLocations.SelectedIndexChanged If CboBxLocations.Text = "All Locations" Then strSelectLocation = "" Else …
Last reply by meduffy, -
-
- Administrators
- 6 replies
- 967 views
So the MSDN disk for VS.NET 2005 arrived on Tuesday, I got a fresh build of a top-notch laptop from the helpdesk, and loaded VS.NET onto it and proceeded to start loading all my 2003 projects to see what would happen. All the windows ones load with no problems and even run - the biggest one needed a couple of minor tweaks to fit with the new rules in Vs 05. Then I loaded up a pretty big ASP.NET project. This is a nightmare. I build and it says no errors, but 3 warnings. I look at the warnings and they are all minor "Variable x is used before it has been assigned a value" type errors. But whenever I build it turns the warning into an error. So I fix the 10 warnings it …
Last reply by samsmithnz, -
-
- 2 replies
- 1.5k views
i have to create a number of objects. they could be forms or any object really, but i want to know is how do i create a new object when a user clicks a button? the user could click the button many times, creating many objects, and i dont want to limit the user by only declaring a set number of objects
Last reply by GMan_NC, -
- 3 replies
- 905 views
I'm trying to update a SQL db using ASP.NET but I keep getting the following error: "Line 1: Incorrect syntax near '?'. Line 1: Incorrect syntax near '?'." Here is my code: Dim di As DataListItem Dim cmd As New SqlCommand("UPDATE YPVerification SET [MEMO] = ?, [sTATUS] = ?, [DATE_VERIFIED] = ? WHERE IMG_ID = ?", objConnection) Dim param As SqlParameter Dim rbList as RadioButtonList = E.Item.FindControl("rbList") Dim CurrDate as New DateTime() CurrDate = DateTime.Now Dim strCurrDate as String = CurrDate.ToString di = E.Item cmd.CommandType = CommandType.text 'Update parameters param = cmd.Parameters.Add("?", SqlDbType.Char) param.Value…
Last reply by Diesel,
-
Who's Online 0 Members, 0 Anonymous, 56 Guests (See full list)
- There are no registered users currently online