Mbd's Q&A profile
SQL Server Problems with report fitting to a page when exporting and then printing from Excel
I have various reports in both portrait and landscape and when I export to Excel although the page orientation works correctly the report does not print correctly in that the right hand side of the report gets chopped. In the report definition I have all the margins set to 0.5cm and the page height set to 29.7cm and the width to 21cm for portrait and the other way around for landscape. In designing my report I have a report width 1cm less to take account of the margins i.e. 28.7 for a landscape report and 20cm for a portrait report. The report is defined in all this space as I have lines in my header and footer than span the whole report ...Show All
Visual Studio Purpose of debug and release configurations
Hi there! I have posted the same question before without finding an anwser. After spending some time with VS I may now be more exprerienced to phrase the question better! The following applies to VS2005 beta 2. Follow the steps: Open VS and create a new windows app (I use VB but I guess the same goes for C#) Hit F5 to run the application. The following files are created under bin\debug: WindowsApplication1.exe WindowsApplication1.xml WindowsApplication1.pdb WindowsApplication1.vshost.exe Now hit Ctrl+Shift+B to build the application. The following files are created under bin\release (vshost.exe is missing): WindowsApplic ...Show All
SQL Server Problems Setting DTS Global Variables after Rebuild
We have performed a dummy Disaster Recovery rebuild of our Windows 2000 Advanced Server(SP2) and SQL2000 database so that we all knew what to do in the event of the failure. Everything seems to have worked OK apart from one DTS Upload task. The system uses 3 DTS packages to perform data uploads, but only one fails These are all launched from VB executables which load the relevant DTS package and then executes them. It seems that the global variables assigned in the VB executable are not being picked up or actioned within the DTS scripts. Instead the default values that are stored within the DTS package are used instead. I ha ...Show All
Visual FoxPro OWC11.PivotTable
I've tried to play with MSGraph for some time and after not getting very far yet (although I got some graphs) I downloaded MS Office Pro 2003 enterprise Edition and found out that there seem to be richer controls out there. In particular I am trying to work with OWC11.ChartSpace , OWC11.PivotTable and OWC11.SprreadSheet . I have resigned to the fact that I would have to use MS Excel Spreadsheet as an interim container between my tables and the graphs (Marcia will be thrilled at my defeat:) ). I am finding it difficult to figure out how to populate spreadsheets . There are a number of suggestive properties like OWC11.PivotTable.DataSou ...Show All
Visual Basic Passing Information back form the slave Thread to the Master Thread?
Hello Everyone, I have a question I could not find amongst the Forums.... I am starting a new thread and when the thread finishes I need it to pass a vaule back to the main thread and do a insert in to a Listbox. The data being passed back to the Listbox is not a sting but a tree statement. Can anyone give me some help on this If need be I can post the command going back. (Let me know if it is needed) Regards, -Marcelo You could call Invoke on anything that implements ISynchronizeInvoke. The only classes I ...Show All
SQL Server variables in variables
It it possible to define a variable that is the result of 3 other variable like @[User::Total] = @[User::varA] + @[User::varB] + @[User::varC] I know that i can set it with a scripttask but is there a way to define it when creating the variable Absolutely - and this is one of the cool things about variables. They can be set using expressions just as any other property of an object can be. Select the variable in the variables pane and hit F4. The properties pane will appear showing properties of the variable. Set: EvaluateAsExpression=TRUE Expression=@[User::varA] + @[User::varB] + @[ ...Show All
Visual Studio Express Editions VBE Lesson #6 - Classes and Supplementary Material
I'm looking for sources that better explain the necessity of custom classes and the supplementary material from the course because I can't seem to grasp the use of any of it. I'm new to programming and I've played with VB MANY years ago but I just DON'T see the rationale behind creating a custom class as indicated in the Lessons. It seems non-sensical and unnecessarily complicated. If I wanted to create an application that allowed me to input a number of employees and their particulars, such as pay scale, years of service, department, employee number, etc. Why not define the variables, create an advancing employee number with each new emp ...Show All
Visual C# How to poll the serial port to see if there is data and if not go on
I am working on a senior project that involves a RFID card reader that sends info through the serial port only when a RFID tag is in the readers range. I am wanting to constantly check the serial port for this info but I can only get it to check it and it waits until there is a card. In this period i cannot do anything else. It just sits there and waits. I want it to check it and if no data then go on. Below is what i am doing. serialPort1.Open(); string names, decoded; serialPort1.ReadTo( "8" ); names = serialPort1.ReadTo( "31" ); names = names.Remove(0, 16); //names = "802A546573745F45453438 ...Show All
Visual Studio 2008 (Pre-release) Mouse Capture
Once the mouse is captured Source, OriginalSource, Target & DirectlyOver are all set to the element , capturing it. I wonder is there still a way to say which actual element is 'hovered' by the mouse (as if it woudn't be captured) Thanks ...Show All
SQL Server Directx Initialization
Below is the code for initialzing a directx application in vb. Thecompiler does not recognize any of the directx code. The error is: "'Device' is ambiguous in the namespace MicrosoftDirectx.direct3D" I have all of the necessary imports I believe and all of the necessary references. Can anyone tell me what "ambiguous in the namespace" means and perhaps what I am doing wrong. Thanks, Dick Roose Imports System Imports System.Drawing Imports System.Windows.Forms Imports Microsoft.DirectX Imports Microsoft.DirectX.Direct3D Public Class Form1 Inherits System.Windows.Forms.Form Dim device As Device ' Ou ...Show All
SQL Server Converting @myString to @myInt
Here's a fun one. BOL says that using CONVERT or CAST to change a string into a number won't work. The following "works" and I'm assuming it is because the compiler can verify that the string value is in fact a number, even with the Unicode N: declare @col2 int select @col2 = convert ( int , N '12345' ) ====================================== Here's what I need to work, or I need a creative work-around if someone has an interesting idea: declare @col2 int, &nbs ...Show All
Visual Basic Run Application in ForeGround
Hi, How can I make sure that my vb form in my application always start/show in foreground (fore front) and any other application will run in background (behind my application) Thanks ...Show All
Visual Basic AxWebBrowser inside tab page...
Maybe I put this question in the wrong forum or something...anyway - I have a 10 tab tabcontrol on my form. I have used the AxWebBrowser control successfully (and flawlessly) on other forms that didn't have tabs, but I am having the hardest time getting the browser to render inside a tab control. No empty white field, no nothing. I don't even get a redraw when I switch from another tab. There's not much code involved...just an import system.io, MyBrowser.enter event, and then a MyBrowser.navigate("blah\blah\file.htm")...but let me know if you want my snippet anyway. Thanks, CP For anybody wondering or worrying a ...Show All
Windows Forms HELP!!! --> setting up terrarium server
well, i have been trying almost every options to get this terrarium server running, but... the problem there i think is that i can not get the "Connection String" right to set server up. i have : WINXP PRO SP1 + VS.NET 2003(SDK1.1) + IIS + SQL SERVER PERSONAL The Only Place that it can make this failure is SQL SERVER SETTING UP ------------------- ...Show All
Visual C++ Communication between objects
I am using a main form created with CLR, Windows forms (Form1) with 2 child forms ( A, and B). I want to have B send A some information to act on (I need to pass it an integer). How should I do this (I posted a similar question and it was bumped to another forum, but no answers in over a week) Yep the windows forms forums might be a better place as descibed in http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=187409&SiteID=1 I will contact the forum owenrs there. Thanks, Ayman Shoukry VC++ Team ...Show All
