Posts

Featured post

haskell - Using filter on an item in a list? -

i trying filter item in list , print them line line. here's code:data car = car string [string] int [string] testdatabase :: [car] testdatabase = [car"casino royale" ["daniel craig"] 2006 ["garry", "dave", "zoe", "kevin", "emma"],car"blade runner" ["harrison ford", "rutger hauer"] 1982 ["dave", "zoe", "amy", "bill", "ian", "kevin", "emma", "sam", "megan"]] formatcarrow (car b c d) = show ++ " | " ++ concat [i ++ ", " | <- init b] ++ last b ++ " | " ++ show c ++ " | " ++ concat [j ++ ", " | j <- init d] ++ last d displayfilmsbyyear :: string -> io [()] displayfilmsbyyear chosenyear = mapm (putstrln.formatfilmrow) [putstrln(filter ((== chosenyear).y)) | (w x y z) <- testdatabase] -- code not working think why isnt working? if w…

e commerce - Best CSS Layout for typical ecommerce sites -

ok, going varied opinions on question here goes anyway: best css layout type typical ecommerce site. typical in standard grid based product pages, header footer etc. an infinite number of layouts job done, , impossible definitively 1 'best'. however, there few guidelines should help:make product good.if you're going sell something, need make apparent why product awesome. prominent images can greatly.don't make things more complicated need be. minimalistic! no one's going "well, site design complex , intricate, should give them money..."make easy on eyes , mind. consider usability: people should able find need , efficiently. longer people have spend on site before being able buy something, less successful site be. also, make sure you're using colors aren't stressful on eyes.when in doubt, @ other successful e-commerce sites. don't need spend countless hours thinking of new site layout when there plenty of tried , true designs out there. :d

c# - When does PreApplicationStartMethod actually get triggered to run? -

when using webactivator preapplicationstart method, triggers methods bound run? when iis7 has started app pool? when first request made webserver? else? if have answer, please provide reference got information?does of change in iis 7.5? webactivator preapplicationstart relies on asp.net preapplicationstartmethodattribute (see this link see how web activator works). preapplicationstartmethodattribute works when asp.net runtime starts up application , code runs in pipeline before app_start event gets fired. answer question, trigger happen when first request made web server (which in turn kicks in application start up). note trigger related asp.net app start , not app pool. app pool might running because of other application (can non asp.net app) when first request comes asp.net app, trigger happen (for particular app) because application gets started. if using auto-start feature iis re-start application on app pool recycle , preapplicationstart triggered.

windows mobile - Help me C# code backup/recover & Search contacts on WindowsMobile? -

hi studying programming on windows mobile. , build mini program "manage contacts" functions: add, edit, delete, search , sort group. don't know how complete function : search , backup/recovery contacts! can me?description search function: create textbox , listbox, when press word on textbox, name of contacts containing worddisplay on listbox! can me?this demo, convert , repair example of windows mobile 5.0 this form main, , picture main form here : http://3.bp.blogspot.com/-lmmkcf6-req/tcqwnk9kgdi/aaaaaaaaab4/-eis3mimhy0/s320/main.jpgusing system; using system.drawing; using system.collections; using system.windows.forms; using system.data; using microsoft.windowsmobile.pocketoutlook; using microsoft.windowsmobile.telephony; namespace managercontacts { /// <summary> /// summary description form1. /// </summary> public class contactselector : system.windows.forms.form { private system.windows.forms.listbox listbox1; priva…

tomcat6 - Exception when stopping container for a with Spring + Quartz + Tomcat web application -

when stopping tomcat, getting following exception:...appears have started thread named [org.springframework.scheduling.quartz.schedulerfactorybean#0_worker-10] has failed stop it. create memory leak.how can prevent it? have destroy-method set destroy on schedulerfactorybean bean. just say...we have exactely same error grails (wich spring -based) & quartz on tomcat server... thread can't stopped quartz pool we've never managed correct that

google app engine - String conversion within GAE webapp template -

i trying create string of key of referenceproperty within webapp template:assume following simple datastore model:def user(db.model): first_name = stringproperty() last_name = stringproperty() def email(db.model): user = referenceproperty(user) email = emailproperty() i pass list of email entities webapp template in list named member_list. within template, want create string of key of each email entity's 'user' property use in url, such as: {% member in member_list %} <a href="/member_handler/{{insert_string_of_member.user_key_here"}}>blah</a> i realize pass string of key template, prefer string conversion in template if possible; have tried various permutations of str() , _ str_ no avail. since know entity in question member instance, , presumably won't have parent entity, it's simpler (and produces nicer urls) use key name or id of member, rather full string key. can user.key().name() (user.key.name in django template) or user.…

c# - Binding attached property to IEnumerable -

i using new wpf viewer crystal reports in c#. using mvvm, bind source of data displayed instead of doing in loaded event. therefore, wanted implement attached property source - binding doesn't work, getter method not called. other posts binding attached properties didn't , not sure doing different. can help? here simplified code attached property:public static class crystalreportsattached { public static readonly dependencyproperty sourceproperty = dependencyproperty.registerattached( "source", typeof(ienumerable), typeof(crystalreportsattached), new uipropertymetadata(new observablelist<participant>() ienumerable, sourcechanged)); public static void setsource(dependencyobject target, ienumerable value) { target.setvalue(sourceproperty, value); } public static ienumerable getsource(dependencyobject target) { return (ienumerable)target.getvalue(sourceproperty); } p…