Topics
-
-
- Administrators
- Leaders
- 3 replies
- 2.6k views
how can i change the image of a picturebox control at runtime when mouse hovers it?? heres my code Private Sub hoverDiente(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles d1.MouseHover, d2.MouseHover sender = CType(sender, PictureBox) Dim tempStr As String = sender.name tempStr.Replace("d", "") MsgBox(Me.path) sender.Image = New Bitmap(Me.path + "\\path\\" + tempStr + ".jpg") End Sub so far i have an 'invalid argument' error when calling sender.image=new bitmap() thanks for your help
Last reply by snarfblam, -
-
-
- Administrators
- 2 replies
- 657 views
Here is my code what I am trying to do is manipulate strings with an array like this chpArr() contains a smaple of the following text 1-10 2-29 3-24 4-21 5-21 This represents the Book of 1 John where chapter 1 has 10 verses and 2 - 29 verses and so on with my code I am wanting to get the verses my problem with what I was trying is that with the single digit chapters it worked great but with 10 and above NOPE I know its because of how I was trying to trim and such Help appreciated Heres the code Dim vrs1 As String verseCombo.Items.Clear() If verseCombo.Items.Count <= -1 Then MsgBox("You must first choose …
Last reply by vbMarkO, -
-
-
- Administrators
- 4 replies
- 7.9k views
Hi, I don't know why but the text formatting doesn't work at all for the dropdownlist. The reader return whole integers and I want to add two quotes to simulate inches. 20 -> 20'' I tired putting it outside the loop, and inline (html), same results. If dr.HasRows() Then drpWidth.Items.Add(New ListItem("","")) While dr.Read() drpWidth.Items.Add(New ListItem(dr.GetInt32(0),dr.GetInt32(0))) drpWidth.DataTextFormatString = "{0:C}" End While Else drpWidth.Items.Add(New ListItem("No Data","")) End If Thanks * Um why aren't the code tags working? :/ The code is between them.
Last reply by Polar Bear, -
-
-
- *Experts*
- 4 replies
- 1.9k views
For all my past projects, I have been using a database class I wrote to do all my database updating (and retrieving) to and from MySQL. I basically have 2 commands, select and execute. My select function simply returns a DataTable. Therefore, all my changes must be made through the use of the execute function. Anyway, now I have a grid that I want to make changes to and then send all the updates to the database. I know you can bind everything, using a connection object, DataAdapter, and a DataSet and then use the DataAdapter's Update function, but I can't seem to figure it out. I would really like to be able to use my database class and just write some kind of updat…
Last reply by grip003, -
-
-
- Administrators
- Leaders
- 4 replies
- 1.5k views
Alright I want to make a simple start up program where I have a list of Names of Programs with check boxes next to them. I have it so if you click on the Yes button it uses if commands to open what ever program(s) were checked. The First Part - I want to add a button for OpenFileDialog so if a program is not listed, then a user can select the .exe file they want to run or a .doc file instead of just word, but I have it all worked out except for I can't open the file would anyone please tell me the code to open a file from an openfiledialog box, I know its simple but for some reason I am just missing something (It is more for other programs because otherwise I can ju…
Last reply by daveydave400, -
-
-
- Administrators
- *Experts*
- 3 replies
- 1.1k views
I have two classes: Friend Class clsItem Public Sub New(ByVal objId As Object, Optional ByVal objNr As Object = Nothing, _ Optional ByVal objCode As Object = Nothing, Optional ByVal objDesc As Object = Nothing) Try Id = objId Nr = objNr Code = objCode Desc = objDesc Catch ex As Exception InfoError(ex) End Try End Sub Private mobjId As Object Public Property Id() As Object Get Return mobjId End Get Set(ByVal Value As Object) mobjId = Value End Set End Property Private mobjNr As Object Public Property Nr() As Object Get Return mobjNr End Get …
Last reply by Nerseus, -
-
- 1 reply
- 2.1k views
Hi, I've had a look on the Microsoft website, but haven't really gotten anywhere with this..... so back to the best place to get a question answered - XtremeVB! I'm looking at the best way to do a Merge with Word, from a Dataset in .NET to a .dot template. The .dot template can contain a table which will have multiple lines (e.g. if it is Orders, the table will have one line with the fields in it, but will grow depending on the number of Order lines). At the moment I'm converting the Dataset to XML (using WriteXML), and using a component which opens up Word as a object, then replaces each field one-by-one. The thing is it's very slow, programmatically replacing a…
Last reply by pendragon, -
- 2 replies
- 819 views
Here is some code I wrote earlier today.... It opens a text file loads it into an Array then I am counting number of chapters and number of verses in each chapter then displaying it in an rtb. However, I am getting a repeating of of this for example over and over this specific chapter chapter 1 has 10 verses its displaying like this in my rtb 1-10 1-10 1-10 repeating the above numerous times LOL I know I am missing something simple ... but for the life of me I am not seeing why this wont work Dim frPath As String Dim ReadString As String Dim myText As String Dim cntArr() As String frPath = "C:\…
Last reply by Machaira, -
- 2 replies
- 1k views
Hello, I'm looking for a message Box which I could use in both Internet Explorer and Mozilla to help me display error messages of Validator controls in both types of browser. In fact the ShowMessageBox property of the ValidationSummary control works fine with I.E but not with Mozilla Browsers... If someone has an idea. NB : If necessary, VB samples are welcome.
Last reply by scalf, -
-
- Administrators
- 1 reply
- 1.2k views
Hello, I was wondering how can i build a program in VB.NET that can upload files to an FTP server. I am not very experianced at this sort of thing. PK
Last reply by PlausiblyDamp, -
-
- 4 replies
- 9.5k views
Hi I have a problem with the asp.net dropdownlist. I fill the dropdownlist with say a 100 items and when I go to select an item from the list the dropdownlist takes up the whole height of the screen and only show the items that are visible on the screen. There are more items on the list but they appear off the screen and cannot be seen as the vertical scrollbar never appears. I tried viewing this very same asp.net application from another computer and the scrollbar does appear for them. From this I came to the conclusion that it was a windows setting that was wrong, so I changed the theme of my computer to windows classic and now I can view the dropdownlist with…
Last reply by Road Runner, -
-
- Leaders
- 14 replies
- 2k views
I have findly got my Tool I have created to help automate the task of converting text in text files where the text looks like this 1:1: In the begining was VB 1:2: and they saw it was good 2:1: blah blah blah blah 2:2: more text on this line and so on '/// Hehe couldnt help myse;lf ...ofcourse the text is actual scripture :) anyway Its being converted in an RTB to look like this 1:1 Line of Text ' Note each chapter ofcourse has a diferent number of verses 2 Line of Text 2:1 Line of Text 2 Line of Text 3 Line of Text Now this brings us to what I need I need to be able in a button click to take the final result you see above and add this t…
Last reply by Nate Bross, -
-
- 13 replies
- 3.4k views
Does anybody know if there's a way of selecting a vertex of a 3D object using the mouse? For instance, I have a 3D view of a foot (I'm in the medical industry) and when the user drags the mouse over the shape I need to draw a point on top of the vertex where the mouse is pointing to, excluding the hidden vertexes. Does anybody know how to do that? Thanks,
Last reply by Reidar Lange, -
- 4 replies
- 1.4k views
I have a class that has a "RecievedData" event, this event returns the data that was recieved from a TCP Client. I would like to make a Collection of these classes and handle the RecievedData event. Public WithEvents cClient As clsClient Public Clients As New Collection Public Sub TCPListen() Randomize() Do Until bRunning = False tcpListener.Start() 'Accept the pending client connection and return 'a TcpClient initialized for communication. Dim tcpClient As TcpClient Dim TheKeyID As String = Rnd(300).ToString …
Last reply by Nate Bross, -
-
- *Experts*
- 1 reply
- 1.7k views
I was experimenting with running applications on a USB thumb drive today and figured, on a whim, that I'd try installing SharpDevelop directly to the drive to see what happened. I figured that it would crash and burn, especially running on a computer that didn't have the .NET Framework SDK installed. How wrong I was! From the short experiments I did, it seemed to run PERFECTLY on a computer that has never seen the .NET Framework SDK before. I'm sure the .NET Framework Redistributable is required, but most XP machines have that anyway, and you can always carry the installer for that along just in case. I've always wanted something that I could have with me to do pro…
Last reply by sgt_pinky, -
-
- 1 reply
- 1.7k views
In VS 2005 windows application. How to auto increment revision everything I complie?
Last reply by mskeel, -
-
- Administrators
- 8 replies
- 1.6k views
This code: Imports System.Data.OleDb Public Class Form2 'Global vars Private dbData(100, 3) As String Private dbPosition1 As Integer = 0 Private Sub Form2_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Debug.WriteLine(Application.StartupPath) Try Dim dbConnection As New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & Application.StartupPath & "\leadup1.mdb") Const sql As String = "SELECT TB_years, TB_names, TB_battles, TB_essays FROM leadup" Dim dbCmd As New OleDbCommand(sql, dbConnection) Dim results As OleDbDataReader D…
Last reply by PlausiblyDamp, -
-
-
- Administrators
- 4 replies
- 1.8k views
Have a bit of a dilemma and I'm wondering what type of opinoins are out there ... I have a piece of equipment that I communicate with via a serial port. Data comes in at a pretty high rate of speed and the data is in "packets" of varying sizes. I currently use the mscomm control as VB.Net 2002/2003 does not have built in comm functionality yet. The data comes into the mscomm control and I have a thread that is waiting for for data to be in the input buffer. Once the thread sees data there, it grabs it and moves it out of the mscomm buffer area. Sample incoming data looks like ... ------------ RX : 08 05 04 03 02 01 02 03 04 18 …
Last reply by PlausiblyDamp, -
-
Omr
by lothos12345- 0 replies
- 560 views
I am trying to develop an OMR(Optical Mark Recognition) Visual Basic.NET application, can anyone recommend a control I could demo, or some project I could look at for help with this applications development. Any help offered is greatly appreciated.
Last reply by lothos12345, -
- 8 replies
- 1k views
hi ti all, i have 3 files that are being converted to another format. in the end there are still 3 files so i was thinking it would be better to make a thread to treat them "simultaneously". I new to threading so i would like some help. I have 3 methods that i use to inicialice the threads private void Process1() private void Process2() private void Process3() private void btnLerFich_Click(object sender, System.EventArgs e) { this.trd1 = new Thread(new ThreadStart(Process1)); this.trd1 .Name = "Process1"; this.trd2= new Thread(new ThreadStart(Process2)); this.trd2.Name = "Process2"; this.trd3 = new Thread(new ThreadStart(Process3)); this.trd3 .Name = "Pr…
Last reply by rfazendeiro,
-
Who's Online 0 Members, 0 Anonymous, 59 Guests (See full list)
- There are no registered users currently online