MessiahAndrw's Q&A profile
SQL Server SET IDENTITY_INSERT tablename ON
I know there has already been a thread on this, but I want to push some about it. In SQL Server, there is a command " SET IDENTITY_INSERT tablename ON". That allows you to update IDENTITY columns, or do INSERTs that include IDENTITY columns. Although a work-around was given for this in the other thread (reset the IDENTITY seed to the desired value before each INSERT), that is a major pain. In my database, I have a table that tracks charitable donors. They have a donornum, that is an IDENTITY column, and a year. Together, the donornum and the year form the primary key. Each year end, a copy is made of all donor records in one year, to form the next year's donors. They have to keep the same donornum, but they get a new ...Show All
Visual Studio Express Editions Button Click within a for each loop
Fairly new to VB express. Is it possible to have a button click event from within a for each loop on a form i.e. the button being clicked refreshes the form and moves on to the next iteration of the loop Any suggestions welcomed. I hope this helps or sheds some light: Dim myOtherArray() As String = { "Bob" , "Beth" , "Conrad" , "Grant" } Dim i As Integer = 0 For i = 0 To 3 Label1.Text = myOtherArray(i) 'MessageBox.Show(myOtherArray(i)) Me.someButton .PerformClick() 'this will click the button specified, replace "someButton" with the name of the button you want to click Next is this what you are after my apologies for being ...Show All
Windows Forms VB2005 Fill datagridview with data from other form
Hello, I have a form called "frmMain" wich contains a datagridview. When I click the button "numberoforders" (which is on the form frmMain) another form (frmNumber) openes and I would have to fill in a number of orders. I save that number to a public integer. When I close the frmNumber I want the number I filled in on the frmNumber (which is saved to the public integer) to appear in the datagridview on the main form (frmMain). I dont know exactly how to put the number in the specific row in the datagridview. I think I would have to use the formload event I hope you guys can point me in the right direction..... here is an example code ,I hope this will help ...Show All
Visual Basic BeginOutputReadLine()
This has probably been answered many times but I don't seem to be able to get it to work. My aim is to run a console command and bring the output to the form. For example, running this by hand: C:\Documents and Settings\Username>cvs.exe Usage: cvs.exe [cvs-options] command [command-options-and-arguments] where cvs-options are -q, -n, etc. (specify --help-options for a list of options) If I try and do it in VB: Imports System Imports System.Threading Imports System.IO Imports System.Diagnostics Dim boolFirstTime As Boolean Dim intNumLines As Integer = 0 Dim strFile As String = "cvs.exe" Dim strOutput Dim intOutput = 0 Dim value As ProcessStartInfo = New ProcessStartInfo With value ...Show All
Windows Forms Modifying manifests programatically on site
Can anybody point me in the right direction for information on the following: We'd like to have a user (well site admin to be precise) generated file included as content in a click once deployment. This I guess would mean regenerating the manifests programatically. I've had a quick look at MSDN in the Microsoft.Build.Tasks.Deployment.ManifestUtilities namespace and as these classes aren't meant to be used by us plebian software devs there isn't a lot of info. I'm assuming of course that what we want to do is possible. (oh and don't ask me why we need to do this...you won't like it...I don't even like it ) Look at the documentation for mage.exe and mageui.exe... The typical scenario is to build the manifests using MageU ...Show All
Visual C# How do I Retrieve text from other programs?
Hi guys, I'm currently trying to come up for a solution for the following problem: Right now the user is reading values off a screen and manually copying them into another window to store in a databse. Because of the closed nature of the program they are using I can't edit the program, and was trying to figure out how to automate this process. Summary: I want to read the displayed text values off the window of another program. anyone know how to do this Or at leaste can anyone point me in the right direction for some learning sources or api classes that might be related Thanks a bunch, Hello , I have used this code as is but I don't know where should the result "Text" be , but I ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Realtime Drawing
Hi there, I am new in graphics programing and I want to develop a simple applciation (like a simulator) that draws waves based on values comming (like what happen in heart beat graphs, certain values coming from ECG sensors continously make the waves on the display screen). Regards This can be done but as you are just starting out you might want to look at using GDI+. Here is a link to a good faq site on the subject. You could also use DirectX but it would take a bit of education to get you started, the best place to look at the moment is www.thezbuffer.com as the zman has a good list of tutorials that you can follow (Note www.thezbuffer.com is mainly for managed languages which include c# and vb.net, if you want to use ...Show All
Visual Studio Express Editions some questions again
1) i want my program to cover everyones screen full, i could use the windowstate maximize for that but what i want is that everything scales with the size of the form, i hope u understand what i mean 2) how can i get/put data from/in a dataset with coding thx in advance as for the video, you need to use either 3rd party control to do this or use and embed the WMP control in your application for the listbox, not sure but I know you can do this with a combobox. I guess one theory would be on the textchanged event of the textbox, to go through each item in the listbox and see if the item "startswith" the text the user entered and if so, keep it otherwise remove it. ...Show All
SQL Server Excel Destination: write over existing data
I have a daily package that extracts some data and writes it into an excel file. I want to write over the existing data, but the excel destination only appends the next free location in the worksheet. I tried using a SQL task to grab the file, set all the cells = NULL and then run the rest of the package, thinking it would see the null cells as empty and write in them, but somehow it knows where the previous data ended and keeps appending further down in the workbook. Does anyone know of a workaround so I do not have to delete and re-create the file everytime TIA, Sabrina Jamie Thomson wrote: Phil Brammer wrote: Rafael Salas wrote: ...Show All
Smart Device Development Exiting a Smart Device Application
I am developing a smart device application in Visual Studio 2005 for a Symbol handheld pocket pc device. I have two forms for the sake of this discussion lets just label them Form1 and Form2. Form1 is the login form that is loaded by the application using the following code: Application.Run(new Form1()); After the user is authenticated on Form 1 I create a new instance of Form2 and open it using the following code: Form2 frm = new Form2(); frm.ShowDialog(); There are now two instances running one of Form1 and one of Form2. I know this because when I check the system memory I can see both processes. My question. If I am on Form2 and I create a exit button how do I close the entire application. How do I close both forms and en ...Show All
Visual C++ Add numeric Object type to DataRow
When I create a datarow and I add an Object, the passed Object always is cast into a System::String type. This is the example: void InsertRowInTable(DataTable *dataTable, ArrayList* columnNameList, ArrayList* rowData) { DataRow* dataRow; dataRow = DataTable->NewRow(); unsigned int numberOfColumns = columnNameList->Count; for(unsigned int i = 0; i < numberOfColumns; i++) dataRow->set_Item(columnNameList->get_Item(i), rowData->get_Item(i)); dataTable->Rows->Add(dataRow); } In the arrayList rowData passed into the function the objects type is Int32 but when the method set_Item is used, the object item in dataRow converts into a System::String type. My purpose of all this, is to allow sorting the rows us ...Show All
Visual Basic Multiple fontstyles for a font
Hi, Another simple question i'm sure... I'm trying to create a font with multiple FontStyles... e.g. bold and italic and underlined I've got the basics for a single fontstyle but just can't work out multiple ones. Current Code: Dim fnt as new Font("Times New Roman", 12, FontStyle.Bold) Any help would be greatly appreciated (can't believe i've been writing apps for the last 5 years and never actually come accross this problem before!!!) Thanks OK i've wprked it out, Just me being a bit slow!!! I've created a Font Generating function that returns a font (below) taking the font name, size, and boolean values for Bold, Italic, Strikeout and Underline. Private Function ...Show All
Software Development for Windows Vista Problem in driver development in Vista
Hi, I'm in development of a driver for PCI card in Windows Vista (Build 5308). I faced a problem probably due to its "shadow copy technology". Suppose i have installed my driver on system. And then made some changes and build. whenever i'm going to install this updated version(with respect to build time-stamp) vista is not using the updated version. Its using the very first version(with respect to build time-stamp) installed on the date although it keeps backup of the updated version. I have attempted a number of alternatives: 1) Restored an updated version from "previous versions" tab. Its worked fine only for the next restart. and 2nd time onwards uses very first version of the date. 2) i suppose its due to shadow cop ...Show All
Windows Forms Textbox/RichTextbox Caret
I developed an application in VB. I had to use a regular Textbox, because I needed to change the width of the caret. I wasn't able to change the width RichTextbox caret in VB, is there a way to change it in C# I was playing around with the AlphaBlendTextBox , but I couldn't figure out how it was drawing the caret. Does anyone know anything about this I won't be changing the font size or font face of the textbox, and I'm using a fixed-width font (Lucida Console), so the caret width isn't dynamic. If that's the case, how is the caret being drawn in the AlphaBlendTextbox I was playing around with the contol and editing a few values. It was hit or miss, but occassionally I got the caret to expand, although ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Where does Console.WriteLine() go to on 360?
Probably a setup problem, but I can't seem to get any text sent to Console.WriteLine() to appear in the output window in GSE, when running the app on my 360. Anyone else managed to get this working Andy. Derek Nedelman wrote: There is no console when running on the 360, just like there's no console when you run a Windows Forms application. System.Console.WriteLine() writes data into the output window of an attached IDE when debugging, even with WinForms apps . I tend to use this rather like you would use ::OutputDebugString() in a native application for debugging - and I find it hard to believe that when attached to a remote process the strings are not piped back to the IDE. ...Show All
