Alexander Petukhov's Q&A profile
Community Chat any help for finding out CPU temperature? and RAM usage? in Dot net?
any help for finding out CPU temperature and RAM usage in Dot net thx.. We andrew, the DLLs you refer aren't MS DLL's they come from the boad manufacturer. The real answer is that CPU temp is just not available unless you have a driver/dll combination. Ram usage on the other hand is quite easy. See an example of the performance monitor in show and tell. But Biche is quite correct, this is not the place to make such an inquiry. ...Show All
Visual Studio Team System Dynamic variable in Team Build script
Hi All I have a 'Team Build' staging build script. This staging build actually builds off a LABEL. The process is that when the Dev Code Line is ready for staging, we label it and then staging build builds that Label. Why we do this is to get the accurate Build Report i.e. get the changeset and work item list in that label for that particular code line. If i don't specify the label, it gives me changeset and work items affected in DEV and QA code line. To restrict it just to 1 code line, we label that code line and build it. Now, the issue is that i have to update the label everytime and then kick off the build. This is very manual process and nobody here likes it. I am trying to update this. Is there a way i can have the label number as ...Show All
.NET Development Help vb.net db problems!
hi im a vb.net newbie. im trying to connect a access database to vb.net using jet. i would like the database to fill in the interface in the form i created but when i run it, it shows this error message: An unhandled exception of type 'System.Data.OleDb.OleDbException' occurred in system.data.dll. When i tried using TRY..CATCH it showed this message: Record(s) cannot be read; no read permission on 'tblTest' tblTest is the table in my db. This is the code: Dim con As New OleDb.OleDbConnection Dim ds As New DataSet Dim da As OleDb.OleDbDataAdapter Dim sql As String Dim mytbl As DataTable con.ConnectionString = "PROVIDER=Microsoft.Jet.OLEDB.4.0;Data Source = C:\DB\test.mdb" ...Show All
SQL Server Need Help on this SQL Statement
Hi All, sqlLstProds="Select * From PRODUCT_DEF "&_ "WHERE productID IN(Select productID From PRODUCT_DEF WHERE (IDProductCriteria = 5) AND ([Value] = '"&getSession("ModelID")&"')) "&_ " Order By IDProduct, IDProductCriteria" I have the above SQL Code in an ASP page. This queries the Product_Def table, however there is also a table called Product_sType, the primary key in that table is productID which corresponds to productID ub the Product_Def table. I need to add to the query a where clause, where active = 1 active 0 is obviously discontinued products, how would I do this So basically, it's somewhat of a join of some sort, like select * from Produc ...Show All
Visual Studio 2008 (Pre-release) Error 403 when browsing to Service.svc file
I am trying to run one of the wcf samples. I am deploying the server to IIS 6 and keep getting Http Error 403 Forbidden when I try to browse to the service.svc file. The directory and files appear to have the right permissions set. I added a Default.aspx page to the same directory and it works fine. I changed to Basic authentication and the Service.svc file returns the 403 error before I am even prompted to login. The Default.aspx page prompts me to login and then displays correctly. I had the sample working fine on my Windows XP workstation it just won't run on Windows Server 2003. Does anyone know what else I can check to get this working Thanks, Matthew Hello, What happens if you try to ...Show All
Internet Explorer Development Problem with overflow-x
following is some code with strict doctype <div id="a" style="width:300px; height:300px; background:green;"> <div id="b" style="overflow-x:auto;height:100px; margin:10px; background:orange;"> <div id="c" style="width:400px; height:200px; background:blue;"></div> </div> </div> div#c's width is larger than div#b's, so a scroll bar should add to div#b, but in IE6 there is no scroll bar and div#b's width will be adjust to include div#c, why overflow-x cannot work here I found that if I set div#b's width=200px or 100%, then the overflow-x property works!! Can anyone gives a hand I have no assistance to offer. But I was wondering if you ...Show All
Windows Forms How to call a web page as Post method from Windows Form Application?
I have a form application with some TextBox controls in it.I want to send the values of these controls as Post variables to the web page. I can call a web page using System.Diagnostics.Process.Start("Http://...") but how to make a call like it was called from form element with method post I used WebClient instead.It seems to be just for those kinds of tasks. Now the problem is the page is giving me response "Not signed in...".And page is using cookies for authentication. Thats the reason I tried to call Browser so I would already be authenticated. I discovered CookieContainer class but WebClient doesnt seem to have that.So do I need to switch to HttpWebRequest instead ...Show All
SQL Server dynamic pivot table
hi i am trying to create a dynamic sql statement so i can pivot information... my problem is that when i run this query i get the error information below. i am running sql server 2000... can this run in 2005 this runs perfectly when only one record is returned in the sub query... declare @query varchar(300) select @query = 'Select '+ char(10) + ( select Code +'case when Code = '''+ Code +''' then count(Code) else 0 end as '+Code+''+char(10) as [text()] from WipAvailable WA )+ char(10) + ' from WipMaster group by Code' select @query exec (@query) Server: Msg 512, Level 16, State 1, Line 3 Subquery returned more than 1 value. This is not permitted when the subquery follows =, !=, <, <= , >, > ...Show All
SQL Server Visualize more than one attributes of the elements in a XML
Hello Again. I need to visualize the attributes of a xml file like a column. I have this xml file in a sql column: '<Root> <Gato id="0123" sitio="por aqui"/> <Gato id="2536" sitio="por alla"/> <Gato id="4587" sitio="por acuya"/> </Root>' I need to see the "column" id by example in this form ID 0123 2536 4587 there is any way to do this with xquery.value if i can't do that there is another way to do this without using OPENXML Thanx again create table mytable(x xml) insert into mytable(x) values ('<Root> <Gato id="0123" sitio="por aqui"/> <Gato id=&quo ...Show All
Visual Studio Express Editions The keypress event
I have my program setup to hide itself when a button on the form is pressed, is there a line of code that would (me.show) itself when the "q" key is pressed. I have tried many things but nothing works. Average Joe How you gonna press a button on that form if its hiden ;P and in vb.net theres no Me. longer ... anw its Form2.Show() or Form2.ShowDialog() diffrence is if you use first you can change back to form1 wen form2 is still open ..with the 2nd way you cant.... ...Show All
SQL Server Prediction Join to MDX with nested table
If your prediction join is to a SQL datasource, you can easily write a SQL query which returns a nested table like: SELECT Predict([Subcategories],2) as [Subcategories] FROM [SubcategoryAssociations] NATURAL PREDICTION JOIN (SELECT (SELECT 'Road Bikes' AS Subcategory UNION SELECT 'Jerseys' AS Subcategory ) AS Subcategories ) AS t What about if your datasource is a cube Is there some special MDX syntax similar to the SQL syntax above Or do you have to utilize the SHAPE/APPEND syntax as follows SELECT t.*, $Cluster as ClusterName FROM [MyModel] PREDICTION JOIN SHAPE { select [Measures].[My Measure] on 0, [My Dimension].[My Attribute].[My Attribute].Members on 1 from MyCube } APPEND ( { select [Measures].[Another Measure] on ...Show All
Visual Basic sorting the files in a folder
how to sort the files in the folder according to the date modified/written i am getting the file (code snips) Dim dDir As New DirectoryInfo(pathIssueFile) Dim fInfo As FileInfo() fInfo = dDir.GetFiles("*.txt") is there any methods to sort the files [according to the file modified ] while Getfiles.. or any other methods.. avilable.. thanks in advance..... Sort the returned array - Private Sub Consume_Load( ByVal sender As Object , ByVal e As System.EventArgs) Handles Me .Load Dim dirinf As New IO.DirectoryInfo(Application.StartupPath) Dim fls(1) As IO.FileInfo Array.Sort(fls, AddressOf Sortfiles) End Sub Public Shared Function SortFiles( ByVal x As ...Show All
Windows Live Developer Forums Script Help!
I am trying to put a textbox and button into a custom map control and it won't work! Here is My Script: <html> <head> <title></title> <meta http-equiv= "Content-Type" content= "text/html; charset=utf-8" > <script src ="http://dev.virtualearth.net/mapcontrol/v3/mapcontrol.js" ></script> <script> var map = null; var layerid=1; var layerid2=1; function GetMap() { map = new VEMap('myMap'); map.LoadMap(); AddMyControl(); } function AddMyLayer(type) { var veLayerSpec = new VELayerSpecification(); veLayerSpec.Type = type; veLayerSpec.ID = layerid; veLayerSpec.LayerSource = 'http://a ...Show All
.NET Development Computer real clock (CMOS)
How can I get the computer real clock (the one that is in the CMOS, not the windows clock) or the real computer epoch Thank you people in advanced. Technically, you can access the CMOS registers through I/O ports. There's a real danger however that this will interfere with proper system operation if you do this at just the wrong time. Windows obtains the time from CMOS when it starts up and auto-correct the CMOS clock when it gets an update from a time server. Either way, the windows clock and the CMOS clock should be in sync. Do you have problem with the century ...Show All
Game Technologies: DirectX, XNA, XACT, etc. mesh not rendering
I set up my camera matrix to look at the origin. Then in my render loop I transform to the cameras matrix d3d->GetDevice()->SetTransform(D3DTS_VIEW, camera.GetViewMatrix()); begin the scene and set the render state. d3d->BeginScene(); d3d->GetDevice()->SetRenderState(D3DRS_FILLMODE, D3DFILL_WIREFRAME); then transform to the meshes matrix d3d->GetDevice()->SetTransform(D3DTS_WORLD, m_Object->GetMatrix()); and render the mesh m_Object->Render(d3d->GetDevice(), &meshes[m_Object->GetMesh()]); end the scene. nothing shows up on the screen, I took a look in the debugger and everything is positioned where it should be, is this not the proper way to set up the render loop. ...Show All
