Assign Default User Area?

Nov 26, 2011

[code]...But, when someone else runs it their user name won't be the same as mine, so only people with the account name ADAM would be able to run successfully Is there a code so instead of me putting adam there is a code that will choose the user that the program is being run by?

View 9 Replies


ADVERTISEMENT

App Returns To Default Settings When In New Area?

Jan 15, 2012

My Program changes it's My.settings to default , it looses the Location Where it is saved This only happens when i move to a new area But if i take a new builded exe and put it in same Dir of old exe then It Remembers old Settings?

View 7 Replies

User To Select Just Straight To Default Printer With Its Default Settings

Dec 3, 2011

I need to print the contents of 3 textboxs to default printer. what examples I have found dont seem to work. I was trying the documentprint1 component as i thought it would be easy but cant figure out how to tell it what to print the second part is to print a variable (string) to the printer as well.no need for user to select just straight to default printer with its default settings

View 1 Replies

Assign A Value To A Message Box For When The Default Value Displayed In The Text Box Is Unchanged?

Jan 25, 2012

How can I assign a value to a message box for when the default value displayed in the text box is unchanged. ie. If my default value is 17 and the user clicks ok without retyping a number, the Input value displayed in a textbox will be 0.

Currently I have:

Public Class Form1
Dim MyValue As Double
Private Sub But_EnterInput_Click(sender As System.Object, e As System.EventArgs) Handles But_EnterInput.Click
MyValue = CDbl(InputBox("Input a value", "Data Input", "17", 200, 400))

[code]....

This works however if the user types 17, the textbox will read 0. not what i want.

View 2 Replies

Assign Default Value When Declaring Boolean Vs Using Both Clauses Of An If Statement?

Mar 8, 2012

Which of the following is more readable and preferable?

This, where the default value is assigned in the declaration:

Dim isLastWeekOfPeriod As Boolean = False
If periodInfo.WeekCount = weekInfo.Week Then
isLastWeekOfPeriod = True

[Code].....

View 1 Replies

When I Create The User And Assign The Role, The User Should Get The Permission Automatically?

Nov 24, 2011

I need to define some roles in my program with defined permissions. Let's say the administrator can have access only to certain features. The officer in charge to certain features and the user as well. for example, I have several group boxes and the user can access one of it only. So how i do manage these permissions? What I want do is have the roles already with the defined permissions. When I create the user and assign the role, the user should get the permission automatically.

View 6 Replies

User To Choose Save Name And Area?

Apr 7, 2011

Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
'Creates a string that holds the path to your file.
'this path uses the Special Dir .MyDocuments
'so on my computer LogPath = "C:UsersTechNoHickDocuments"
'on your computer LogPath might = "C:UsersKirbyDocuments"
Dim LogPath As String = String.Format("{0} est", My.Computer.FileSystem.SpecialDirectories.MyDocuments)
Dim FileName As String = "test.txt"

[Code]...

I am using visual basic 2010 express and would like to know how i can use a text box of sorts or windows explorer function to allow a user to save a file to a location of their choosing.At the moment a folder and .txt file is created in the mydocuments folder of the user's computer using this code

View 2 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

Saving A File Into The End Users, User Area?

Jun 11, 2011

If I create a save a text file, how do I get my application to save it into the end users directory?

Ive current got this which saves into my user area.
file = My.Computer.FileSystem.OpenTextFileWriter("C:Users#####FruitFruit.txt", False)

View 6 Replies

VS 2010 Take A Picture Of An Area The User Chose?

Feb 8, 2011

screenshot function in my application. This is what I currently have:

vb
Dim bounds As Rectangle
Dim screenshot As System.Drawing.Bitmap

[Code]....

But instead of taking a picture of the whole screen, I want to just take a picture of an area the user chose. When the user presses the start point, I would like to have a rectangle drawn to the place where the user presses the end point. And then take the picture.

View 2 Replies

Adapt The Application Area To The User's Monitor Resolution?

Jun 16, 2011

how do I adapt the my application area to the user's monitor resolution?I have created a winForms application on 1280*768 resolution monitor and the application is generally used on smaller laptops (10inches). Now I need to a scrollbar on my entire application so that the spacing remains the same as I have designed. For this, there has to be a scrollbar (Both Horizontal and Vertical) on the application.

View 1 Replies

Wpf Custom User Control MouseleftButtonDown Capture Area?

May 23, 2012

I have a custom control with an event handler when you click on it. Everything works and the event get fired right.

AddHandler (cu.MouseLeftButtonDown), AddressOf Me.DoSomething

When the control resizes to show some extra information it expands. It also collapses when the user preses a button. This works alright. But now when I click where the expanded area used to be, it still fires mouse leftbuttondown on that control. I have tried to set IsHitTestVisible to false on the expanded element but it diden't work. Here's some xaml...

<UserControl x:Class="MyCustomControl">
<StackPanel>
<Grid>

[code]....

I cant use another element around my customcontrol since I also use this MouseLeftButtonDown on all different kind of controls.
I can't figure out how the boundaries on the cu.MouseLeftButtonDown event work to fix this.

View 1 Replies

Forms :: ComboBox - Stop The User From Clicking A Blank Area?

May 28, 2010

how to stop a ComboBox from displaying blank data?

The query I'm using does not allow nulls but the ComboBox is showing black areas and the user can click in those areas.

The PureComponents ComboBox did not show the blank areas but when I started to use the ComboBox from VS 2008 the blank areas are showing up.

The attachment shows me clicking in a blank area.

View 8 Replies

Assign User Name In File Path?

Apr 29, 2010

I'm am not primarily a visual basic programmer however I am trying shell and executable from a vb macro after a mail merge with the code below I found this function to get the current username which is rather verbose

Option Explicit
Declare Function GetUserName Lib "advapi32.dll" Alias "GetUserNameA" (ByVal lpBuffer As String, nSize As Long) As Long
Public Function GetCurrentUserName() As String

[code]....

IF I PUT MSGBOX " " & GetCurrentUser & "" I return the current user with no problem and if I hardcode the user name the shell function works with no problem however I am uncertain of the proper syntax to code the username into the file path ...After tinkering with it for half an hour I figured I should just ask someone who codes in VB !

View 3 Replies

Implement A Controlling Design Logic That Prompts The User For A Length And The Area To Calculate?

Aug 12, 2009

I am trying to implement a controlling design logic that prompts the user for a length and the area to calculate until he or she enters a number less than zero in the length to end.So far I have it where I believe it�s doing the calculations but it�s not ending when I input a number less than zero or zero.

Sub Main()
' Declare Length As Float
Dim Length As Double
' Declare s, c, t As Float

[code]....

View 4 Replies

Make A Program That Will Calculate The Area Of A Rectangle Based On The Length And Width Given By The User

Nov 20, 2009

im trying to make a a rogram that will calculate the area of a rectangle based on the lenght and

width given by the user

[code...]

View 4 Replies

Assign A Number From A Row The User Selects In A DataGridView To A Textbox

Jul 5, 2009

I'm trying to assign a number from a row the user selects in a DataGridView to a textbox. On the dgvProducts_CellContentClick event I wish to take whats in column(6) to a textbox.

[Code]...

View 1 Replies

Assign Icon To User According To Gender - Show In ListBox

Jun 7, 2012

I can't seem to find a way to accomplish this task - I would like to be able to show a List of usernames with a female or male "icon", depending on the Application Settings the user selects. I have the following properties listed in my Application settings:

[Code]...

View 1 Replies

VS 2008 Assign User Entered Text As The File Name?

Feb 27, 2012

I have a Form1 with TextBox1 and Button1.

Here is what I'm trying to do: When Button1 is clicked, I want an Excel file created and saved into a default folder (the user does not choose the folder...code for Button1_Click will choose the folder), and the file name will be the text that the user enters into TextBox1.

View 3 Replies

Assign User Chosen Hotkeys Whilst The Application Is Running?

May 20, 2012

I have an application which uses hotkeys which are to be defined by the user. It is a combination of 2 keys, either CTRL, ALT, SHIFT as one hotkey and the F* Function keys as the other (e.g. CTRL + F1, ALT + F2 or SHIFT + F8) As stated these are then chosen by the user before a global keyhook is put in place to listen for them and trigger an event. In my app I have all my function keys as follows:

Public Const VK_F1 = &H70
Public Const VK_F2 = &H71
Public Const VK_F3 = &H72

[code].....

View 1 Replies

Set The Viewable Area To A Smaller Screen Area?

Jun 11, 2012

Trying to set the viewable area to a smaller screen area and have it cycle through as the person moves using collision detection to move the backgroudn image. Here is the start but its off to a bad start so far.

Public Class Form1
Dim Mapx As Integer = 600
Dim Mapy As Integer = 2000

[code]....

Basically the forum size is set to 600x2000 but the client should only allow you to view 600x600. I want it to add +1 once you "collide with a invisable box I'll add and this will redraw the screen.

View 4 Replies

Specify Actual Usable Form Area Instead Of Outside Area?

May 12, 2010

I designed a form and managed to fit graphics inside it. Picture box is 465 pixels high. Form1 is 500 pixels high. SnapShot of the screen verifies that the 500 pixel height is the overal height. It includes the upper Bar and lower frame. Is there an instruction to set the From's inner pixel size and not overal?

View 2 Replies

Error: "The Query Builder Failed. Cannot Open User Default Database. Login Failed. Login Failed For User <User Name>"

May 8, 2012

I'm using Visual Basic Express 2010 and SQL Express 2008 in Windows XP. At first I couldn't add a datasource (the .mdf file for the database) because of a "Operating system error 32" which I seemed to have resolved by giving myself full permissions for .mdf file (by right clicking on the file and going into properties and then Security) and restarting the SQL SERVER (SQLEXPRESS) service. The dataset for the database is in my solution explorer but when I right click on a table adapter to add a query and attempt to open up the query builder, I get the error in the title above.

View 1 Replies

Making A Value As A Default Which Can Be Changed To Another By User

Aug 9, 2010

In my program I've a list of "Time Zone" and I want to make one of that as the default Time Zone when an end user uses the program - ie: everytime he starts the program that Time Zone should be selected ( Of course, he should be able to select another Time Zone temporarily, but his default selection shouldn't be changed unless he wants to do so by changing the default one).

And another user should be able to make another Time Zone as his default Time Zone.

In my program, I give the Time Zones in a ComboBox as follows:

TimeZone = CDbl
(ComboBox1.SelectedItem)
ComboBox1.Items.AddRange(New

[Code].....

View 18 Replies

"The Query Builder Failed. Cannot Open User Default Database. Login Failed. Login Failed For User <User Name>"

May 8, 2012

I'm using Visual Basic Express 2010 and SQL Express 2008 in Windows XP.I created a database on my local PC HDD. At first I couldn't add a datasource (the .mdf file for the database) because of a "Operating system error 32" which I seemed to have resolved by giving myself full permissions for .mdf file (by right clicking on the file and going into properties and then Security) and restarting the SQL SERVER (SQLEXPRESS) service.The dataset for the database is in my solution explorer but when I right click on a table adapter to add a query and attempt to open up the query builder, I get the error in the title above.

View 10 Replies

C# - User Settings Keep Resetting To Default After Each Deployment?

Aug 18, 2009

My deployment of upgrades to an application written in C# (.NET 3.0) consist of simply replacing an older .exe with the new one. Because that older version can currently be used by some customers, I simply rename the old version to blahblah.exe.old and copy the new one to the same folder. When the user opens up the application again, the new one loads up.

The problem is, every time I deploy a new version, the user scope settings are always reverted back to the default values.

View 1 Replies

How To Check If The User Enters The Default Datetime

Jun 22, 2011

I have two textboxes on the screen. They are used for startdate and enddate. If the user does not enter anything in the textboxes I pass nothing (VB.NET) to the webservice. When the webservice receive it on the other end it shows the value "#12:00:00 AM" which I think is the default for the datetime field. Anyway, now I do not want to pass this value to Stored procedure since it will not work. How can I check before sending values to sproc that the value is not the default datetime.

View 3 Replies

Programmatically Change A User's Default Printer?

Jul 26, 2010

I have a VB.NET module that prints out a series of Crystal and PDF documents as a packet. I need a way to temporarily change the user's default printer to the network printer for the PDF report (the Crystal reports are already redirected). Once the module has done its job, I want the module to return the default printer back to its original setting. Since Adobe Reader only works with the default printer, and there does not appear to be a way to redirect that, I need to change the deault for the duration of the module. I tried the following code, but it still sends the PDF output to the local printer.[code]...

View 4 Replies

Set Default Location Of User.config File?

Mar 26, 2012

I made a project in VB.NET 2008. When I update my project I change the assembly version but the problem is that when the user gets the new version they lose their user settings.[code]Note the version number in the path. Is there any way save in a location not affected by changing the version?

View 1 Replies

Setting Default Property Value In User Control?

Aug 24, 2010

I am creating a customised version of the ListView control and there are several of the properties that a ListView has that I would like to be set to a different value to the ListView default when a user goes to use my user control.

From what I've found there seems to be a number of people suggesting just set them in the constructor, but to the best of my knowledge that would just mean that the user would not be able to change the properties in the PropertyGrid in the VS IDE.I assume this is probably something extremely simple that I have overlooked.

View 8 Replies







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