Daily Archives

Articles indexed Friday April 30 2010

Page 18/114 | < Previous Page | 14 15 16 17 18 19 20 21 22 23 24 25  | Next Page >

  • How to write a Criteria Query when there's an <any> association

    - by Bevan
    I'm having some trouble constructing the correct Criteria to do a particular query - after an afternoon of consultation with Professor Google, I'm hoping that someone can point me in the right direction. I have two entities of interest: OutputTsDef and NamedAttribute What I'm trying to do is to find all OutputTsDef that have a particular NamedAttribute value. I can write a detached Criteria to find all NamedAttributes that have a given name and value: var attributesCriteria = DetachedCriteria.For<INamedAttribute>() .Add(Expression.Eq("Name", "some name")) .Add(Expression.Eq("Value", "some value")); How do I inject this in to a query for OutputTsDef to restrict the results? var criteria = nHibernateSession.CreateCriteria(typeof(IOutputTsDefEntity)); // What do I write here? var results = criteria.List(); NamedAttribute looks like this - note the use of [Any] as we can have NamedAttributes on many kinds of entity. [AttributeIdentifier("DbKey", Name = "Id.Column", Value = "NamedAttributeID")] [Class(Table = "NamedAttributes")] public class NamedAttribute : BusinessEntity, INamedAttribute { [Any(0, Name = "Entity", MetaType = "System.String", IdType = "System.Int32")] [MetaValue(1, Class = "Sample.OutputTsDef, Sample.Entities", Value = "OTD")] [MetaValue(2, Class = "Sample.OutputTimeSeriesAttributesEntity, Sample.Entities", Value = "OTA")] [Column(3, Name = "OwnerType")] [Column(4, Name = "OwnerKey")] public virtual IBusinessEntity Entity { get; set; } [Property(Column = "Name")] public virtual string Name { get; set; } [Property(Column = "Value")] public virtual string Value { get; set; } ... omitted ... } In regular SQL, I'd just include an extra "where" clause like this: where OutputTsDefId in ( select distinct OwnerKey from NamedAttributes where Name = ? and Value = ? and OwnerType = 'OTD' ) What am I missing? (Question also posted to the NHUsers mailing list - I'll copy any useful information from there, here.)

    Read the article

  • SQLAuthority News TechEd India April 12-14, 2010 Bangalore An Unforgettable Experience An Opport

    TechEd India was one of the largest Technology events in India led by Microsoft. This event was attended by more than 3,000 technology enthusiasts, making it one of the most well-organized events of the year. Though I attempted to attend almost all the technology events here, I have not seen any bigger or better event [...]...Did you know that DotNetSlackers also publishes .net articles written by top known .net Authors? We already have over 80 articles in several categories including Silverlight. Take a look: here.

    Read the article

  • LIDNUG: Effective Silverlight with SharePoint 2010

    Ad:: SharePoint 2007 Training in .NET 3.5 technologies (more information). This feed URL has been discontinued. Please update your reader's URL to : http://feeds.feedburner.com/winsmarts Read full article .... ...Did you know that DotNetSlackers also publishes .net articles written by top known .net Authors? We already have over 80 articles in several categories including Silverlight. Take a look: here.

    Read the article

  • How to troubleshoot if a zip file is valid or if it is big file size to be unzipped ?

    - by mireille raad
    Hello , I am trying to unzip a file with the size of 2GB I am getting the following error : unzip CLTE_C_08.zip Archive: CLTE_C_08.zip End-of-central-directory signature not found. Either this file is not a zipfile, or it constitutes one disk of a multi-part archive. In the latter case the central directory and zipfile comment will be found on the last disk(s) of this archive. unzip: cannot find zipfile directory in one of CLTE_C_08.zip or CLTE_C_08.zip.zip, and cannot find CLTE_C_08.zip.ZIP, period. After some googling, some people say that this error is because the file is too big, others say because file is corrupt, others say that it could be a not unix archive. So my question , how to find out if file is valid archive file on my Centos and what is the command/trick to uncompress big files ( if any ) Thanks in advance :)

    Read the article

  • Hosting my ASP.NET website - ANY recommendations?

    - by Etienne
    I have a website hosting here in South Africa, but I am receiving terrible service from my hosting company. My database is down all the time and I cant get hold of anyone over weekends. I would prefer a company in the USA to host it who will be available 24/7 for support. Who would you recommend me using to host my ASP.NET site?

    Read the article

  • Win 2k3 - DNS query ?

    - by nXqd
    I'm learning about network and I configured DNS in 2k3. In forward zone : cntt.edu www.cntt.edu [ 192.168.188.4 ] . [ All IP / DNS configuration is right ] After that I use wireshark to catch packet when I enter www.cntt.edu in IE . I see there's no DNS here, I forward directly to 192.168.188.4, there's no query . Any problem ? Thanks for reading this :)

    Read the article

  • New reporting tool in .Net

    I had a great chance to try and use the new reporting tool in .Net. Its Fast Report.Net, after working with it, I concluded tha the job was well done because the new tool is effective and can be used with easy.

    Read the article

  • Android Plugin for Eclipse problem

    - by tbneff
    I am using a laptop with Windows 7 Home Prem x64. I have installed Java JDK1.6.0_18 and Eclipse Gallileo. I have downloaded and installed the latest version of Android SDK with several Platforms loaded and a AVD defined. I can install the Android Eclipse plugin from the remote site stated in the instructions. The plugin installation performs without any errors and I can verify that the plugins are indeed installed. My problem begins when I go to Windows - Preferences, there is no Android section to configure. And when I go to File - New - Project, there is no Android Project to choose. I have uninstalled the plugin and reinstalled at least 10 times, trying different things and still no luck. I originally had the 64 bit version of the JDK installed, but removed it and installed the 32 bit version. Has anyone heard of this type of problem? Is it because I am using Windows 7? Thanks for any help. tbneff

    Read the article

  • GenerateBootstrapper fails to create a working setup.exe

    - by Darren
    I’m seeing some odd behaviour I can’t explain. I'm using wix to generate a msi and using the msbuild GenerateBootstrapper task to handle pre-requisites. It all seems to build correctly i.e. there are no error or warnings but the generated setup.exe won’t run. It gives a nice blank error dialog and the event log gives about the same information. The kicker is that if I drop to the command line and run msbuild manually on the project and specify the bootstrapper target it generates a correct and working setup.exe. I've used this wix article as a base and a number of questions on StackOverflow to no avail. Has anyone seen this behaviour before, better still a fix?

    Read the article

  • How to remove insert image button from Yahoo Rich text editor

    - by Nitz
    Hey Guys, I am using ThickBox 3.1 one one page. Now, there is one problem, i am using one form to open thickbox on the button click event. And i am using yahoo text editor on that form. And in the yahoo rich text editor there is one link of image insert.. but i don't know why its not opening. on click of it. the image insert dialog is not opening. all things are working properly. Why is it not opening? and if is there anyway to only remove the image insert icon from text editor.

    Read the article

  • How to conditionally exclude features from "FeaturesDlg" in WiX 3.0 from a managed Custom Action (DT

    - by Gerald
    I am trying to put together an installer using WiX 3.0 and I'm unsure about one thing. I would like to use the FeaturesDlg dialog to allow the users to select features to install, but I need to be able to conditionally exclude some features from the list based on some input previously received, preferably from a managed Custom Action. I see that if I set the "Display" attribute of a Feature to "hidden" in the .wxs file that it does what I want, but I can't figure out a way to change that attribute at runtime. Any pointers would be great.

    Read the article

  • powershell errors on remove-item command

    - by Lachlan
    Hi, I've written a powershell script which removes folders more than 7 days old. It seems to be removing the folders, but for some reason its giving me errors. I was wondering if anyone might be able to tell me why? The script is... $rootBackupFolder = "\server\share" get-childitem $rootBackupFolder | where {$.PSIsContainer -AND $.Name -match ("^CVSRepository_(19|20)[0-9]0-9(0[1-9]|[12][0-9]|3[01])$") -AND $_.LastWriteTime -le (Get-Date).AddDays(-7)} | remove-item -recurse -force Their are 2 errors I get, this first is this one... (Get-Date).AddDays(-7)} | remove-item <<<< -recurse -force Remove-Item : Cannot remove item \server\share\CVSRepository_20100305\somesubfolder\sumotherfolder: Could not find a part of the path '\server\share\CVSRepository_20100305\somesubfolder\sumotherfolder'. The other error is this... (Get-Date).AddDays(-7)} | remove-item <<<< -recurse -force Remove-Item : Cannot remove item \server\share\CVSRepository_2010031 2\somesubfolder\: Access to the path 'Rdl' is denied.At C:\CVSRepository_BackupScript\Backup.ps1:43 char:38+ (Get-Date).AddDays(-7)} | remove-item <<<< -recurse -force Any ideas? The script is running under a domain account which has privs to delete the remote folders. And in fact it is indeed deleting the folders! But giving me errors... Thanks, Lachlan

    Read the article

  • 'Contains()' workaround using Linq to Entities?

    - by jbloomer
    I'm trying to create a query which uses a list of ids in the where clause, using the Silverlight ADO.Net Data Services client api (and therefore Linq To Entities). Does anyone know of a workaround to Contains not being supported? I want to do something like this: List<long?> txnIds = new List<long?>(); // Fill list var q = from t in svc.OpenTransaction where txnIds.Contains(t.OpenTransactionId) select t;

    Read the article

  • Full coordinates across streets with google maps

    - by nbv4
    If you go here: http://econym.org.uk/gmap/snap.htm there are some examples of the kind of stuff I'm trying to do. I want the user to enter a route on a google maps widget, and then have the map drawl the route along roads. Then the user click on a "submit" button, and their route is sent back to the server where it will be stored in a database. Instead of sending back just the red vertices, I want to send back all the information that makes up the purple lines. Is this possible?

    Read the article

  • Android: HTTPClient

    - by primal
    Hi, I was trying http-cleint tutorials from svn.apache.org. While running the application I am getting the following error in console. [2010-04-30 09:26:36 - HalloAndroid] ActivityManager: java.lang.SecurityException: Permission Denial: starting Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10000000 cmp=com.org.example/.HalloAndroid } from null (pid=-1, uid=-1) requires android.permission.INTERNET I have added android.permission.INTERNET in AndroidManifest.xml. <?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.org.example" android:versionCode="1" android:versionName="1.0"> <application android:icon="@drawable/icon" android:label="@string/app_name"> <activity android:name=".HalloAndroid" android:label="@string/app_name" android:permission="android.permission.INTERNET"> <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter> </activity> </application> <uses-permission android:name="android.permission.INTERNET"></uses-permission> </manifest> The java code in HalloAndroid.java is as follows HttpClient httpclient = new DefaultHttpClient(); HttpGet httpget2 = new HttpGet("http://google.com/"); HttpResponse response2 = null; try { response2 = httpclient.execute(httpget2); } catch (ClientProtocolException e1) { // TODO Auto-generated catch block e1.printStackTrace(); } catch (IOException e1) { // TODO Auto-generated catch block e1.printStackTrace(); } HttpEntity entity = response2.getEntity(); if (entity != null) { long len = entity.getContentLength(); if (len != -1 && len < 2048) { try { Log.d(TAG, EntityUtils.toString(entity)); } catch (ParseException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } } else { // Stream content out } Any help is much appreciated.

    Read the article

  • Alternative to NOT EXISTS

    - by Dave Colwell
    Hi all, I have two tables linked by an ID column, lets call them Table A and table B. My goal is to find all the records in table A that have no record in table B. For instance: Table A: ID----Value 1-----value1 2-----value2 3-----value3 4-----value4 Table B ID----Value 1-----x 2-----y 4-----z 4-----l As you can see, record with ID = 3 does not exist in table B, so i want a query that will give me record 3 from table A. the way i am currently doing this is by saying AND NOT EXISTS (SELECT ID FROM TableB) but since the tables are huge, the performance on this is terrible. Also, when i tried using a Left Join where TableB.ID is null, it didnt work. Can anyone suggest an alternative?

    Read the article

  • jQuery i++ and i-- problems ... what on earth???

    - by michael
    Could someone please tell me what I am doing wrong? I'm not a newbie at programming but I feel like it tonight! Every time I increment the incrementing variable it throws a fit! When add one to it, it behaves fine, but if I try to add one more to it it wants to add 2 more. And then if I try to de-increment it wants to subtract from the original number that it was assigned to. I've tried: i++; i = i+1; i = i++; Nothing seems to work. It's got to be a stupid mistake. Press the buttons to increment and de-increment. http://michaelreynolds.net/iphone/ here's the code: var dayNum = 30; //---------------------------------------------------------------------- $.jQTouch({ icon: 'dailyqoteicon.png', statusBar: false, initializeTouch: 'a.touch' }); //---------------------------------------------------------------------- $(document).ready(function(){ //$(function(){}); $(function(){ $('a.touch').swipe( function(event, info){ //alert("jQTouch swipe event"); //alert(info.direction); }); }); $(function updateVerse(){ //alert("updateVerse called"); $.ajax({ type: "GET", dataType: 'JSON', data: 'day='+ dayNum, url: 'forward.php', success: function(data){ var obj = $.parseJSON(data); $("h2.quote").html(""); $("h3.reference").html(""); $("h2.quote").append(obj.quote); $("h3.reference").append(obj.reference, " ", obj.version); //$("span.version").append(obj.version); //----------------------------------- // JSON string {"id":"1","quote":"For to me, to live is Christ, and to die is gain","reference":"Philippians 1:21","version":"NKJV"} }, error: function(request, error){ alert("problem retrieving json data string"); } }); function addDayNum(){ dayNum = dayNum + 1; //dayNum = dayNum++; } function subDayNum(){ dayNum = dayNum - 1; //dayNum = dayNum--; } $("div#header a.next").tap( function(){ addDayNum(); //dayNum++;// doesn't work at all //dayNum = dayNum + 1;//doesn't work at all updateVerse(); //alert(dayNum); //alert("next clicked"); }); $("div#header a.prev").live('click', function(){ subDayNum(); //dayNum--;//doesn't work at all //dayNum = dayNum - 1;// doesn't work at all updateVerse(); //alert(dayNum); //alert("previous clicked"); }); }); });

    Read the article

  • Getting a seg fault, having trouble with classes and variables.

    - by celestialorb
    Ok, so I'm still learning the ropes of C++ here so I apologize if this is a simple mistake. I have this class: class RunFrame : public wxFrame { public: RunFrame(); void OnKey(wxKeyEvent& keyEvent); private: // Configuration variables. const wxString *title; const wxPoint *origin; const wxSize *size; const wxColour *background; const wxColour *foreground; const wxString *placeholder; // Control variables. wxTextCtrl *command; // Event table. DECLARE_EVENT_TABLE() }; ...then in the OnKey method I have this code: void RunFrame::OnKey(wxKeyEvent& keyEvent) { // Take the key and process it. if(WXK_RETURN == keyEvent.GetKeyCode()) { bool empty = command -> IsEmpty(); } // Propogate the event through. keyEvent.Skip(); } ...but my program keeps seg faulting when it reaches the line where I attempt to call the IsEmpty method from the command variable. My question is, "Why?" In the constructor of the RunFrame class I can seemingly call methods for the command variable in the same way I'm doing so in the OnKey method...and it compiles correctly, it just seg faults on me when it attempts to execute that line. Here is the code for the constructor if necessary: RunFrame::RunFrame() : wxFrame(NULL, wxID_ANY, wxT("DEFAULT"), wxDefaultPosition, wxDefaultSize, wxBORDER_NONE) { // Create the styling constants. title = new wxString(wxT("RUN")); origin = new wxPoint(0, 0); size = new wxSize(250, 25); background = new wxColour(33, 33, 33); foreground = new wxColour(255, 255, 255); placeholder = new wxString(wxT("command")); // Set the styling for the frame. this -> SetTitle(*title); this -> SetSize(*size); // Create the panel and attach the TextControl to it. wxPanel *panel = new wxPanel(this, wxID_ANY, *origin, *size, wxBORDER_NONE); // Create the text control and attach it to the panel. command = new wxTextCtrl(panel, wxID_ANY, *placeholder, *origin, *size); // Set the styling for the text control. command -> SetBackgroundColour(*background); command -> SetForegroundColour(*foreground); // Connect the key event to the text control. command -> Connect(wxEVT_CHAR, wxKeyEventHandler(RunFrame::OnKey)); // Set the focus to the command box. command -> SetFocus(); } Thanks in advance for any help you can give! Regards, celestialorb

    Read the article

  • How to convert string date to Timestamp in java?

    - by lakshmi
    Hi, I want to convert string Date into Timestamp in java. The following coding i have written.I have declare the date for date1 is: 7-11-11 12:13:14. SimpleDateFormat datetimeFormatter1 = new SimpleDateFormat( "yyyy-MM-dd hh:mm:ss"); Date lFromDate1 = datetimeFormatter1.parse(date1); System.out.println("gpsdate :" + lFromDate1); Timestamp fromTS1 = new Timestamp(lFromDate1.getTime()); I want to convert 7-11-11 12:13:14 this string date into timestamp. Now i got the output is 0007-11-11 00:13:14.000000 +05:30:00 but i want ( 7-11-11 12:13:14) this format Timestamp date. Can anyone please help me. Thank you.

    Read the article

< Previous Page | 14 15 16 17 18 19 20 21 22 23 24 25  | Next Page >