How Do Express These Values In C#
Feb 25, 2012
I'm following this example code: url... but doing it in c#.I don't know how to express the following in c#:[code]Specifically, I do know to prefix hex values with '0x' but what is are the S's all about on the end of some of these values? Also on the third line when I convert it to 0x80000000 I get an error saying it can't convert from uint to int implicitly. Not sure if I should just cast, or change the type of the variable?
View 2 Replies
ADVERTISEMENT
Jul 13, 2010
In a VS2008 VB project, I have a combobox that gets its values from a SQL Express table. This table has three columns. I want to display the value from one column in the combobox, and obviously the user will select from this. I want to then write the value of the selected record from a second column back to a different table, and I also want to change the value of a radio button (on the same form as the combobox) based on the value of the third column of the selected record.I'm setting the ComboBox.Text value to be the first column, the ComboBox.SelectedValue to be the second column, but how would I change the radio buttons in the most efficient way? If it was VB6, I'd probably make another trip to the database to find the value of the third column based on the selected value from the combobox. I'm not familiar enough with the tableadapter concept but I suspect I should use them to do what I need.
View 15 Replies
Mar 4, 2009
Intellisense in VB 2005 Express is showing lots of member items when hovering over a variable instead of showing the variable value. For example, when hovering over DataRow("Field"), instead of showing what's in Field, it shows all the members of the Datarow object.
Is there a way to change this, so I can see variable values without using the debug window like so, ?Datarow("Field")
View 3 Replies
Sep 23, 2009
I have a simple windows form application (I'm working in Visual Basic Express 2008).
There are some forms that have simple text boxes. When somebody wants to edit something in this boxes he pushes edit button and then they are enabled. I insert some text and when I save this text is saved for good.
When I reopen the application this text is there like I want it to be. Just for information, this text is always the same in one text box, until I change it (me or some other user) - so I think there is no need for databases. For my needs this is ok because I don't need to change this data often. This is code in Form load event (for calling back the data)
[Code]...
View 4 Replies
May 3, 2009
i'm using visual basic 2008 express edition and having a problem in saving the data i've added in datagrid to excel. i use inputbox to add data into the datagrid. when i click the save button, the data from the datagrid must be save to excel. this is the code i get from some forum and i already edited it but it only saves the last data/row i inputted.
[Code]...
View 1 Replies
Oct 3, 2011
I'm just using the default SQL Server Express in my vb 2008 express edition as my database server for my database operation. When I tried to update the records on my table I got a runtime error which indicates the error on this line 'myCommand.ExecuteNonQuery()'and it highlights a yellow background on it. The runtime error says "SqlException was unhandled: An expression of non-boolean type specified in a context where a condition is expected, near 'Number'. ".
Imports System.Data.SqlClient
Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
Dim myConnection As New SqlConnection
Dim myCommand As New SqlCommand
[code]....
View 3 Replies
Oct 16, 2010
I tried to start using VB 2010 Express with a program I originally developed with VB 2005 Express that I moved to VB 2008 Express successfully a couple years ago. It uses a database file (*.mdf) that is on the computer ( not out on a server). When attempt to run the program in debug mode, I get the following error "An attempt to attach an auto-named database for file C:Documents and SettingsTomMy DocumentsQuizzing StuffQuestion Database 2010QuizQuest ionGameQuizQuestionGameinReleaseQuizQuestionDB.mdf failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share."
I first made a copy of the entire project folder that was working in VB 2008 Express and gave it a different name. In VB2010 I opened the project in the copied folder and it said it successfully converted the project. I am able to open the Data Source inthe Designer and see the database structure as I expect. I think the project is still using SQL Server 2005 Express (because it is what is checked in the list of prerequisites on the Publish tab).
Note, I have programmed off and on for many years, but fairly new to using databases and SQL Server.
View 3 Replies
Nov 1, 2011
Is it possible to connect to a database on SQL Server R2 Express from Visual Basic Express? I am following a set of tutorial videos done in SQL Server 2005, but cannot seem to connect to create the database. I have created the database in SQL Server R2 Express, but cannot connect. Is there a work around?
View 4 Replies
Feb 29, 2012
Here is the scoop: I am trying to make a user account SQL database work with Visual Basic 2008 Express for login purposes, i.e. usernames & passwords. Plan is to host this server so people can login to use the the application and verify they have a valid account. I would like to host all the account information in SQL due to the possiblity of hundreds of users at any given time. I also need the ability to add data to the database for users registering for the first time. The SQL server will need to be able to access the SQL Server databases remote via WAN.
View 1 Replies
Jan 21, 2011
I am trying to re write a VB6 program using MS Access, many years ago, using VB 2010 express and SQL server 2008 R2 Express. I have a database with several tables, which I created using the designer. I am able to connect to the database and select data and display it in textboxes etc in vb code. What I have not been able to in code is to INSERT rows DELETE rows or UPDATE any data in the tables. I can do any of these operations using the Query Designer, but I want to do it in code. I can post some code if necessiary, but I thought it might just be some property that I had not set in the designer.
[Code]...
View 13 Replies
May 12, 2010
Is VB Express 2010 slower to compile and run that older versions of VB Express? I've installed it this weekend and it seems a little sluggish on my quad core computer with 1 gig of RAM. I have VB Express 2005 installed for my students at school and it seems to fly just fine. Those school computers are older P4s with 512k of RAM.
View 7 Replies
Feb 29, 2012
there Dream in Code Community! Im an okay programmer as far as skill right now I am still learning as we all are I need some help from some experienced VB.NET programmers in the community, Here is the scoop: I am trying to make a user account SQL database work with Visual Basic 2008 Express for login purposes, i.e. usernames & passwords.
[Code]...
View 2 Replies
Feb 24, 2010
The program I am trying to modify was initially written using VB 2005 Express. I have subsequently downloaded the 2008 version. The program creates a monthly spreadsheet from a template. The old code that will no longer (highlighted and underlined) compile is as follows:
[Code]...
View 4 Replies
May 13, 2005
It's probably just a case of me not looking in the right place or not seeing the obvious, but does anyone know if a machine with just version 2.0 of the .NET Framework should be able to run a VB.NET Express application which accesses a SQL Server Express database file? Or is there an additional requirement for a non-development machine to have some kind of SQL Server Express runtime component in addition to the 2.0 Framework?It seems to be counterintuitive to expect that a VB.NET application would be able to access any kind of SQL Server data without having some kind of SQL Server host component (Express or otherwise) installed. But then again, it seems just as counterintuitive that Microsoft would require the download and installation of the new framework as well as a separate database runtime in order for the average user to run an application with accesses a local SQL Server Express database.To me, it runs contrary to the whole concept of XCopy deployment to require more than just the application's files and .NET Framework for an application to run properly. But nothing I've read so far explicitly indicates that a user would require anything more than the app files and the framework to run an application which accesses SQL Server Express data. But...I can't get any VB Express applications which uses a SQL Server Express databases to run on any machine that doesn't have SQL Server Express installed.What am I missing?(Apologies if this isn't the right group to post this in.
View 3 Replies
Nov 20, 2009
I have attempted to uninstall VB 2005 express and C++ express using Remove Add programs to no avail. Error message: The Window Installer Package c:program files visual studio 8 vs_setup.msi could not be opened. I have removed the MSDN library and SQL server successfully. I have also tried vs_uninst_betas tool which doesn't find anything to uninstall. I would prefer not to modify the registry if at all possible. If I could find a source for the original install packages for VB and C++ I would attempt reinstalling and then uninstalling....but cannot find them anywhere.
View 4 Replies
Feb 25, 2011
Is there any advantage to using the VB2010 express version versus the VB2008 express version? Can they be installed side by side or will VB2010 express replace VB2008? I have no issues with the 2008 version, so I don't know if installing the 2010 version would be of any advantage.
View 9 Replies
Feb 29, 2012
I am trying to make a user account SQL database work with Visual Basic 2008 Express for login purposes, i.e. usernames & passwords. Plan is to host this server so people can login to use the the application and verify they have a valid account. I would like to host all the account information in SQL due to the possiblity of hundreds of users at any given time. I also need the ability to add data to the database for users registering for the first time. The SQL server will need to be able to access the SQL Server databases remote via WAN.
View 3 Replies
Sep 21, 2009
how I can implement my calendar with VB .net express 2008 and MSSQL 2008 Express. How do I get it to work with datasets, binding source etc.If I go to Properties>settings my connection string is:
Data Source=.SQLEXPRESS;AttachDbFilename=|DataDirectory|CalendarDatabase.mdf;Integrated Security=True;Connect Timeout=30;User Instance=True
and I have a table with fields:-
CalendarID
Subject
Location
Purpose
[code]....
I can Add the event to the calendar I have the necessary items on my form linked to my table and I can save them to my table:
Me.Validate()
Me.CalendarTableBindingSource.EndEdit()
Me.TableAdapterManager.UpdateAll(Me.CalendarDatabaseDataSet)
But I cant keep the event displayed on my calendar when I close it and open it again.
View 1 Replies
Mar 23, 2009
I have a DEM file(Digital Elevattion Model File) and I am trying to open the file,where we have Latitude and Longitude values inside the DEM file.And, Now I have opened the file using Filestream and Read the file using BinaryReader.But, I am having a trobule in getting the values of Latitude and Longitude.I am getting Byte values randomly as 1,202,31,271 etc.But, we dont have latitude and longitude values more than 180,and also I am not getting 16 bit UInt values.For example, the values should be like Latitude 20.00416666666667 and Longitude 39.99583333333333.So,read the correct Byte values of the DEM file.The code I have used till now is:
Dim fs As FileStream = New FileStream("C:UsersadminDesktopHeader and DEM fileE020N40.DEM", FileMode.Open, FileAccess.Read)
Dim rd As New BinaryReader(fs)
Dim convertDB As UInt16
For i = 0 To rd.BaseStream.Length
[code]....
View 14 Replies
Jun 2, 2011
lets say I have a form (form1) with lables a-z which are all designed with default text "0". So they all show 0 on program startup. which is fine. I also have a dialog with 2 TextBoxes; I want my program to update the default text/value on (only)form1 labels x, y and z to whatever was put into the textboxes when i press the OK button on the Dialog, so these specified labels show the 'new' value on next startup. Is it even possible or should I save the values to a file which loads the values in the specified labels on startup?
View 5 Replies
Apr 21, 2009
I have simple columns and their respective sums. However, I exclude 1 particular value from each sum, like so [code]...
Now I need to exclude another value ("Awaiting Progression") from a second column called "PROGRESSION".
Since I already exclude value based on 1 column called CATEGORY, how do I change my =Sum(Code.ExcludeOthers(Fields!CATEGORY.Value,Fields!ACTION_PLAN_NEW.Value)) to exclude a value from the PROGRESSION column if it's = ("Awaiting Progression") ?
i.e. How do I exclude multiple values, depending on values in 2 columns in SSRS 2005?
View 1 Replies
Apr 21, 2010
I want to be able to see if the values a user inputs into 2 textboxs equals the values assigned to a picture. I put these values in the picture's name and tag. Also the picturebox is getting the image from a random function correlating to an imagelist. How would i go about thisI thought of maybe using a checkbox and coding
If picturebox1.image.tag = ("12") _
and textbox1.text = 1 _
and textbox2.text = 2 Then
checkbox1.checked = true
unfortunatly when i debug it says the picturebox1.image.tag = Nothing
View 3 Replies
Jan 4, 2011
i have retrived this datatable from datasource and i want to add a more colum 'category'basedon the each value of each Role, like if role column has the value '90 daya client' then in the same row it should have a value 'DC' in the category column.n make a temporatry dt1 table but to add related values.
S.No First Name Last Name Role Date
1 Us er1Name User1Name 90 Day Client 11/01/2011
2 User1NameAtt1 User1NameAtt1 90 Day Client 11/01/2011
[code].....
View 1 Replies
Mar 28, 2011
I am creating a maths programs that draws graphs for the user. so far i have placed 22 values into an array and now i need to import them to excel, draw the graph and import the graph back into the program to display them.[code]...
View 4 Replies
Jul 14, 2009
I am using Visual Basic express edition 2008.I am trying to know if a value in a single dimensional array is repeated in the array. If yes, then multiply one of them by 100. For example:
MyArray (14) = 12, 15, 18, 15, 18, 11, 15, 18, 16, 14, 18, 8, 12, 17, 10
In the above example:
MyArray (1) = MyArray (3) = MyArray (6) = 15
MyArray (2) = MyArray (4) = MyArray (7) = MyArray (10) = 18
MyArray (0) = MyArray (12) = 12
[Code]...
View 8 Replies
Jul 15, 2011
I have a two different tables, Table 1 and table 2.
Table 1
-----------
Resource
Start Date
End date
[Code]....
Here I have to match the total hours of each table according to the resource,
then have to find the mismatched data and find difference with that values of mismatched data.
View 2 Replies
Mar 11, 2010
I'm not sure this is really the right place for this question but I couldn't find a general programming forum.Why are the numeric values -1 and 0 used to represent the logical values TRUE and FALSE?
View 6 Replies
Oct 27, 2010
I am creating an xml file with LINQ as follows...
Public Sub CreateXml()
Dim db As New MDataContext
Dim Customers = <gallery columns="3" rows="3">
[code]....
Could i mix local values with the ones returned from the LINQ query...Something like the following?
Public Sub CreateXml(ByVal **Col** As String, ByVal **Row** As String)
Dim db As New MDataContext
Dim Customers = <gallery columns="& **Col** &" rows="& **Row** &">
[code]...
View 1 Replies
Jun 3, 2011
Initially my app worked with excel fine, now it causes my computer to reboot only after Excel has been opened (two or more times). I have opened and closed Excel files 20+ times without running thru either of my apps (they all uses identical code for excel) and it has never caused a reboot or a crash.
run either of my apps and have the app control excel has become a crap shoot, it will reboot my computer. Adding to that I then have to do a manual shutdown because the reboot process after is unstable. (System doesn't respond properly). My code in this app is small, should make for a good example. I can provide the entire project to anyone who would volunteer to test it. (First I need to know how to send the project).
[Code]...
View 10 Replies
Mar 5, 2010
I'm using VB 2008 Express for our College Project. I'm also running SQL Server 2008 Express and have installed SQL Server Management Studio and used it to create my database. Both software have been installed and running locally. I'm trying to connect to the database from VB 2008 Express. Database connection wizard have 3 options:
connecting to Access db
connecting to SQL Server 3.5 compact db and
connecting to SQL Server db file.
[code].....
View 1 Replies