matthew lyden's Q&A profile
Visual Basic Printing directly
I have in the past created a way to print by creating a file and using writeline methods create the content and then in the end send the file location to a print method that would print the file... but now, I want to print directly to the printer but after I create/format the output. However I am pretty sure the program will run over a network with not enough privileges to create a file, is there a workaround to creating the output and then sending it to the printer thanks, johnp Richard, Actually I am creating a temporary name badge used where I work for visitors. So all I need to do is figure out the start coordinates for all the starting lines of text and just pull in the data that will change like a name and d ...Show All
Windows Forms ToolTip text is not displayed after a click
i walk on c#.net form application, framework 2.0 i have tooltips for my checkboxes,textboxes, comboboxes. after i click a box, its tooltip is never displayed again. how can i display tooltips always. showalways doesn^t do that Hi, If you really want to display it, you can manually display it by implementing the Click event of your certain control using toolTip1.Show("Text",your_control);. Hope this helps. ...Show All
Windows Forms C# windows form looks different on different OS/Platform
I have run into a problem where windows form made in C# looking different when it is runned from Xp professional edition and Xp Media Center edition. All the functionality, group box, buttons, textbox were fine. However, the sizes of the picture boxes I have added on to the program seems to change its relative size ratio from one OS to another. I an in a situation where the picturebox on XP fits nicely into the whole designer form where as on MediaCenter Pictureox enlarges to not fitting in to the designer form. Does anybody have answer for this problem would like to offer me a hand Thanks Cordially, KSJP Hi, I guess I just solve my problem by changing my form: this .AutoScaleMode = System.Windo ...Show All
SQL Server SQL 2005 data dictionary (get code of stored procedure)
Hi all Does somebody know how to get the code of a stored procedure I would like to know the name of the view in the data dictionary which holds the code of the functions or stored procedures ... Thanks for any help Best regards Frank Uray SQL Server 2005 Consider the following Application that helps to create the Training Calendar for a month. Calendar Creation happens in 2 steps. Step 1: Create the calendar code , description and the period Step 2: Specify the programs, modules and courses in the calendar. Step 1: Create the calendar code , description and the period The first Screen is used to create the calendar Code and also the per ...Show All
Visual Basic I need a delay in visual basic program
I am writing a visual basic program that display the file from a directory in a list box the app has a button which calls routines to 1. delete files in the directory 2.put some files in the directory 3. get the file info from directory and add file names to a list box here is code for step 3 my sub My .Computer.FileSystem.CurrentDirectory = "C:\mtmp" ' Create a reference to the current directory. Dim di As New DirectoryInfo(Environment.CurrentDirectory) ' Create an array representing the files in the current directory. Dim fi As FileInfo() = di.GetFiles() Dim fiTemp As FileInfo For Each fiTemp In fi ListBox1.Items.Add(fiTemp.Name) Next fiTemp end sub ...Show All
Windows Forms Text field/box
Task: I have a text box with maxlength property set to 0. What I want to accomplish is to determine whether an overfilling of the text box has occured. Example if you enter a text beyond the visual space or width of the textbox. Example: TextBox _txt = new TextBox(); _txt.MaxLength = 0; _txt.Text = "Yandisa Mtyide has been developing in C# for the last 10 months"; _txt.Width = 60; //Basically the text will overfill the text box, so if this occurs I want to notify the user that the textbox has been overfilled Thank you Is your question answered Please mark the post that provided you with the answer as answered. ...Show All
Windows Forms i want to add checkbox column in the datagrid can anyone tell me about it
i want to add checkbox column in the datagrid can anyone tell me about it. moreover how can i get the datasource in the datagrid this is my try. In this we get the checkbox but we cannot get the datasource value and all checkboxes are checked...please tell me about it Dim i As Integer mTable = objDB.GetData(strquery) DGrid.DataSource = mTable PercentageStatus_Col.MappingName = "PercentageStatus" PercentageStatus_Col.HeaderText = "Percentage Status" For i = 0 To mTable.Rows.Count - 1 If mTable.Rows(i).Item("PercentageStatus") = 1 Then PercentageStatus_Col.TrueValue = True End If If mTable.Rows(i).Item("PercentageStatus") = 0 Then PercentageStatus_Col.FalseV ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Does anyone know the polycon count for XNA PC/Xbox 360 games?
Hi All, Does anyone know the poly limit for pc/360 games Does the XNA framework impose any limits Are there any "cheating" techniques to modeling for games (maybe this should be in the blender forums but just in case ). Are there any tutorials for any of the above Kindest regards, On the PC it depends completely on the graphics card you are using and what you are doing with it - you can find the number of poly's per second on the manufacturers website, just remember that value will be the maximum value possible (you won't ever see that), and of course you'll be rendering 60 frames per second. On the 360 everything is confidential, so unless you are a registered deve ...Show All
Visual C# Set and Remove access(delete) permissions to a folder.
Hi, My requirement is something like this. I am supposed to create a foler and have to check whether it already exists or not. If exists then delete the files from the existing folder and for that I need to check for the permissions(for ASPNET user) to that folder. and when files are deleted set the permissions back to the folder as it had earlier. Skeleton would be like this- void DeleteFilesFromFolder() { Get the access permissions for ASPNET user if(!Granted) { Give him/her the premission to delete the files from folder } Delete the files Set the permission back to the folder } Any idea how to do it in C# Regards, the most reasonable explanations is variable strFolder d ...Show All
Audio and Video Development HD DVD project questions
Hi all, I've been making a lot of SD DVD's the past 5 years so I want to give it a try to author a HD DVD. A client is releasing a 2 DVD box with 6 episodes that have been shot in HD 1080i and asked me if it's possible to author it for HD medium. I want to suggest to release it as a standard DVD box with 2 extra discs containing the HD version of the filmedit. Since there are no players available yet in Europe I'm not very eager to release it on a true HD-DVD medium but to compromise I would like to replicate it on 2 x DVD-9 . The footage is about 2 x 2.5 hours with 5.1 audio. To be on the safe side I would also like to rebuild the project in Director with the same assets so I can include an executable people can use on their PC's because ...Show All
Smart Device Development random TypeLoadException
I am having real issues with a TypeLoadException that occurs generally randomly. I've been working on a .NETCF 2.0 app all day, debugging and generally being productive. All of a sudden, with no changes to the assemblies, I get a TypeLoadException on one of the types in one of my referenced assemblies. It's one of my own assemblies, and I checked the manifest and didn't notice anything untoward. // Metadata version: v2.0.50727 .assembly extern mscorlib { .publickeytoken = (96 9D B8 05 3D 33 22 AC ) // ....=3". .ver 2:0:0:0 } .assembly extern retargetable System.Data { .publickeytoken = (96 9D B8 05 3D 33 22 AC ) // ....=3". .ver 2:0:0:0 } .assembly extern retargetable System.Xml { .publickeytoken = (96 9D B8 05 3D 33 22 AC ) ...Show All
Visual Studio Team System Script Import: does not want to parse correctly?
I'm using CTP6 and trying to import/parse as .SQL script. When I put eacht object type seperately (having multiple .sql files) parsing goes OK. When I try to import a complete script, it does not recognize the CREATE VIEW statement. The .SQL is just a small extension top NorthWind. .SQL file content: CREATE TABLE [dbo].[Auctions] ( [AuctionID] [int] IDENTITY(1,1) NOT NULL, [AuctionTitle] [nvarchar](50) NOT NULL, [AuctionDescription][nvarchar](2000) NOT NULL, [AuctionStartDate][datetime] NOT NULL, [AuctionLength][int] NOT NULL, [ProductID][int] NOT NULL, [ItemQuantity][int] NOT NULL, [EmployeeID][int] NOT NULL, [MinimumBidAmount][money] NULL ) ; ALTER TABLE [dbo].[Auctions] ADD CONSTRAINT [PK_Auctions] PRIMARY K ...Show All
SQL Server rda.SubmitSql cause outofmemoryexception
My application create quite a lot log file to submit to the server under WiFi coverage to monitor the application. (log is just txt file). as time goes on, submitsql method throw OutOfMemoryException. I agree my log file is quite big, 80K each and 6 log files to submit. My log submitter is an instance object. I also tried static object but it doesn't help either. I do dispose my rda object when it is out. Is any way I can fix this Just got log from my test scanner. It still has this exception. I will do more changes with "capacity" property. By the way, does StringBuilder has maximum capacity Cheers ...Show All
Windows Forms getting window client area coordinates in large windows
Hi! I need to acquire the client-area mouse coordinates in a window of a third party application. I have used GetCursorPos and ScreenToClient to get the mouse coordinates when the scrollbars are positioned at the top-left position. Unfortuanately the client area of the window who’s coordinates I need are usually much larger then the window itself. If you use ScreenToClient in the window when the scrollbars are positioned a few 1000 pixels to the right and down from the upper left corner you will get the position of the mouse pointer relative to the upper left corner of the visible part of the client area. Is there a way to get the difference between the upper left corner of the windows client area and the upper left corner of th ...Show All
Visual C++ Compile-time class generation causes C++ Compiler to Crash
Consider this example: template <int N> struct Factorial { enum { value = N * Factorial<N - 1>::value }; }; template <> struct Factorial<0> { enum { value = 1 }; }; void foo() { int x = Factorial<4>::value; } It compiles and runs fine. But if you remove the code in bold, the C++ compiler crashes (probably because of a stack overflow). I tried looking for a support link in order to report this but found none. P.S.: code sample taken from http://en.wikipedia.org/wiki/Template_metaprogramming Don't know, I tried Factorial<489> and Factorial<490>. 489 works and ...Show All
