olelar's Q&A profile
Game Technologies: DirectX, XNA, XACT, etc. Using Static Members
In my projects, instead of passing the GraphicsDeviceManager and the SpriteBatch by reference to the constructor of every class that will need them, or directly to every method that needs it, I prefer making them both Public Static Members of my main class, thus being available anywhere in the program. I would like to know, is this a bad solution And if so, why is that I understand one of the reasons is portability. If I passed them by reference, then I could re-use those classes in other applications without any change. But consider that I'm using these classes for my own application only, and if I needed to use it somewhere else, the changes to be made are still minimal. On the other hand, by using the Static approach, both classes and ...Show All
Visual Studio Express Editions image converter
Roughly, what code do I need to make a simple image converter, say, from .jpg to .bmp I was thinking maybe looping through the images in a folder and converting it to the type... but how would i do that Just for your opinion on the code you would use. Code please (if you can). Send the following Sub your InputFileName, your OutputFileName, and your OutputImageFormat. Sub ChangePictureFormat( ByVal InputFileName As String , ByRef OutputFileName As String ) Dim FileImage As Image = Image.FromFile(InputFileName) FileImage.Save(OutputFileName, Imaging.ImageFormat.Bmp) End Sub ...Show All
Visual Studio Express Editions binary
I know you can convert a string to hexadecimal using the Hex() function but is there one to convert a string to what it looks like in binary Public Class A2SB Private Function BCon(ByVal InputValue As String, ByVal InputBase As Long, _ ByVal OutputBase As Long) As String Const csValidChars As String = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ" Dim cuOutputCharCount As Decimal, lInputCharCount As Long Dim lCounter As Long, sCompareWith As String, sChar As String Dim dDecimalChars As Double, lPos As Long, cuBitValue As Decimal Dim cuDecimalValue As Decimal, sOutput As String On Error Resume Next If (InputBase < 2) Or (InputBase > 36) Then BCon = "" Exit Function ...Show All
SQL Server ReportServer - http://localhost/ReportServer - Error
An internal error occurred on the report server. See the error log for more details. (rsInternalError) Get Online Help Object reference not set to an instance of an object. And my ReportServer log: <Header> <Product>Microsoft SQL Server Reporting Services Version 9.00.1399.00</Product> <Locale>en-US</Locale> <TimeZone>Pacific Standard Time</TimeZone> <Path>C:\Program Files\Microsoft SQL Server\MSSQL.3\Reporting Services\LogFiles\ReportServer__03_24_2006_16_45_06.log</Path> <SystemName>USPROFILING</SystemName> <OSName>Microsoft Windows NT 5.2.3790 Service Pack 1</OSName> <OSVersion>5.2.3790.65536</OSVe ...Show All
Visual Studio From VS 2003 to VS 2005 on Vista - Can't compile
Hello, I'm trying to move an application to VS 2005 on Windows Vista, but it won't compile. The error I get is: 'The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)' C:\Users\MyLogin\Documents\Visual Studio 2005\Projects\AppName\LC I have no reference to anything called "LC", and there's NOTHING in the code that references anything called "LC" (e.g. No variables, no component names, no methods, no properties, etc.) though I am using some components including a button from the Visual Basic Resource Kit for VS 2003. I've installed the other components, and things "should" ...Show All
Visual Basic First time user of Visual Studio 2005...need help DESPARATELY
I just started using visual basic the otherday..from visual basic 6....which by the way I'm still trying to master. Anyway i started this project that I saved and possibly built even before I could finish it. Now I can't get my forms to open in the windows form designer...even when I double click them in the solutions explorer... Detailed assistance required Please....I have a deadline for this project....and already facing hurdles Honestly, there aren't any errors.....It just so happens that I double click the form in the solution explorer and am stuck with the code editor. When I open the project...it's the sam eeditor that I see. I have tried debugging and I get to see my form but ....I want to edit it ...Show All
Visual Studio 2008 (Pre-release) Does WCF support message encryption using short key?
Can a Web Service with message security using less than 128-bit encryption key be implemented in WCF It seems that there is no System.ServiceModel.Security.SecurityAlgorithmSuite class with key length lower than 128-bit. In general, can you advise on the approach to developing a secure web service that can operate under strong encryption requirement in the US and a relaxed encryption abroad due to encryption export restriction Thanks! I replied in this thread to keep the discussion localized. ...Show All
Visual Studio Team System How to publish (clickonce) a solution
Hi, I havent been able to find anything to help me to do this. I can do this manually thru the IDE, but not thru the Build Types. What do I have to place in the Build Type to get the program and its files published to our website I tried the following with no luck I just get an Entry Point error and I dont understand why. Please help. ======== < GenerateApplicationManifest AssemblyName = " AdminUtilGUI.exe " AssemblyVersion = " 1.28.1.0 " EntryPoint = " @(EntryPoint) " OutputManifest = " \\dalxpdss\DMDB_CODE\MARS Branch Project\DailyBuild2\Sources\daily build\MARS_Platform\Tools\MarsServerAdmin\SysAdminTools\obj\Release\AdminUtilGUI.exe.manifest " > < ...Show All
SQL Server File Metadata and the Foreach Loop Container
Hello, I want to set up a Foreach loop container to loop through several flat files. I have a connection manager set up for individual flat files. The metadata for the files is all the same. They are fixed width files, and contain sixty five columns. I didn't see a place in the container properties to configure the metadata of the files. How can a Foreach Loop Container 'know' the metadata of the flat files that I want to loop through Thank you for your help! cdun2 I tried to implement this by following SSIS Tutorial Lesson 2 and the pkg only processed the last file in the list. From one I can tell from the project log, it didn't even loop through the other files, though it did process the las ...Show All
.NET Development Verifying Backup integrity using MD5 of file
I'm using C# to connect to a UNC path on the network and create an MD5 of the backup file I'm checking. I can use System.IO.File.Exists (path) and it returns true, but when I try and use the following code: try { //MessageBox.Show(File.Exists(@ \\192.168.101.5\c$\backup\backupFile.zip ).ToString()); FileStream fs = File .Open( @"\\192.168.101.5\c$\ backup\backupFile.zip " , FileMode .Open); MD5 md5 = MD5 .Create(); byte [] data = md5.ComputeHash(fs); StringBuilder hash = new StringBuilder (); for ( int i = 0; i < data.Length; i++) { MessageBox .Show( "Into For loop" ); // The following line should be data[ i ] but the emoticon takes it over hash.Append(data .ToString( &qu ...Show All
Visual Studio 2008 (Pre-release) How do I intercept HTTP communication between a WCF client and a generic web service?
How do I intercept HTTP communication between a WCF client and a generic web service in code If you prefer to use a tool like TcpTrace to intercept the messages (as opposed to using the message tracing facilities in WCF), you can insert a via element in your client configuration: http://www.winterdom.com/weblog/2006/04/17/RedirectingThroughTcpTraceWithWSEAndWCF.aspx ...Show All
SQL Server Getting the count of rows for 3 tables in Single Execute SQL task
hi frnds, im very new to SSIS package .my package consists of Single Exceute task. In Single Exceute SQL task i had 3 seperate queries to get the count of rows of 3 tables. the Query goes like dis ... select count(*) AS precheckcount1 from new_main_dts where cust_nbr like '875%' like dis for another 2 tables i had written with the alias name precheckcount2 and 3 i mapped the variable user::precheckcount1 to precheckcount1 in the resultSet and for other two alias name i did the same. while executing the package the error is thrown : [Execute SQL Task] Error: An error occurred while assigning a value to variable "precheckcount2": "Unable to find column precheckcount2 in the result set.". please hel ...Show All
Software Development for Windows Vista SequenceActivity inheritance
Hi! I have a few custom activities which all inherit from my base class which inherits from sequenceactivity. Is is possible to use the designer in both my base class and the other custom activities Specificaly, I would like to add a ifelse to my base class which should be run after the flows that inherit from this base class have completed. Is this possible Thanks for your help! Once you add built in children to a custom activity or base workflow, one you intend on deriving from, it becomes locked. This means no more children can be added. One way to get around this is to have a custom toolbox item that adds the child when the activity is added to the workflow, see this post for info. Keeping t ...Show All
SQL Server Parent Child Relationship
I created a parent child relationship in SA 2005. It works great, except when adding it to the cube and browsing it. It shows the ID instead of the Name attribute. How do I make it show the name attribute Thanks in advance, Mardo Suppose you have the following columns in your table: ID - Integer. Primary key column of your table ParentID - Integer. The id of the parent object. Name - String. The name of the object identified by ID. Since things already work for you then you already have the key attribute and parent attribute set in your dimension. To resolve your problem select the parent attribute oin Dimension Structure page of the dimension editor and press F4 to activate the property grid displaying the properti ...Show All
Visual Studio Team System Team Build producing PDB files despite Release Mode Configuration Build
Hi All, I have a Web Application Project built with Web Deployment Project and another web service project being built via Team Build. How come when building in Release mode there are pdb's still generated for some projects and not for all My WAP or Web Service projects generates a PDB. I don't really understand this logic. It shouldn't do that. Cheers mike The build configuration of web applications is NOT defined by the build configuration, it is defined by the debug attribute of the compile element in web.config. The reason for this is that web applications are typically compiled at run-time when the application is first accessed (unless it is pre-compiled) so web.config is used. ...Show All
