C# - Tell Which Tab Are Moving From/to In A .NET Tab Control?

Aug 24, 2009

I need to determine which tab the user is coming from, and going to, when they switch tabs, and possibly cancel the switch. I have tried the Deselecting, Deselected, Selecting, Selected events, and all of them show the e.TabPageIndex to be the same as the sender.SelectedIndex.

Is there an event, or property, that I can use so that I can determine both sides of this, or do I have to hack something together with caching it from one event and using that value in the new event.

I am trying to avoid handling the Deselecting/Deselected events and caching the value to use in the Selecting event. I already know I can do this, so I am asking if there is a cleaner way, without doing this.

I have tried in both C# and VB, with the same results (no surprise).

View 6 Replies


ADVERTISEMENT

VS 2008 - Draggable Control And AutoScroll - Allow Moving A Control On A Form At Run-time

Dec 26, 2009

The following code works perfectly to allow moving a control on a form at run-time. However, when AutoScroll is set to True on Form1, and you drag Button1 past the right and/or bottom bounds of the form, it goes haywire. I really need someway to smoothing control the autoscroll so that as you scroll the control off the form, the scrollbars smoothly appear.

[Code]...

View 1 Replies

Moving Towards A Control

Aug 27, 2010

I am just wondering how you can move a control toward the another control in VB.net. I have searched everywhere and cannot find a solution.

View 18 Replies

Moving Form Via Control

Mar 13, 2010

I was putted an image on the form (and filled) How to move form with click to image?

View 2 Replies

Moving Into Monthcalendar Control?

May 9, 2010

I am using the monthcalendar control, i want to change the selected date in the control and i want to the control move to this date

View 7 Replies

Moving Control(Label) Around A Circle?

Oct 27, 2009

I have created a simple circle on my Form with this code

Private Sub DrawCircle(ByVal cp As Point, ByVal radius As Integer)
Dim gr As Graphics
gr = Panel1.CreateGraphics

[Code]....

I have a timer and a label on the form , and i want that label to circulate around that circle on each tick of a timer.

View 8 Replies

Moving To The Next Cell Down In The Datagridview Control?

Dec 8, 2009

I have a datagrid control on my form that receives data from a device on the COM port. I strip out the data I need and put it into the currently selected cell. When I load the grid, I find the first empty cell and set the focus so each load presents the user with an empty cell to start receiving data. Once I get the measurement, I need to move to the next cell down (like hitting enter in the grid). This will allow the user to do measurements with the external device without having to move to the next cell.

View 6 Replies

Moving WPF Control At Run-time With Mouse

Jan 11, 2010

i have a window in wpf and i add a couple of control at run time. Now i wanna be able to drag & move them around the window. Could anyone post some sample code how i can achieve this? (coding in vb.net)

View 3 Replies

VS 2008 Moving A Custom Control

Feb 1, 2010

I have a panel that has 9 pictures boxes within it. I need the User to be able to create as many instances of this control as they like.

Then each control needs to be able to move freely within the form.

I've created the control and added the appropriate code to move it around the control.

I've made the control canvas the same size of the panel. The problem is that when I move the panel, it only moves within the bounds of the control canvas. I guess I could increase the size of the canvas, but then additional controls would still only be able to move within their bounds and it would come out all wrong.

Is there anything I could do about this? Or is there a better method?

View 8 Replies

Control Moving Between Record Thru Binding Navigator?

May 27, 2009

i want to control the functionality of moving the records thru binding navigator in vb.net

for example, on click of next button in navigator, i want to check some condition, if condition is true then move to next record otherwise don't move.

View 9 Replies

Dynamic Control Creation And Moving Of Those With Mouse?

Jan 22, 2012

I am trying to make a program that will include a drag/drop view where you can arrange objects around in a view and add/delete objects as needed (objects are actually controls I create dynamically), I have made some code which I include below.If I run this code it works but not the part when I click on a newly created control, then mousemove function is not used, I should be able to move controls using the mouse functions..but these do not work. I thought code like:

AddHandler logicif(i).MouseMove, AddressOf logicif_MouseMove

should work! Can anyone give me pointers on what I am missing?

Public Class Form1
Dim logicif(20) As Panel
Dim count = 0

[code]....

View 2 Replies

Moving Child Control Within Bounds Of Parent

Nov 27, 2009

I need a solution to move a child control with in the bounds of a parent control means I had a panel with 300*300 pixels and I had to move a textbox within the panel how?

View 2 Replies

VS 2008 Different Method Of Moving A Control Every Specified Interval

Jun 11, 2010

I'm using the following method to move a picture box that is in a 24, 24 panel:[code]This is obviously the worst way of doing this. But, it's the first thing I could think of and Googling has brought me no luck so far.

View 3 Replies

Asp.net - Moving The ScrollBar To The Selected Node In A TreeView Control

Mar 19, 2010

I have a treeview control where I am dynamically selecting a node depending on user interaction. when a node is selected I want to be able to have the scrollbar go to the location of that selected node in the tree. The scrollbar is simply made by overflow:auto in the div tag where the treeview is located. Can someone give me some detailed code to accomplish this?

View 1 Replies

Moving A Button Control Based On GridView Height?

Feb 16, 2011

I have a GridView with a button located beneath it. The GridView's height is set dynamically. When the height is set, it displays on top of the button. What I want to do is move the button down so it still displays just below the GridView when its height is changed.I know I can just set the location of the button, based on the height of the GridView, but is there a way to link the height to the location of the button? Like anchoring the button to the bottom edge of the GridView.

View 1 Replies

Moving And Resizing Custom Control At Runtime In Datagridview?

Nov 25, 2010

i'm attempting to develop a calendar using datagridview where column headers are dates and row headers are list of employees.

i would like to add a button/custom control on the datagridview to represent a task over time where I can move or resize at runtime.

View 4 Replies

Moving Through Unbounded Datagrid View With BindingNavigator Control?

Sep 30, 2010

i have a data grid which is populated with codes not bound and a binding navigator as well which is also not bounded to any Table adapter but i want to be able to move through these items with the navigator. That is if i click on the next button i move to the next record in the grid

Me.ApplicantsDataGridView.CurrentCell = ApplicantsBindingNavigator.MoveFirstItem

View 1 Replies

VS 2008 - Moving Label In Different Directions Inside Panel Control

Apr 8, 2010

How to move a label up, down, left, right inside the panel control? The label should move up when I press a "button for up", the label should move down when I press button "button for down".

View 9 Replies

Making Moving Percentages Into A Moving Graph?

Oct 5, 2008

I have this:

Private m_PerformanceCounter As New _
System.Diagnostics.PerformanceCounter( _
"Processor", "% Processor Time", "_Total")

[code]......

View 4 Replies

VS 2008 Find "Moving" Control In 3rd Party App

Apr 8, 2011

I've completed projects similar to this in the past but this one has me stumped. Trying to retrieve text from a text box in a third party application. Using SPY++ I found that this control is the second control in the list so I coded the following: Dim parentWindow as integer = windows.ReturnWindowHandle({windowname})

If parentWindow > 0 then
Dim childWindow as integer = FindWindowEx(parentWindow, 0, Nothing, {child window name})
Dim field as integer = 0

[Code].....

This worked great. Closed the app, came back the next day and this same code did not work. Used spy++ and found that the control had moved to the 4th position. Closed it, reopened it, this time it moved to the first. What is the best way to find this control each time when there are are 50+ controls on the screen and they all appear in spy++ like this:

Window 0022063A "" Edit
Window 00270652 "" Edit
Window 001A0630 "" Edit

and they continue to rearrange themselves each time the application is closed and reopened?

View 3 Replies

Moving From .Net To C#?

Dec 1, 2009

I'm seriously considering moving from VB.Net to C#. If you made the jump to C# from vb.net, then what were the best resources you used to learn the language going from novice to pro?

View 9 Replies

Moving From 32-bit To 64-bit?

May 16, 2012

I am in the process of moving my Visual Studio development from a 32-bit to a 64-bit system I have set up VS 2008, and copied my build files from the 32-bit system over to the 64-bit system. The program builds OK, but whenever I try to openone of the child forms from the Main form, I get a COM error message (component not registered)

View 8 Replies

Moving From C# To .Net?

Mar 8, 2009

So as a direct result of this global financial hoohar I'm going to start a new job as a VB.net developer tomorrow. Up to this point I've been developing in C# (bit of java, vb6, sql, tibco, etc. here and there)

So the question is this, what are the gotchas to look out for and does anyone have any good advice on writing good vb.net code?(Any other advice on coping with a salary / prospects drop welcome but not essential Just a quick update, company seems really good, current code base appears to be of a very high quality.Am starting to adjust to the VB way of doing things (can't stop myself adding semicolons everywhere though!).

View 8 Replies

'True' Control Transparency - Control With Motion Graphics (simplicity, A 'video Player' Control)

Dec 29, 2010

Here's my situation: I have a control with motion graphics (for the sake of simplicity, a 'video player' control) in my project. Think of a PictureBox with constantly-changing images. In front of this will sit a second control (such as a second PictureBox of the same dimensions). The topmost PictureBox will be drawn to in its Paint event.

I need to draw very few elements, and the bottom control is updated much more frequently than I need for this drawing. So these elements are drawn to the topmost control. Think of a news broadcast, where they have live video in the background, with a news channel logo, news ticker, and sometimes gradient visible in front.

I'm trying to create that 'foreground' control, and the closest I believe I have gotten so far is the following:

Imports System.Drawing
Imports System.Drawing.Imaging
Imports System.Drawing.Drawing2D

[CODE]...

The 'Opacity' property in the code above is a sort of "scaling factor." The image drawn to the top control may, in different parts of the image, have any alpha value from full transparent to a full 255. This 'Opacity' property is applied to the entire image being drawn, scaling the alpha values of each pixel.

See the following pictures for description:

[URL]
[URL]
[URL]

View 9 Replies

2010 - Moving On From VB6 To .Net?

Jun 21, 2010

I am finally making the move to vb.net after having supported VB6 apps all this time. I have been learning vb.net 2010 but am finding it difficult to find relevant information on the COM aspect. In VB6 COM was the dominating feature of the language, however, I can't seem to find relevant information on what has happened to COM in vb.net, does it still exist in vb.net, does it work in the same way or are apps designed in a different way in .net to do away with COM dll's?

View 3 Replies

Get A Box To Sit On A Moving Platform?

Mar 6, 2012

Am making a game for a college project, its just a mario like game except its a frog.

I want the frog to be able to jump on top of a moving platform in order to get to the other side. However the timer doesn't stop and the frog keeps on moving down. The moving platform has a separate timer called timer2 and the gravity timer is called timer1.

Here is a picture just to show you the game and the frog falling through the platform.

For some reason the moving platform leaves a trail of itself, be cool if you could also fix that for me hehe.

Here is the code for the 'collision '

If Player.Right >= platform.Left And Player.Bottom = platform.Top And Player.Left <= platform.Right Then
Timer1.Stop()
End If

View 6 Replies

How To Picture Box Moving

Oct 13, 2009

im making a game (board game) so i need to restrict the picture (character) from moving more than picture on a turn (alfter move is complete they have to press the end turn button, what would the code be for this? (the board is spread into box picturesI like

View 13 Replies

Keep Progress Bar Moving?

Jan 6, 2010

2008 Is there a way to keep a progress bar moving in a VB .Net windows application during long database calls (SQL Server - 10 seconds or so)? I tried a status strip progress bar running in matrix mode and a System.ComponentModel.BackgroundWorker running a progress bar but when the SQL call to a stored procedure is made they both freeze.

View 4 Replies

Moving A Picture From A Box To Another

Feb 25, 2011

Image1 is a picture box in child window and vImage is a picture box in parent window. When I open the child window for the first time, I see a complete blank picture in Image1 while at the same time vImage is having a picture on it. When I Hide and reopen it again It has the picture on it. What is the problem and how can I fix it in my Code?

View 1 Replies

Moving ECDSA From COM DLL To .NET?

Apr 2, 2009

I have an ActiveX DLL that uses ECDSACom from Dragongate Technologies to create a signature for a product license. The product, when starting, uses the signature generated, the public key and the license to check if the license is good.But now I'm changing to .NET and 64bit applications and the ECDSACom can't be used since is a COM DLL. Is there any library so I can check the signature (given the signature, data that was

View 3 Replies







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