Make Main Form Large: Entire Workspace Less 10% Margins On Each?

Aug 24, 2009

How to make main form large: entire workspace less 10% margins on each side using vb.net.

View 2 Replies


ADVERTISEMENT

Entire Workspace Less 10% Margins On Each Side?

Aug 24, 2009

Dim workspace(1 To 4) As Long ' (1)=left (2)=top (3)=right (4)=bottom SystemParametersInfo &H30, 0, workspace(1), 0 ' &h30 = get workspace size Dim X As Long, Y As Long, w As Long, h As Long

X = workspace(1) * Screen.TwipsPerPixelX
Y = workspace(2) * Screen.TwipsPerPixelY
w = workspace(3) * Screen.TwipsPerPixelX - X
h = workspace(4) * Screen.TwipsPerPixelY - Y

Move X + 0.1 * w, Y + 0.1 * h, 0.8 * w, 0.8 * h ' 10% margins

View 2 Replies

Find A Workspace With The Same Object And To Create A New Workspace From Another Workspace?

Oct 16, 2009

I'm learning MVVM using the sample created by Josh Smith and I wanted to add a functionality of update.Two problems arise (not addressed in the referred question):What is the best and light way to create a workspace from another workspace?

View 2 Replies

Make Textbox Consume Entire Form?

Oct 23, 2009

I'm not sure if I stated that right in the topic, but I was wondering if anyone knows how I could make a textbox take up 100% of the form.

View 2 Replies

Make Variables Accessible To The Entire Form?

Feb 10, 2010

So I am making kinda of wizard, with options and a next buttons all in the same form but using hide and show.I have 3 of them. How can I make variables accessible to the entire form?

View 5 Replies

Make The Main Form Grey Out/translucent Black When A New Form Opens On Top?

Jul 9, 2010

How can I make the main form grey out/translucent black when a new form opens on top?

View 8 Replies

Make Printing And Page Margins?

Jan 13, 2011

I am printing a receipt with the following code:

Dim printFont As New System.Drawing.Font("Courier New", 10, System.Drawing.FontStyle.Regular)
e.Graphics.DrawString(sPrintText, printFont, System.Drawing.Brushes.Black, 10, 6)

[code]....

View 1 Replies

Make A Program That Has A Main Form

Jun 22, 2010

Im trying to make a program that has a main form(menu form) and when i click on the buttons another separate form will appear.

View 1 Replies

VS 2010 Make Classes Import Into Main Form.vb

Mar 20, 2012

I was just wondering how you can make classes import into your main Form.vb

Let's say I make a class with the following.

Public Class OtherStuff
Public Sub HideMe()
Form1.Hide()

[Code]....

How could I make the Form1.vb include the things that are in OtherStuff.vb.

All of the solutions that I have tried come up with the same error. Reference to a non-shared member requires an object reference.

View 2 Replies

Make A Module To Store All My Sub's For Populating A TreeView On My Main Form?

Jan 24, 2010

I decided to make a module to store all my Sub's for populating a TreeView on my main form. My question is, how do I make the Module.vb where I'm storing these Subs recognize the TreeView on my main form? I'm going to create subs such as this:

Public Sub Populatetest()
Dim _GeneralNode1 As TreeNode = TreeView1.Nodes.Add("Test")
End Sub

View 4 Replies

Make Label Visible On Main Form From A Multi Threaded Process

May 17, 2011

I am usng a multi threaded process to fire off a task, but when it is completed I want to make a label visible on the main form (form 1), eg "process completed", however the code I have in place comes up with the following error message;

Cross-thread operation not valid: Control 'lblCompleted' accessed from a thread other than the thread it was created on.

View 4 Replies

VS 2008 Make Main Form Inaccessible Until User Closes Dialog Box?

Apr 11, 2010

A program I'm developing launches dialog boxes to get information from the user. Right now, the user can still click on and manipulate the main form while the dialog box is open. How can I make the main form inaccessible until the user closes the dialog box?

View 2 Replies

VS 2005 - How To Set Margins To Print Out Image Of Form

Apr 20, 2009

As part of this project I'm doing for VB class I'm required to print out an image of the form. Anyways, the form is exactly 1024 x 780 so I have it set to landscape to fit better, but it still hangs off by an inch or so on the top and left margins. Here where I got the code from [URL]. I tried going under .DefaultPrintSettings and using Offset and Margins but changing them did nothing. I should also add that I know my printer can't print on every part of a page and that some of the image will be cut off, but I have been able to print within 1/2 inch of the edge of the paper before and when I print the form image it cuts it of at like 1 1/2 inches.

View 6 Replies

Can't Make The Search For The Entire Table In Sql?

Aug 13, 2011

this code get the data from the sql where the name = @word which is the variablecontaining the word to search for my problem is i want to check all the table columns not only one column ? is it doable ?

Public Function Search(ByVal word As String) As DataTable
Dim Dt As New DataTable
Dim Adp As New SqlDataAdapter

[code].....

View 2 Replies

Make Object Available Throughout Entire Application

Jul 28, 2009

I've recently began to use OOP in my application and now I'm stuck on how to use it properly.

View 2 Replies

Creating A Link From The Control In One Form To The Entire Nother Form?

Apr 12, 2009

I have another question (and anticipate that I will have about two more before I'm done with my class project). Here is my issue (and I'll copy and paste my code for clarification). I need to link up the control from the form on either side of the current form that I'm working on so that if I click on the buttons that I'm titling previous and next that I can click on the proper button and either go directly to the previous form or the next form. I was successful in doing this for two earlier forms on this project (with some direction from a couple of helpful people on this forum before), but for some reason, no matter what I details I use the controls do not connect to the previous and next forms.

Option Explicit On
Option Strict On
Option Infer Off

[code]....

View 4 Replies

Make Class Useable By Entire Project?

Aug 21, 2010

I created a class with a function. How can I make this class usable by other classes and other forms within my project?

View 9 Replies

Making A Workspace Window?

Nov 20, 2009

looking at some applications like excel and other ms office programs got me wondering: how do you create an area where windows open in but don't appear as separate windows on the windows bar? Basically my question is, is there any way to create a window workspace where new windows are opened but don't appear as an entire new window?

View 4 Replies

Make ListView FindItemWithText Match Entire Text

Jun 21, 2012

I have a ListView with two columns, and before enter a new item in the listview, I want to prevent entering a duplicate value, so I found ListView.FindItemWithText to accomplish that.

But I realized that if I enter 232323, and then enter 2323, which is different but starts with the same digits as the first entry, the function returns that item as a match.

I wonder if there is any way to match the whole text (exact text) to avoid the above.

Here is my code:

Dim ChkSIM As New ListViewItem
ChkSIM = lvItems.FindItemWithText("2323")
If Not ChkSIM Is Nothing Then
lblErrorSIM.Text = "Already in list"
End If

View 1 Replies

Mdi Child Form Order - Move The New Form Behind The Main Form While It Loads

Aug 5, 2010

i have my main child form open. then i show the new form:

[Code]...

but when the form opens it flickers a lot. so i want move the new form behind the main form while it loads so the user does not see the flicker. once it is done loading i will set the form to topmost. how do i move the new form behind the main form?

View 12 Replies

Disable An Entire Form?

Apr 25, 2009

I need to disable every control on my Form so that the user can not click or press any key that will change values of listboxes and other controls on the form. I need to be able to lock the whole Form like this because as part of the project I have to print the form 3times with 3 different colors and the only way I've been able to get it to work is with a timer. So for about 3 seconds the form is changing colors and printing itself, so in between that time the user could accidantely click something and change a value on the form when all three prints should be of the same form, only difference is in the color.I can't use disable as that will make all the controls look faded and messed up, I need a clean way to prevent anything from being changed.

View 39 Replies

Team Foundation Server - Check Out File Without Workspace

May 27, 2011

I have TFS url, and I have source File location, but I don't have Workspace path. How to Check out file without workspace, or how to find workspace for some file? I already make solution for checkout file in TFS, but in some cases I don't have workspace path or name.

[Code]...

View 2 Replies

Fade Entire Form Smoothly?

Jun 4, 2009

I'm trying to make my form nearly transparent when the mouse is not inside the form by changing the opacity.I'm having trouble because if the mouse is moved quickly, I can't get its position accurately. when the mouse is moved into a control, it's considered to have left the form. Is there an easy way to do this that I might be missing?

View 6 Replies

TopMost Form - Messages Form Would Be Hidden By The Main Form

Nov 20, 2009

I have a tool window that I want to stay above the main application form, but not stay on top of all windows forms. Similar to the floating properties window for visual studio - it always stays on top of the main VS window, but if I select another program, like internet explorer, the floating properties window will be behind internet explorer.

What I have is an application that has several forms that may be displayed at the same time. I have a Messages form that displays messages generated by the code in the form, that gives the status of the application. Obviously, the user would not normally be working on this form, but they may want it to be visible to see the status messages from the program (File saved confirmations, etc). So, my two options right now are I can set the form to be on top of all other windows forms or, when the user clicks on the main application form, the messages form would be hidden by the main form.

View 6 Replies

2008 - Print Entire Form On The Screen

Jan 15, 2009

I have a user who wants to print the form that is on the screen(the entire form not just the data) on the click of a button, is there a quick and easy way to capture it and print it. Kind of like a screen shot? I suggested that they could just do alt/printscreen and capture the form that way and print it but they want it all to be done from a print button for them.

View 14 Replies

Fitting A Form To Cover The Entire Screen

Sep 11, 2011

I have a program and wish to generalise its appearance at startup on different machines. This worked OK until I moved it onto a Windows 7 unit with a 22" screen. The front page covers less than 2/3 of the screen. I know I've asked the system for 'working area' but could not find a reference to the entire screen which other applications seem able to use. How can I catch up with them? The code is from VB in VS2005. Is this my limitation?

[Code]...

View 4 Replies

Detail Bound Form Updates Main List Form, But Does Not Update Data

Jan 29, 2010

I have a main form with datagridview containing a list of contacts:

VB
Public Class Form1
Private Db As New DataClasses1DataContext
Private Sub Form1_Load

[Code]....

After saving, I get the correct message ("Saved"), and the DataGridView in the first form gets updated in real time.

But... when I take look at the data (or close and reopen the forms) the data in the database (SQL server) have not changed! What happens!

View 4 Replies

Load The Main Form Of A WPF So That A Separate Thread Goes And Gets Data From The Database While The Form Is In An Apartmentstate?

May 15, 2012

How do i load the Main form of a WPF so that a seperate thread goes and gets data from the database while the form is in an apartmentstate? (drag-able / movable) I Know this is possible with opening a new window from your main form like this :

Private Sub openOrderWindow()
Dim OrderWindow As Orders = New Orders
OrderWindow.ShowDialog()
End Sub

[code]....

I've tried putting MyBase.ShowDialog() and .Show() and .9000+ other things The only benefit I've got out of using a seperate thread to load from the databse is i can see the screen right away (as oppose to it being a transparent box until it loads) but i cannot move it around or minimize it?is there any way to make it Movable while it loads?

View 1 Replies

Forms :: Form Settings - Check If File Exist On Main Form

Apr 29, 2011

[Code] I want like to check if a file exist on main form, if not: force open settings form. And then when the user is closing the form with exit button = check if the file exist again. If it doesn't exist, close application. It's a huge application and I need optimized on most parts. Also, the settings form is asking the closing question two times.

View 1 Replies

VS 2010 Sub/Child Form Close When Click On Main/Parent Form?

Jun 5, 2012

i am having some trouble in my Windows form application. i have 2 forms1st Main / Parent Form2nd Sub / Child Form (Menu)

View 7 Replies







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