Allow The User To Drag The Text Back And Forth From Labels

Nov 10, 2009

Im trying to allow the user to drag the text back and forth from labels. The code I have below seems to just show the little circle with a slash through it, and I cant drag or drop the text?

Private Sub Label_MouseDown(ByVal sender As System.Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles Label1.MouseDown, Label2.MouseDown, Label3.MouseDown
Dim lbl As Label = DirectCast(sender, Label)

[code]....

View 1 Replies


ADVERTISEMENT

Move / Drag Labels On A Form?

Jul 11, 2010

There is an image of a patient on the form.I have to mark the location of wounds on this picture.What I want to do is place 5 labels on a form.I am using these labels to mark the location of the wounds.these labels will be shown on the side of the form.the user can drag any one of the labels to a specific location on the image of the person.e.g face,head,leg.arm etc

Then I want to save the location of the labels in database so that when the record of the patient is retrieved the labels appear on the moved position.

View 1 Replies

Drag And Drop Element On Form With Labels

Mar 19, 2011

As I have been working on a project from a development book for self learning, I am having a problem with Dragging and dropping on my form. My form has labels that represent questions on one side and labels on the other side to be drag/dropped as the answers. I understand that under the element's properties there is Dragdrop and you can work with that, but how exactly do I actually make the element drag/drop? I want to be able to click and hold the element to drag drop, just as you would for reorganizing preferred settings or for my case of a drag/drop Q and A form.

View 3 Replies

Forms :: Implement Drag And Drop Using Labels?

Dec 5, 2011

I am trying to implement drag and drop using labels, when the label is to be dropped in location not currently visible auto scrolling should happen.

View 2 Replies

Instruct VB To Save These Values In The Text Property Of The Labels So That The Next Time The Program Is Loaded The Labels?

Oct 21, 2008

I created a program that has serval labels on a form and a listview object. It has a button that when clicked reads a textfile and loads up values in the listview object. I then can click and drag text from the listview box to any label on the form and then the program removes the value from the listview box. Now, my question is how can I instruct VB to save these values in the text property of the labels so that the next time the program is loaded the labels will contain the values loaded during the last run time session?

View 1 Replies

Changing The Back Color For ALOT Of Labels

Jun 21, 2010

I currently have

Private Sub LabelClick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Label14.Click, Label15.Click, Label16.Click, Label17.Click
If sender.backcolor = Color.LightGray Then

[Code].....

But there are ALOT of labels (about more than 300) and typing them out (or selecting them in the menu) consumes alot of time. Is there anyway to put the rest of them? I have about 8 groupboxes with these labels that need to be changed (there is another one that doesnt need this) so they are labels inside of groupboxes.

View 12 Replies

VS 2005 Labels From Back End Appears During Open And Save File Dialog?

Jan 12, 2010

I have a open and file save dialog which I use to open and save file. There are also some labels in the application. During the time a file is open or saved, the file open /save dialog becomes blurred by the background labels. Is there any way to prevent this? The attached pic is given as an example to explain the dilemma.

View 1 Replies

Allow The User To Drag And Drop Them?

Oct 20, 2010

I am trying to generate buttons and allow the user to drag and drop them.

I have this sub:

Sub Form1_MouseClick(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles Me.MouseClick
Dim nodebtn As New Button

[Code]....

Also if I declare the nodebtn as a global variable, I do not face this problem, the button is dragable. However when I click to add new buttons, no new button is generated, instead a button is generated with the count on it.

View 1 Replies

How To Count Labels To Display User Result

Dec 24, 2011

I've been working with my project. I make a quiz and I put check value for every label. If the user is correct the label with shows or else the label is in a hide status. My problem now is how do I count those labels to display his/her result. If there are 3 labels shown in the form in automatically the user got 3 points and that "3" with be put into a textbox...

View 5 Replies

Drag User Control Into Form?

Sep 15, 2009

How can i drag already created user control into a form? In a clear statement, i have created a user control. I need to use this user control 2 times and i need to drag it into a form.

I currently using vb 2008 express edition.

View 2 Replies

ListView Resize With User Drag?

Dec 8, 2009

I am converting my company's VB6 program over to VB.net and I have hit another stupid little roadblock.

The old program had a ListView docked to the left side of the application screen. The user could place the cursor over the right portion of the ListView, the cursor would turn into the SizeWE arrows, then they could drag it, which would resize the ListView.

I am trying to recreate this. As far as I can tell there is no Property called "Resizable," or at least nothing is popping out to me. I do not believe that it is being done in the code.

Is there a property I am missing? If not, is there an easy way to do this within the code? (ie. is there a event that would make my life easier)

I am using Visual Studio 2008.

Edit: I see how how it was done in the previous program (you always seem to find it once you ask the question, don't you?). The old program had a invisible picture that was only a few pixels wide that when hovered over would change the cursor to SizeWE. You could then drag that invisible picture and that would hit an event that would then change the size of the ListView. This seems rather convoluted. My question still stands: Is there a better way to handle this dragging and resizing?

View 2 Replies

VS 2008 - Saving To Text File Using Multiple Text Boxes And Labels

May 27, 2009

how to permanently save to text files then re-open all of the information again using SFD and OFD. Now my teacher has come back at me and said that i need to be able to save the information from multiple text boxes and have the text in certain labels to also be saved into the one text file (the labels need to be done because it is a database and these labels are like the fields and the right text box needs to match the right label)

View 39 Replies

User Control - Adding Internal Labels Inside It

Mar 8, 2010

I've made a user control and have added some internal labels inside it. In the User control class I'm trying to handle the mouse events so that: When the mouse enters the User-Control the background of the User-Control turns white - using MouseEnter event. When the mouse leaves the User-Control the background of the User-Control turns grey - using MouseLeave event. However as soon as I move the mouse over the internal labels it triggers the MouseLeave event. I don't want it to do that, because the mouse hasn't left the bounds of the User-Control! So, how do I get it to not trigger the MouseLeave event when the mouse is still internal to the User-Control?

View 9 Replies

Ability For A User To Drag An Area On Screen

Mar 14, 2012

i want to give the ability for a user to drag an area on the screen that they want and a that area to be print screened. or alternativly they click anywhere and that location is the top left of the box and then when they next click that location is the bottom right of the box and that box is print screened. [code]

View 1 Replies

Generate Buttons And Allow The User To Drag And Drop Them?

Oct 20, 2010

I am trying to generate buttons and allow the user to drag and drop them.I have this sub:Sub Form1_MouseClick(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles Me.MouseClick

[Code]...

Also if I declare the nodebtn as a global variable, I do not face this problem, the button is dragable. However when I click to add new buttons, no new button is generated, instead a button is generated with the count on it. Am I tackling this problem of drag and drop in the right manner or am I completely wrong at this.

View 11 Replies

C# - Integrate Picturebox And Labels Inside A Listview As A User Control?

Mar 1, 2010

I want to create a listview type user control which'll have a picturebox and a label inside each item. Is that possible?

View 2 Replies

Let User Back-up Their Data?

Apr 25, 2010

I am using VB.net 2003. I am working on a stand alone windows program that stores data in an Access database via ADO.net via MS jet 4.0 OLEDb. I have progress to the point that I would like to provide the end user the oportunity to back-up the data they have stored and re-install if they choose. I am envisioning a menu item for "maintenance" with sub-items for "back-up" and "restore". I can create the menu items, but I can not find any information on how the back-up should be done.

View 4 Replies

Drag/Drop/Mouse Events In User Class?

Oct 24, 2009

is it possible to link a personal created class with a Mouse Event? I created a class and I want to make it possible to make it interactive with the mouse. So when the user goes over the GDI-created shape (which is declared and created in that class), he has to see some information about that shape, like the name etc.... And the user has to be able to drag and drop that shape.

View 2 Replies

Make The User Be Able To Drag Around Picture Boxes Around The Form?

Oct 13, 2009

how can i make the user be able to drag around picture boxes around the form???

[Code]...

View 2 Replies

VS 2008 Let The User Be Able To Drag A Picturebox To One Of The Empty Pictureboxes?

Mar 17, 2010

I have an application where I have different picture boxes which the user can drag and move.I also have different empty pictureboxes.

What I want to do:I want to let the user be able to drag a picturebox to one of the empty pictureboxes. Also, If the user drags a picturebox to an invalid place (outside the bounds of any of the empty pictureboxes), the dragged picture box should return to its previous location.

So what I currently have is the usual drag-drop code and on the MouseUp event, I run this code (currently only checking for one empty picturebox):

If Not pbEmpty1.Bounds.Contains(Me.PointToClient(pbRemote.Location)) Then
pbRemote.Location = OldLocation
End If
(pbEmpty1 = Empty picturebox, pbRemote = picturebox that is dragged)

But it doesn't work, it doesn't care if the picturebox is inside the bounds of the empty picturebox or not, it still returns to its previous location...

View 4 Replies

(WPF) Drag + Drop To Allow User Sorting Of Stackpanel Elements Within A Scrollviewer?

Jan 8, 2010

I have good model (I think!) for how to allow a user to drag an element in a stackpanel and reposition it to another location within the stackpanel. However, my Stackpanel is placed within a ScrollViewer, like this (generalized):

[Code]...

View 1 Replies

C# - Make User Come Back To The Same Page After Login?

Oct 7, 2011

In asp.net 3.5, i am trying to send a user to a different https url to login, if the user is not logged in. I am kinda' restricting the user not to see the forum page in the current site (http://thisSite.com/forum.aspx), if the user is not logged in.I am not sure how to redirect the user back from the login page [url] back to the [url]

i tried placing response.redirect in my forum.aspx like this: response.redirect("https://somethirdpartysite.com"), but it's not behaving as expected.

View 1 Replies

DB/Reporting :: Allow User To Back-up And Restore Database?

Apr 25, 2010

I am using VB.net 2003. I am working on a stand alone windows program that stores data in an Access database via ADO.net via MS jet 4.0 OLEDb. I have progressed to the point that I would now like to provide the end user the oportunity to back-up the data they have stored and re-install if they choose. I am envisioning a menu item for "maintenance" with sub-items for "back-up" and "restore"

View 1 Replies

Asp.net - Some User Controls Not Loading When The 'Back' Button Is Pressed?

Dec 14, 2011

I'm working with ASP.NET and VB.NET. I have a page which contains 5 user controls. the page itself does nothing, it just presents the user controls to the user.

The user controls work fine when I come on the page, or when I refresh, but when I go to another page, and press 'Back' only two of my user controls shows up, and they don't work like they're supposed to!

Short description of the controls:

2 controls which look if the user has to create something and shows an option to do so. (goes to the DB)
2 controls show an overview if needed (goes to the DB)1 control looks if the user is an admin (does not go to the DB, but looks in the securityContext)

[Code]...

View 2 Replies

Making A Method Excute Right Before The User Gets Control Back?

Sep 17, 2009

I would like to make a method excute right before the user get back controle of the program. No matter what chain of events happens i would like to beable to have a method is always the last thing to excute. I plan on using the method to check the form and the data on it. I have no issues righting the method, I just don't know if their is a event or some other way to make sure it is always the last thing to excute. (Sorta like a validation method) Is their an easy way to do this?

View 5 Replies

Allows The User To Drag And Drop A Xls File Onto The Form And A DataGridView Fills With The Xls Sheet Data?

Mar 25, 2010

I have a VB .NET (VS 2008) application which allows the user to drag and drop a xls file onto the form and a DataGridView fills with the xls sheet data. The user than can apply changes to the data or add entries. Data integrity is checked during the load into the DataGridView (duplicates are removed and invalid entries are filtered out). After doing all this the user can click a button and the data is uploaded to a SQL server (2008) DB. I have a primary key set up (row number) and I have a compound key in the SQL table.

It is all working beautifully. Now here is my question:

I want to check for duplicate entries (between SQL server and DataGridView data) before the data is uploaded and commited to the table. What would be the most efficient way to that?

View 2 Replies

Save Text From Text Boxes And Reloading Back Into Them?

Aug 15, 2011

What i am trying to do is save text from a number of text boxes to a user named file then subsequently be able to reload the data back into the same text boxes at a later date.so far i have this which was provided for elsewhere on the web, this allows me to save comma delineated data to a file which is fine but i can't seem to reload the data. As an experiment i have just tried to reload it back into a rich text box to see if the process would work but nothing as yet.

Private Sub SAveToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles SAveToolStripMenuItem.Click
Dim savedfile As String
savedfile = TextBoxinc1.Text & "," & TextBoxinc2.Text & ","

[code]....

View 4 Replies

Put The Text Into The Labels?

Apr 21, 2011

I want to put the text into the labels.

Label1.text is "a",Label2.text is "b",................

How

Public Class Form2
Dim Labels As List(Of Label) = New List(Of Label)
Private Sub Form2_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

[Code]....

View 8 Replies

Calendar For The Current Month And Allowing The User To Go Back To Other Months?

Nov 8, 2009

I am writting software for a touch screen (windows CE) as well as a desktop pc (windows XP)I have the software working for both, but the problem I am having is the Calendar.I need a Calendar for the current month, as well as allowing the user to go back to other months.I was going to use the control in vb.net called 'MonthCalendar' but when I add it to the form and make the control bigger (as in font) it adds to months when viewed on XP but when I copy the exe to the touch screen it only shows the 1 month like its ment to.Is there a better Calendar control I can use or does anyone know how to make it so that it only shows 1 month in the 'MonthCalendar' control?I am using VB.net 2008

View 1 Replies

Force A User To Log Back Into To An Application If No Activity Is Detected For X Minutes?

Apr 22, 2010

I would like to try and implement a feature wherby once you have logged into an application (straightforward winforms application) and had your credetials verified the application would then force you to log on again if no activity had been detected in the application for a certain number of minutes. In essence I want to provide some extra security for those occasions when users get up and wander away from their machines for prolonged periods.

I have all the logic for logging into the application, it's just the checking for no activity over a given period and then forcing the user to log back in again that I'm not having much luck with.

View 2 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved