johnnyXNA's Q&A profile
Windows Forms Textbox default value
Is it possible to put a textbox on a form, set its default value to 0 then Change it in code and keep the new number, even after the app is closed I know I can change the default value of a textbox by code, but is there a way to keep your changes permanently Davids Learning You may want to look into using My.Settings to save the value when it is changed (or the form is closed) and then to read from on startup of the form to retrieve the saved value. ...Show All
.NET Development D
We are upgrading a program from VS03/Sql MSDE to VS Professional 05/SQL 05 Express Edition (SQL Server 2005 Express Edition With Advanced Services SP1 to be exact). The VB code converted fine, but the data has been a disaster. We have tried this with/and without the 05 SP1 Beta and have the same problem. In the 03 IDE, we created many Data Adapters in the Component Designer (just called Component in 05) with multiple tables. In 03 everything worked. In 05, when you configure the existing data adapter, if there is more that one table, you get the error: Dynamic SQL generation is not supported against multiple base tables. and the data adapter is useless. If this is not supported in 05, what do we d ...Show All
Visual Studio Express Editions Coolest toy...
As an older person who thinks fun is learning how to program with Visual Basic, I can't express how great it is to have this software, the learning materials and the instant online internet access to, essentially, a classroom. Super! Thank you, Microsoft. PS: I have this installed on my amazingly fast and stable Vista-- thanks for that too. Hi there stardis we/Microsoft appreciate the positive feedback and hope you will have much success and enjoyment of newer products in the future. We value your feedback greatly! Have a great day! ...Show All
.NET Development Specifing the time intraval in win service
Hi guys, I want to set the intraval time as 24hours i.e only once per day i shud run my windows service to perform the task.Moreover i have coded to start my service after one minute of log on and now i have to set the time to run the task.I am struck in specifing the time. Please look at the underlined line of the code and suggest me how to do it. Thanks for ur kindness, Karthik ----------------------------------------------------------------------- public void OnTimedEvent(object source, ElapsedEventArgs e) { AddEventLog( "Buildfolio Services entered" ); try { if( timer!=null ) timer.Stop(); foreach( IService s in subServices ) { try { s.TimedEvent(); } catch( Exception ex ) { AddEventLog( "Sub Service: Exception "+ex ...Show All
Visual Studio Express Editions Convert decimal to fraction
Does VB have any built-in function to convert a decimal number to a fraction What I need is a way to convert a decimal number into a fraction string rounded to the nearest 32nd. So for example, .375 would be converted to "3/8" or .428 would be converted to "7/16" after rounding. If VB doesn't have this built-in, does anyone have code for a function to do this Thanks... Hi, Is your problem solved If yes then could you please mark reply as answered Thank you, Bhanu. ...Show All
Visual C++ <windows.h> Interferes with System::IO::Directory::GetCurrentDirectory();
Including windows.h in a managed project overrides System::IO::Directory::GetCurrentDirectory();, which is very annoying: rootFolder = System::IO::Directory::GetCurrentDirectory(); //'GetCurrentDirectoryW' : is not a member of 'System::IO::Directory' How can this be prevented This seems to be the only function in wondows.h that gets confused with System::... If you do not need the GetCurrentDirectory function from windows.h , maybe you can just un-define it: #include <windows.h> #undef GetCurrentDirectory I hope this makes sense. ...Show All
Visual Studio Maintaining data session state in the CrystalReportViewer
I finally got a .NET DLL datasource to work for my crystal report. Now I'm wondering if I'm fighting with an 'easier way, that may be already built into Crystal Reports. I've included two routines 1) Page Load - This routine checks the user's ID from Windows which is an NUID, it then takes that NUID to find that user in an Admin table, a Supervisor Table, to decide what type of data should be in the dataset of the report. The routines are nicely streamlined and are based off of stored procedures. Depending on the rank of the person's NUID, that person will see more 'Training status's of various employees. The idea is to have the page automatically display what is valid to that person when they open the page on our intranet. 2) ...Show All
Visual Studio Express Editions What Am I Doing Wrong
1>------ Build started: Project: Homework, Configuration: Debug Win32 ------ 1>Compiling... 1>Homework.cpp 1>.\Homework.cpp(16) : error C3861: 'printf': identifier not found 1>.\Homework.cpp(19) : error C3861: 'printf': identifier not found 1>.\Homework.cpp(20) : error C3861: 'printf': identifier not found 1>.\Homework.cpp(21) : error C3861: 'printf': identifier not found 1>.\Homework.cpp(28) : error C3861: 'printf': identifier not found 1>Build log was saved at "file://c:\Documents and Settings\Lorne's School Work\Random\Homework\Homework\Debug\BuildLog.htm" 1>Homework - 5 error(s), 0 warning(s) ========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ======= ...Show All
.NET Development .Net 1.1 forward compatibility
Hi I have an C# application compiled with VS 2003 (.Net 1.1) that needs to use a dll compiled with VS 2005 (.Net) 2.0. The machine have both runtimes installed but the application refuses to use the dll since it been created by newer version. Is there any way to work in VS 2003 with .Net 2.0 dll's Thanks. Michael, The metadata format of assemblies changed between 1.1 and 2.0 (in order to support generics). The compiler needs to understand this new format, which is one of the reasons that it's not possible to forward target 2.0 with 1.1. As Mattias suggests it may be possible to dynamically load the assembly assuming that the application is running on the 2.0 CLR; however, if the machine that the ...Show All
Visual Basic specify the browser version of WebClient Class
currently, I use the following codes to get HTML sources code of a web page. Dim client As New WebClient() Dim address As new Uri(" http://www.yahoo.com/ ") Dim filename As String filename = "C:\tmpfile.txt" client.DownloadFile(address, filename) the codes work fine, except Yahoo has a check on the browser version and returning a "simple version" of it's main page. Do I have to use WebBrowser instead of WebClient If so, how to do it Thanks for help. ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Could C# be the future of gaming?
Since XNA is using C#, and is is a more intuitive language than C++, is it possible that in the future that C# will dominate, espessially in AAA titles. Could XNA be ushering a new way of programming in the main stream I think people underestimate the performance of managed code. There are not many scenarios where unmanaged code will significantly out perform managed code. When people start to better understand how the garbage collector works and ensure that objects stay small and prevent them from getting promoted to generation 1 and 2 it will make a big performance increase. From what I understand the GC on 360 is the same as in the compact framework, so I’ll have to read up on the differences. If you lo ...Show All
Visual Basic System.IO.FileNotFoundException: The specified module could not be found. (Exception from HRESULT: 0x8007007E)
Hi, I run an online Railroad simulation with a Community of some 60-70 players. Just recently 2 of the players have had to re-install Windows and hence the Simulation and now when they attempt to load it they get " System.IO.FileNotFoundException: The specified module could not be found. (Exception from HRESULT: 0x8007007E)" No others are affected and indeed a couple of new players who have installed the game in the same period have had no problems. I have sent the affected players a list of the loaded Assemblies and both have confirmed all are present and correct. I am using VB Express with .NET Framework V2.0 and the DirectX Redistribution from October 2005 (ie Direct3DX 1.0.2908 with the other DirectX Assemblies ...Show All
Smart Device Development question about Numeric up down control
Is it possible to use Numeric up down control within Listview So that i can use the arrow to edit numeric data in the list view. Is it possible to do that Please help. Thank you Not an easy task, but doable. Check these blog posts on how to do it with theTextBox: http://blog.opennetcf.org/ayakhnin/PermaLink,guid,4d82068f-0b25-4b01-825d-4dffb0335817.aspx http://blog.opennetcf.org/ayakhnin/PermaLink,guid,d652ddf7-8702-4253-a431-357703dc63c1.aspx ...Show All
Windows Forms SignUp Forms VisualWebDev 2005 Express
hya im using visual web dev 2005 express. im wondering, when you make a signup form(create new user wizard) when you use this in production, where does the data go can you access the individual data(username,pw,security question) from within your application and or can you change or delete the individual data items from within your application ...Show All
.NET Development unable to download file
below i've attached my code. if i copy and paste the url and query string into a web browser, i get in return a file with data based on the query string. i want to be able to do this without having to use a web browser. is this possible what is the next step i need to take with regards to coding any help at all would be greatly appreciated. thanks. static private bool CertificateValidationCallback(object sender, X509Certificate certificate, X509Chain chain, SslPolicyErrors sslPolicyErrors) { &n ...Show All
