Martin Hooper's Q&A profile
SQL Server Problem for Calling A Stored Procedure, Please help.
I am writing a Stored Procedure for other server (using C++ to receive the output values) as below, where @Total , @balance, @A are output values create proc [MaxTime] @number varchar(30), @numbera varchar(30), @numberb varchar(30) as begin declare @balancefloat declare @table varchar(20) declare @freetotal varchar(20) declare @SQL nvarchar(4000) declare @A float declare @Total float select @balance = balance, @table = table, @freetotal = freetotal from info where number = @number SELECT @SQL = 'select @A = A FROM' + @table + ' WHERE LEFT(code, 1) = ' + LEFT(@incomingcode, 1) + ' AND CHARINDEX(LTRIM(RTRIM(code)), ' + @incomingcode+ ') = 1' + ' ORDER BY LEN(code) DESC' exec sp_executesql ...Show All
Software Development for Windows Vista DirectShow: get_StreamLength inaccurate
Sorry for yet another DirectShow query. I'm using the IMediaDet interface to find out the footage duration and consequently the number of frames in the footage for lots of different formats. I've tried two methods to obtain the number of frames. 1. Call get_StreamLength and get_FrameRate and then multiply the stream length by the frame rate to get the number of frames. 2. Use the number of frame calculated in 1, subtract 15 from it (magic number, nasty I know but I'm getting desperate) to get a frame number 15 frames from the end of the footage, let's call it frameNumber2. Then run the graph from frameNumber2 and use the IMediaEvent interface to WaitForCompletion. Check that the event is the EC_COMPLETE event. Use the IMediaSeeking ...Show All
Visual C++ collapsing outline at random times in VS05
[Moved this discussion from " Visual Studio Debugger "] I recently migrated from VS03 to VS05 (using VC++). I've always used Outlining to manage large code, but VS05 seems to have introduced a bug in the outlining functionality. I will be working in a section of code and all of a sudden it will collapse and the section I am working in will be hidden. It seems to happen at random times -- usually in a section that was previously hidden but was subsequently expanded. Sometimes just the opposite happens -- sections will suddenly expand that were previously collapsed. I suspect that it has to do with the new (helpful) feature in VS05 that "remembers" outlining states from previous sessions. It's acting like it has s ...Show All
Visual FoxPro Listbox causing error
Hi I have a listbox in which I fill with values from a SQL based on a selection chosen by the user. The listbox allows the user to select the value they want from the list and enter payments for that person. However my problem occurs in instances where the list box contains more records that are shown in the main listbox window and the user has to scroll down the list. This is usually 500 or more records. When the user selects any of the records nearing the end of the list, the entire application closes with an error saying "Syntax error" and it is going straight to the read events. It however does not tell me where the syntax error is. For any of the records closer to the beginning, everything works fine. Help please. ...Show All
Visual Studio Can't Find Crystal Reports
Hello, we have Visual Studio Team Edition installed on a machine. We're trying to use Crystal reports, but we can't find it. I checked the installation, and it claims to be installed. It doesn't appear in the new file list anywhere. Thank you for your help! Hm. Visual Studio Team System appears to be a collection of about seven different versions of Visual Studio (See the products page for more details ). There's a chance that you have a version of Visual Studio that does not include Crystal Reports for Visual Studio, such as Visual Studio Team Foundation . If you select Help >> About Microsoft Visual Studio, what products are listed in the 'Installed Products' list - Dave ...Show All
Windows Live Developer Forums Need help on makeing a Media Player.
I need some help on may be finding something that can make a media player, i've called the sopport number about it, and i dicided to come here, and see if i can get more info. thanks. This is not the right forum for questions about media players, you should probably check this site out: http://msdn.microsoft.com/windowsmedia/ or this forum: http://forums.microsoft.com/MSDN/ShowForum.aspx ForumID=387&SiteID=1 nate ...Show All
Visual Basic Fill Several Combobox with the same values from database
Hi, I have 15 Comboboxes in a form and I have to fill them with the same values from a database table. If I use the same datatable to fill them all at the same time, everytime I select a a value form a combobox, all the rest show the same value !!!!, I don't know why this happens. So I tried to use a function to open a new datatable for each Combobox datasource and works fine, but the problem is that my application turns slower when loading that form. This is my function when all ComboBoxes take the same value when some of them is selected: Public Sub FillCombos( ByVal xComboArray As System.Collections.Generic.IList( Of Windows.Forms.ComboBox), ByVal DBConn As SqlClient.SqlConnection) Dim i As Int16 ...Show All
Visual Studio Express Editions Calculate Emailaddress from multiple textboxes.
Hi, I'm totally new to programming in VB but you have to start somewhere! It's so cool! What I'm trying to archieve for now is creating an emailaddress based on various input textboxes: FirstName, MiddleName, LastName. The emailaddress should be calculated like this: <1st letter of FirstName>.<MiddleName>.<LastName>@company.com If a user has no MiddleName there shouldn't be an extra dot! The EmailAddress textbox should be generated as you type the FirstName, MiddleName and LastName textboxes. I'm also looking for some tips for input validation. It should only be possible to use alphabetical characters. An additional Initials textbox should only use alphabetical characters and dots e.g. T.K.B. All help ...Show All
.NET Development Seek suggestion on .NET support options
Hi everyone, Does anyone out there have some recommendation(s) regarding alternative forums for discussion / questions / answers about .NET programming, C# development, etc It's great to have the MSDN forums, but, the "oracle is not always in", and I find that more of my questions go unanswered than not...(I do try to form my questions as well as I can, and try to be aware of the proper etiquette, read faqs beforehand, etc...I think the problem is simply that most of the problems I've had a genuinely quite obscure, ...for example, I've got a problem right now with a bizzare compiler error messsage ('assembly /../..longpath/xyz.dll must be strong signed in order to be marked as a prerequisite') which is fatal to the build proc ...Show All
Visual Studio Express Editions Parsing Text files
Hi, I have created a vb application that loads the contents of a comma delimited text file to a textBox1. I now want to change the format of the data held in textBox1.text and have the changes shown in textBox2.text, as shown below: textBox1.text = 55, Smith, Fred, Actor, Retired textBox2.text = Fred, Smith, Retired, Actor, 55 Any help with the method to use to re-arrange the textBox1. text string to textBox2.text string would be much appreciated. Jason Hi Jason Try this, which is written for two textboxes called TB1 and TB2 and will cope with any number of lines. Bear in mind there is no error checking in there so if any lines are not formatted as you expect it will genera ...Show All
.NET Development How to read and display MS Word and MS Excel Xml files programmatically
Hi all, I'm wondering how to read and display the WordML format word Xml file and Excel SpreadsheetML xml file programmatically using c#. Thanks forum. hey, best bet is to use xslt to turn the documents into html, then display it using the web browser control. I downloaded a stylesheet that turned WordML to HTML but its at home, I am positive it was part of the Office XML Schema Reference, have a look here and maybe you can find something that will help.... http://msdn.microsoft.com/office/download/toolutil/ ...Show All
Visual C# Printing to a dot matrix printer without feeding an entire page
I need to be able to print a number of lines to a dot matrix printer, but not have a full page length feed through the printer when I send the PrintDocument for printing. Thus far, printing in the traditional .NET fashion spools an entire page out. There must be a way to do this, but I can't find it. Ideas >> probably using the SerialPort classes in .NET 2.0 to have direct access to the printer Note, however, that most printers use (traditionally) the Parellel port or (more recently) the USB port. I haven't seen a printer attach to a serial port in 20 years. ...Show All
Visual C# RadioButton and ApplicationSettings
Hi, I have the following problem: A form with one groupbox containing two radiobuttons whose checked-properties are bound to settings-properties: radioButton1.checked is bound to bool Settings.Default.gwmKeep radioButton2.checked is bound to bool Settings.Default.gwmDelete When I run the Application, I have to click twice on these radiobuttons to check/uncheck them. Is this behaviour intended Do I really have to track manually if a radiobutton is clicked Please help, Andy I also faced some weired problems in past when binding properties of controls to Client Settings, I dont know how it behaves in your scenerio but if you have tested and its not working you should handle them manually as suggested by ...Show All
Visual Studio Express Editions Website Redirector (Help)
Hello, Me and my friend asterix299 are trying to build a program called Website Redirector. We have an idea on how we want it made but there are no good resources that we can find on the Internet and in Books. So I thought i'd come here! Heres how we are planning for itto be built 1. Have a box where a user can type in a website EXAMPLE: What website would you like to be redirected to (www.google.com) example Where would you like this website to be redirected from (www.yahoo.com) example Then an ok bar at the bottom. We are going to use the hosts file in drivers/etc we are stuck so can one of you tell us how we can make this Thanks. ...Show All
Visual Studio Team System creating/adding new document templates
my QA team is accustomed to using Excel for documenting manual test plans. how do I add my existing test plan template to be accessible in VSTS this has to be possible. The manual test file is stored in the project item template, which is in Program Files\Microsoft Visual Studio 8\Common7\IDE\ItemTemplates\CSharp\1033\ManualTestWordFormat.zip. Change it and you're good to go You can also add a new manual test by adding new item templates. This article may help: http://msdn.microsoft.com/msdnmag/issues/06/01/CodeTemplates/ . Thanks, David Gorena Elizondo [MSFT] VSTS ...Show All
