Jim Agla's Q&A profile
SQL Server SqlDataSourceEnumerator.Instance; not returning all instances
...static void Main() { // Retrieve the enumerator instance and then the data. SqlDataSourceEnumerator instance = SqlDataSourceEnumerator.Instance; System.Data.DataTable table = instance.GetDataSources(); ... Hi MS SMO folks, I'm not getting all instances returned in my table. I know there are issues surrounding this call but I have 1 dev box, 1 nt 2003 server and a total of 3 sql srv instances. 2 of which are on my local dev machine. All are 2005. Both servers have SQL Browser enabled and all protocols are enabled. All of my MacAfee and Windows firewalls are temporarily Off. The only instance returned is mylocalbox/sqlexpress. I can understand why it may not see the server, due router or other h/w, but what I really d ...Show All
SQL Server SQL2005 Active\Passive Cluster Install ?
yesterday i installed sql2k5 on a active\passive cluster and for some strange reason the mssqlserver service does not want to start up on the node that i installed it on but if i fail it over to the passive node it will start fine. system info below: system info: * win2k3 enterprise r2 (x64) cluster active\passive* * sql2k5 enterprise (x64) clustered* the win2k3 cluster works fine. i installed the msdtc service running as a cluster as well and that works fine. both servers are identical to each other. sql virtual server is running on the passive node which is now the active node. any ideas --alan well after reading through the event logs i discovered that we had a dns issue with one of th ...Show All
Visual C# predefined attributes
Are there any references on the ~200 predefined attributes in .Net/C# I can't find -any- information.. Can only get references on STAThread, Obsolete, Usage, Conditional.. Keith, Are you looking for a list of all the predefined attributes, or is there a particular attribute you want to know about but can't find documentation for Or is there specific functionality you are looking for and you want to know if there is already an attribute that provides it -Tom Meschter Software Dev, Visual C# IDE ...Show All
Visual Studio Express Editions Abstracting values
How do you abstract a value (data) in the cell (nt row) in the selected datagrid row The following code. Will load a number of rows into a datatable and set this as the datasource on the datagridview control. Then when I click the button it will determine that there is at least one row selected and then display the first and second columns from this selected row. The selectedrows is simply a collection which you can iterate over and the rows and cells can be used to refer to items by ordinal value. This is a real simple example but there is nothing special about the selectrows collection. http://msdn2.microsoft.com/en-us/library/4wszzzc7.aspx http://msdn2.microsoft.com/en-us/library/system. ...Show All
Visual Basic Opening csv files through web
Hi, I'm using the following code to open a csv (comma separated values) file over the web. The problem is, when Excel opens the file, it puts each line in the first cell of each row, completely ignoring the commas. I tried using other content types, but they all do the same thing. Any help would be great. Thanks. <% Response.buffer = TRUE Response.ContentType = "application/x-msexcel" Dim vntStream Set oMyObject = Server.CreateObject("MyObject.BinRead") vntStream = oMyObject.readBinFile("c:\temp\tempcsv.csv") Response.BinaryWrite(vntStream) Set oMyObject = Nothing Response.End %> Function readBinFile(ByVal bfilename As String) Set oFSO = CreateObject("Scripting.FileSystemObject") ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Skin weight Transforms and Model Importer
Hey, where do you guys store the transform matrices for skin weights in the content pipeline It seems that they are merged with the bone matrices before they are passed to the processor. Also, is there any way to extend the .X file importer class There are a lot of situations in which this can be useful. Thanks, but I loaded the vertices from a custom processor to the model (ripped them out before base.process()) and used the model bone matrices to skin it. On rendering, it appeared exactly as if the bone transforms stored in the skinning info were never added (I tested this by taking a model with skinning info such that each vertex only mapped to one bone, and then changed the bone transforms in the ski ...Show All
Visual C++ summing elements of a vector(class) with class elements
Hi, I'm using Visual Studio 2005 and trying to use "accumulate" function in order to sum elements of type vector class. However, the elements of the vector in question have are objects, namely: class bond { public: double strength, prob; bond() : strength(0), prob(0) {} bond(double x, double y) : strength(x), prob(y) {} }; void main() { vector<bond> bond_array(N); // N: very large double sum_total //say the elements of vector bond_array are full with values ... sum_total=accumulate(bond_array.begin(), bond_array.end(), 0); //This command is incomplete, see the question. ... } What I'm trying to accumulate is actually ".prob" of all elements of type bond in vector, and the parameter sum_total will be assigne ...Show All
Visual C++ Visual C++ Express, open a child form.
When I try to open one form from another, I get the error at compile: 'Manifest' : is not a member of 'AlaskaFreight' Mainfest is declared as follows in the Manifest.h file containing the form code: namespace AlaskaFreight { public ref class Manifest : public System::Windows::Forms::Form { Manifest shows up under 'AlaskaFreight' in the Solution Explorer, Class View explorer and even pops up from Intellisense when I type in the code: AlaskaFreight::Manifest^ oform = gcnew AlaskaFreight::Manifest(); oform->Show(); I'm not sure if it's appropriate to use the pointer Manifest or not, but either way I still get the error. Any ideas Thanks Never mind, I found ...Show All
SQL Server How to recover from dropped tempdb?
I am testing sql server 2005 in different disaster situations happened under 2000. I was reading a lot about no update on system tables, so: sp_detach_db 'tempdb' In sql 2000 i could issue something like the following command to recover: use master sp_configure 'allow updates' , 1 reconfigure with override go insert sys.sysdatabases ( name , dbid , sid , mode , status , status2 , crdate , reserved , category , cmptlevel , filename , version ) values ( 'tempdb' , 2 , 0x01 , 0 , 8 , 1090520064 , '2007-01-27 13:03:10.873' , '1900-01-01 00:00:00.000' , 0 , '90' , 'D:\beep\mssql\temp\tempdb.mdf' , 611 ) go sp_configure 'allow updates' , 0 rec ...Show All
Visual Basic My Namespace
I have 3 projects in my solution and in one of the projects called Library there is a module Utilities in which i have given following line at top Namespace My.MyApp (I have intentionally done this instead of adding it to My.Application to keep it seperate from built in stuff) Within the library project, i'm able to access My.MyApp.MyFunction1() My.MyApp.MyFunction2() etc. But in the other project it is not showing MyApp in My Namespace. Can anybody help in this. please note 3 projects are having following root namespace :- 1. Library :- Root namespace is Library 2. OmWin :- Root namespace is OrdersManagement (this is the startup project, windows forms application) 3. O ...Show All
Visual Studio Express Editions Why am I getting "End of statement expected"?
Hello, Why am I getting "End of statement expected" Thanks for the help. Ken Private Sub txtReadRegValue_TextChanged( ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtReadRegValue.TextChanged if txtreadregvalue.Text not txtreadregvalue.Text then cmdOpenPort.PerformClick() End If End Sub Try This. Private Sub cmdReadRegister_Click( ByVal eventSender As System.Object, ByVal eventArgs As System.EventArgs) Handles cmdReadRegister.Click cmdOpenPort.PerformClick() Dim Response, message, msgg As String Dim command_type, addres As Short Dim registerr As Single ...Show All
Windows Forms Creating my own TabPage class
I have a tabcontrol on a form. If I add tab pages and add controls to them in Visual Studio the controls become members of the main form and the main form will also handle all events from all controls on all tab pages. I want to create my own TabPage class that handles everything that happens in the TabPage to avoid having all code in the main form. I created MyTabPage class by adding a new Component to the project and changing the base class to TabPage. I am able to drag stuff from the Toolbox onto my TabPage in Design mode. In the designer for the main form I added another tab page to the tab control and changed the type from TabPage to MyTabpage in the main form code. However, I am not able to see any controls in the tab when I ...Show All
SQL Server SQL Express running slow on Small Business Server
Hi We have SQL Express running very slowly on Small Business Server. Does anyone know if there is a conflict between the two Or any ideas on how to solve our problem ( Autoclose is set to false) Thanks There are a lot of ways to find out what is happening in your database system that is affecting performance. Start with this series of articles: http://www.informit.com/guides/content.asp g=sqlserver&seqNum=195&rl=1 Buck Woody ...Show All
Visual Studio Express Editions Inputbox
I've seen this tool in Visual Basic and Visual For Pro. But is there an equavilancy of this function is C# .NET Express Straight forward question =] Thanks in advance Vinces, Windows Forms does not have an InputBox control. However, Les Smith wrote one for C#. Check it out at http://www.knowdotnet.com/articles/inputbox.html -- Tim Scott http://geekswithblogs.net/tscott/ ...Show All
.NET Development Com Interop with a .Net Application
Hello! Is it possible, to have a C++/CLR project compiled as an application, und expose some classes through Com-Interop to Com-Clients I want to run an application, but let some Com/DCom-Clients (alongside with a local user) take control of that application I've tried to make a new Visual C++ CLR Console Application (Visual Studio 2005), define a class and make it com-visible, same procedure, same class as with generating a Class Library, but when I try to register it with regasm, he throws out the following error message: Microsoft (R) .NET Framework Assembly Registration Utility 2.0.50727.42 Copyright (C) Microsoft Corporation 1998-2004. All rights reserved. RegAsm : error RA0000 : Attempt to load an unverifiable executab ...Show All
