Search Results

Search found 4770 results on 191 pages for 'john russell'.

Page 22/191 | < Previous Page | 18 19 20 21 22 23 24 25 26 27 28 29  | Next Page >

  • C# ASP.Net The type or namespace name 'Secure' does not exist in the namespace 'source_extranet'

    - by Louis Russell
    Afternoon all, I really need your help as this is a Nightmare! I was earlier having a problem with referencing a 3rd Party Dll (Here) but have overcome this problem and am now having a problem referencing my own classes! Everything seems fine at build with no errors at all but when I go to run the application it comes up with the following Compilation Error: Compiler Error Message: CS0234: The type or namespace name 'Secure' does not exist in the namespace 'source_extranet' (are you missing an assembly reference?) The line that the Error points to this line in the class: source_extranet.Secure.BackendCustomData newdata = new source_extranet.Secure.BackendCustomData(); This line of code points to a class in the same folder as the calling code class. I have scoured Google looking for an answer and haven't found anything that points me to an answer to my problem. Any help would be AMAZING!

    Read the article

  • Can someone help me refactor this C# linq business logic for efficiency?

    - by Russell
    I feel like this is not a very efficient way of using linq. I was hoping somebody on here would have a suggestion for a refactor. I realize this code is not very pretty, as I was in a complete rush. public class Workflow { public void AssignForms() { using (var cntx = new ProjectBusiness.Providers.ProjectDataContext()) { var emplist = (from e in cntx.vw_EmployeeTaskLists where e.OwnerEmployeeID == null select e).ToList(); foreach (var emp in emplist) { // if employee has a form assigned: break; if (emp.GRADE > 15 || (emp.Pay_Plan.ToLower().Contains("al") || emp.Pay_Plan.ToLower().Contains("ex"))) { //Assign278(); } else if ((emp.Series.Contains("0905") || emp.Series.Contains("0511") || emp.Series.Contains("0110") || emp.Series.Contains("1801")) || (emp.GRADE >= 12 && emp.GRADE <= 15)) { var emptask = new ProjectBusiness.Providers.EmployeeTask(); emptask.TimespanID = cntx.Timespans.SingleOrDefault(t => t.BeginDate.Year == DateTime.Today.Year & t.EndDate.Year == DateTime.Today.Year).TimespanID; var FormID = (from f in cntx.Forms where f.FormName.Contains("450") select f.FormID).FirstOrDefault(); var TaskStatusID = (from s in cntx.TaskStatus where s.StatusDescription.ToLower() == "not started" select s.TaskStatusID).FirstOrDefault(); Assign450((int)emp.EmployeeID, FormID, TaskStatusID, emptask); cntx.EmployeeTasks.InsertOnSubmit(emptask); } else { //Assign185(); } } cntx.SubmitChanges(); } } private void Assign450(int EmployeeID, int FormID, int TaskStatusID, ProjectBusiness.Providers.EmployeeTask emptask) { emptask.FormID = FormID; emptask.OwnerEmployeeID = EmployeeID; emptask.AssignedToEmployeeID = EmployeeID; emptask.TaskStatusID = TaskStatusID; emptask.DueDate = DateTime.Today; } }

    Read the article

  • Setting a Silverlight textbox control's width relatively

    - by John K.
    Hello, I tried searching on stackoverflow for an answer to my question but couldn't seem to find anything relevant. Since I'm relatively new to Silverlight, I'm not even sure if this is possible, but I am trying to figure out if it is possible to set a Silverlight textbox control's width value proportionally to it's immediate parent container? It would be nice to avoid hard coding a width value. Say you want to place a textbox control inside a horizontally aligned StackPanel control and have it's width always dynamically adjusted to be 80% of the total width of the StackPanel. Is this possible to do declaratively in your xaml markup, or will I need to resort to some codebehind attached to some event handler to accomplish this? fyi, I am currently using Visual Web Developer Express 2008 to write my silverlight code. thanks in advance, John

    Read the article

  • fetching a url using $.getJSON and parsing it correctly

    - by sofia
    This is probably really stupid but i can't find the problem with my code. It fetches a url that returns json and the function is then supposed to return a string: function getit() { var ws_url = 'example.com/test.js'; var user = false; $.getJSON(ws_url, function(data) { alert('user '+data.user);//shows john user = data.user || false; } ); return user;//should return john but returns false } test.js will have something like this: {"id":"12","username":"ses","user":"john","error":""} or like this: {"error":"123"} I also tried if(data.user){}else{} but it didn't work either.. So what am i missing? Thanks :)

    Read the article

  • Two separate fields need to be grouped in one group

    - by Sigita
    I have two fields: Mother's employer and Father's employer, and I need to group on the employer. Could somebody help me combine the two above fields into one group? Both fields are in one table. FOr example a child named John Lewis is a record in a table and he has a father and a mother and Mother's employer is IBM and Father's employer is ISF. And so forth. I need to come up with a list By employer where it would show: Employer: IBM John Lewis Emplyer: ISF John Lewis Employer: .... Thank you, Sigita

    Read the article

  • How can you increase timeout in Linq2Entities?

    - by Russell Steen
    I'm doing a basic select against a view. Unfortunately the result can be slow and I'm getting timeout errors intermittently. How can I increase the timeout? Using .NET 3.5, Sql Server 2000, Linq2Entities I'm using the very basic query List<MyData> result = db.MyData.Where(x.Attribute == search).ToList(); Fixing the query so that it's faster on the DB side is not an option here. Exact Error: "Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding." Update: I'd prefer to just change it for this one query.

    Read the article

  • Casting an object using 'as' returns null: myObject = newObject as MyObject; // null

    - by John Russell
    I am trying to create a custom object in AS3 to pass information to and from a server, which in this case will be Red5. In the below screenshots you will see that I am able to send a request for an object from as3, and receive it successfully from the java server. However, when I try to cast the received object to my defined objectType using 'as', it takes the value of null. It is my understanding that that when using "as" your checking to see if your variable is a member of the specified data type. If the variable is not, then null will be returned. This screenshot illustrates that I am have successfully received my object 'o' from red5 and I am just about to cast it to the (supposedly) identical datatype testObject of LobbyData: However, when testObject = o as LobbyData; runs, it returns null. :( Below you will see my specifications both on the java server and the as3 client. I am confident that both objects are identical in every way, but for some reason flash does not think so. I have been pulling my hair out for a long time, does anyone have any thoughts? AS3 Object: import flash.utils.IDataInput; import flash.utils.IDataOutput; import flash.utils.IExternalizable; import flash.net.registerClassAlias; [Bindable] [RemoteClass(alias = "myLobbyData.LobbyData")] public class LobbyData implements IExternalizable { private var sent:int; // java sentinel private var u:String; // red5 username private var sen:int; // another sentinel? private var ui:int; // fb uid private var fn:String; // fb name private var pic:String; // fb pic private var inb:Boolean; // is in the table? private var t:int; // table number private var s:int; // seat number public function setSent(sent:int):void { this.sent = sent; } public function getSent():int { return sent; } public function setU(u:String):void { this.u = u; } public function getU():String { return u; } public function setSen(sen:int):void { this.sen = sen; } public function getSen():int { return sen; } public function setUi(ui:int):void { this.ui = ui; } public function getUi():int { return ui; } public function setFn(fn:String):void { this.fn = fn; } public function getFn():String { return fn; } public function setPic(pic:String):void { this.pic = pic; } public function getPic():String { return pic; } public function setInb(inb:Boolean):void { this.inb = inb; } public function getInb():Boolean { return inb; } public function setT(t:int):void { this.t = t; } public function getT():int { return t; } public function setS(s:int):void { this.s = s; } public function getS():int { return s; } public function readExternal(input:IDataInput):void { sent = input.readInt(); u = input.readUTF(); sen = input.readInt(); ui = input.readInt(); fn = input.readUTF(); pic = input.readUTF(); inb = input.readBoolean(); t = input.readInt(); s = input.readInt(); } public function writeExternal(output:IDataOutput):void { output.writeInt(sent); output.writeUTF(u); output.writeInt(sen); output.writeInt(ui); output.writeUTF(fn); output.writeUTF(pic); output.writeBoolean(inb); output.writeInt(t); output.writeInt(s); } } Java Object: package myLobbyData; import org.red5.io.amf3.IDataInput; import org.red5.io.amf3.IDataOutput; import org.red5.io.amf3.IExternalizable; public class LobbyData implements IExternalizable { private static final long serialVersionUID = 115280920; private int sent; // java sentinel private String u; // red5 username private int sen; // another sentinel? private int ui; // fb uid private String fn; // fb name private String pic; // fb pic private Boolean inb; // is in the table? private int t; // table number private int s; // seat number public void setSent(int sent) { this.sent = sent; } public int getSent() { return sent; } public void setU(String u) { this.u = u; } public String getU() { return u; } public void setSen(int sen) { this.sen = sen; } public int getSen() { return sen; } public void setUi(int ui) { this.ui = ui; } public int getUi() { return ui; } public void setFn(String fn) { this.fn = fn; } public String getFn() { return fn; } public void setPic(String pic) { this.pic = pic; } public String getPic() { return pic; } public void setInb(Boolean inb) { this.inb = inb; } public Boolean getInb() { return inb; } public void setT(int t) { this.t = t; } public int getT() { return t; } public void setS(int s) { this.s = s; } public int getS() { return s; } @Override public void readExternal(IDataInput input) { sent = input.readInt(); u = input.readUTF(); sen = input.readInt(); ui = input.readInt(); fn = input.readUTF(); pic = input.readUTF(); inb = input.readBoolean(); t = input.readInt(); s = input.readInt(); } @Override public void writeExternal(IDataOutput output) { output.writeInt(sent); output.writeUTF(u); output.writeInt(sen); output.writeInt(ui); output.writeUTF(fn); output.writeUTF(pic); output.writeBoolean(inb); output.writeInt(t); output.writeInt(s); } } AS3 Client: public function refreshRoom(event:Event) { var resp:Responder=new Responder(handleResp,null); ncLobby.call("getLobbyData", resp, null); } public function handleResp(o:Object):void { var testObject:LobbyData=new LobbyData; testObject = o as LobbyData; trace(testObject); } Java Client public LobbyData getLobbyData(String param) { LobbyData lobbyData1 = new LobbyData(); lobbyData1.setSent(5); lobbyData1.setU("lawlcats"); lobbyData1.setSen(5); lobbyData1.setUi(5); lobbyData1.setFn("lulz"); lobbyData1.setPic("lulzagain"); lobbyData1.setInb(true); lobbyData1.setT(5); lobbyData1.setS(5); return lobbyData1; }

    Read the article

  • mySQL - Separate Lastname,Firstname and CompanyName entries from a single column

    - by Decalmo
    I've got a column in a database which contains company names, and customer names all in one field... what I'd like to do is keep the CompanyName column completely intact, but wherever there is a comma in the CompanyName I'd like to take that information and populate it into a FirstName and LastName field. So that basically... Before: CompanyName: Big Company Inc Smith, John Sue, Maggie After: CompanyName: Big Company Inc Smith, John Sue, Maggie LastName: Smith Sue FirstName: John Maggie This one is pretty dang tricky for me... Any help is greatly appreciated!

    Read the article

  • java.lang.NoSuchMethodError: main Exception in thread "main" .

    - by russell
    I Cant understand why this messege come--------- java.lang.NoSuchMethodError: main Exception in thread "main" . I know it expecting main() method but as i m building an applet which does not contain main method rather contain init() method.So what will i do??My code is s follow --- import java.applet.*; import java.awt.*; public class Ballbewegung1 extends Applet implements Runnable { // Initialisierung der Variablen int x_pos = 10; // x - Position des Balles int y_pos = 100; // y - Position des Balles int radius = 20; // Radius des Balles public void init() { setBackground (Color.blue); } public void start () { // Schaffen eines neuen Threads, in dem das Spiel l?uft Thread th = new Thread (this); // Starten des Threads th.start (); } public void stop() { } public void destroy() { } public void run () { // Erniedrigen der ThreadPriority um zeichnen zu erleichtern Thread.currentThread().setPriority(Thread.MIN_PRIORITY); // Solange true ist l?uft der Thread weiter while (true) { // Ver?ndern der x- Koordinate x_pos ++; // Neuzeichnen des Applets repaint(); try { // Stoppen des Threads f?r in Klammern angegebene Millisekunden Thread.sleep (20); } catch (InterruptedException ex) { // do nothing } // Zur?cksetzen der ThreadPriority auf Maximalwert Thread.currentThread().setPriority(Thread.MAX_PRIORITY); } } public void paint (Graphics g) { g.setColor (Color.red); g.fillOval (x_pos - radius, y_pos - radius, 2 * radius, 2 * radius); } } And I dont know how to use code tag.so plz someone ans.

    Read the article

  • Search and Replace within a Text file using mySQL queries

    - by user241000
    How can I create PHP to search the testing.txt file for each name in the database table and replace the name with the database table id? So that the text file looks like this: 3 | 1 | 4 | 5 2 | 3 | 6 4 | 5 | 2 and so forth an so on... I have a mysql table called "nameslist" that looks like this: --------------------- id | name --------------------- 1 | bob 2 | john 3 | tom and so forth an so on... I have a text file called "testing.txt" that looks like this: tom | bob | mary | paul john | tom | rachel mary | paul | john and so forth an so on...

    Read the article

  • jQuery/Javascript framework efficiency

    - by Russell
    My latest project is using a javascript framework (jQuery), along with some plugins (validation, jquery-ui, datepicker, facebox, ...) to help make a modern web application. I am now finding pages loading slower than I am used to. After some js profiling (thanks VS2010!), it seems a lot of the time is taken procesing inside the framework. Now I understand the more complex the ui tools, the more processing needs to be done. The project is not yet at a large stage and I think would be average functions. At this stage I can see it is not going to scale well. I noticed things like the 'each' command in jQuery takes quite a lot of processing time. Have others experienced some extra latency using JS frameworks? How do I minimise their effect on page performance? Are there best practices on implementation using JS frameworks? Thanks

    Read the article

  • How do I use Perl's WWW::Facebook::API to publish to a user's newsfeed?

    - by Russell C.
    We use Facebook Connect on our site in conjunction with the WWW::Facebook::API CPAN module to publish to our users newsfeed when requested by the user. So far we've been able to successfully update the user's status using the following code: use WWW::Facebook::API; my $facebook = WWW::Facebook::API->new( desktop => 0, api_key => $fb_api_key, secret => $fb_secret, session_key => $query->cookie($fb_api_key.'_session_key'), session_expires => $query->cookie($fb_api_key.'_expires'), session_uid => $query->cookie($fb_api_key.'_user') ); my $response = $facebook->stream->publish( message => qq|Test status message|, ); However, when we try to update the code above so we can publish newsfeed stories that include attachments and action links as specified in the Facebook API documentation for Stream.Publish, we have tried about 100 different ways without any success. According to the CPAN documentation all we should have to do is update our code to something like the following and pass the attachments & action links appropriately which doesn't seem to work: my $response = $facebook->stream->publish( message => qq|Test status message|, attachment => $json, action_links => [@links], ); For example, we are passing the above arguments as follows: $json = qq|{ 'name': 'i\'m bursting with joy', 'href': ' http://bit.ly/187gO1', 'caption': '{*actor*} rated the lolcat 5 stars', 'description': 'a funny looking cat', 'properties': { 'category': { 'text': 'humor', 'href': 'http://bit.ly/KYbaN'}, 'ratings': '5 stars' }, 'media': [{ 'type': 'image', 'src': 'http://icanhascheezburger.files.wordpress.com/2009/03/funny-pictures-your-cat-is-bursting-with-joy1.jpg', 'href': 'http://bit.ly/187gO1'}] }|; @links = ["{'text':'Link 1', 'href':'http://www.link1.com'}","{'text':'Link 2', 'href':'http://www.link2.com'}"]; The above, nor any of the other representations we tried seem to work. I'm hoping some other perl developer out there has this working and can explain how to create the attachment and action_links variables appropriately in Perl for posting to the Facebook news feed through WWW::Facebook::API. Thanks in advance for your help!

    Read the article

  • Adding childs to list of parents with jquery /mvc2

    - by John Landheer
    Hi, I have a table of products on my page, each product has zero or more colors, the colors are shown as a list beneath the product. After the colors I have a button to add a color. The button will do an ajax call with the parent product id to a controller which will return a JSON object with color information. My problem is where to store the product id in the DOM, should I put it in a hidden field and use jquery in the click event of the "add color" to get to it? What is the best way to do this? TIA, John EDIT: The page is initially rendered on the server so I don't want to use jquery to add the id's to the page.

    Read the article

  • Installing bitarray in Python 2.6 on Windows

    - by John Fouhy
    I would like to install bitarray in Windows running python 2.6. I have mingw32 installed, and I have C:\Python26\Lib\distutils\distutils.cfg set to: [build] compiler = mingw32 If I type, in a cmd.exe window: C:\Documents and Settings\john\My Documents\bitarray-0.3.5>python setup.py install I get: [normal python messages skipped] C:\MinGW\bin\gcc.exe -mno-cygwin -mdll -O -Wall -IC:\Python26\include -IC:\Python26\PC -c bitarray/_bitarray.c -o build\temp.win32-2.6\Release\bitarray\_bitarray.o bitarray/_bitarray.c:2197: error: initializer element is not constant bitarray/_bitarray.c:2197: error: (near initialization for `BitarrayIter_Type.tp_getattro') bitarray/_bitarray.c:2206: error: initializer element is not constant bitarray/_bitarray.c:2206: error: (near initialization for `BitarrayIter_Type.tp_iter') bitarray/_bitarray.c:2232: error: initializer element is not constant bitarray/_bitarray.c:2232: error: (near initialization for `Bitarraytype.tp_getattro') bitarray/_bitarray.c:2253: error: initializer element is not constant bitarray/_bitarray.c:2253: error: (near initialization for `Bitarraytype.tp_alloc') bitarray/_bitarray.c:2255: error: initializer element is not constant bitarray/_bitarray.c:2255: error: (near initialization for `Bitarraytype.tp_free') error: command 'gcc' failed with exit status 1 Can anyone help?

    Read the article

  • Can I align the text in a C# balloon tip ?

    - by John
    Hello, I wrote a little C# program that displays text in a balloon tip from time to time. When the text is in English, there's no problem : Everything is aligned to the left and is readable, but sometimes I have some Hebrew text and a left alignment of a RTL language gets all screwy. I was wondering if there's a way to right-align the Hebrew text ? Google pointed me to articles that can help me change the balloon color and font, but none of them have an alignment argument. Is it even possible ? Any help will be appropriated. John

    Read the article

  • Linq SqlMethods.Like fails

    - by Russell Steen
    I'm following the tips here, trying to leverage the statement that the sql doesn't get created until the enumerator is tripped. However I get the following error on the code below. I'm using Linq2Entities, not linq2sql. Is there a way to do this in Linq2entities? Method 'Boolean Like(System.String, System.String)' cannot be used on the client; it is only for translation to SQL. query = db.MyTables.Where(x => astringvar.Contains(x.Field1)); if (!String.IsNullOrEmpty(typeFilter)) { if (typeFilter.Contains('*')) { typeFilter = typeFilter.Replace('*', '%'); query = query.Where(x=> SqlMethods.Like(x.Type, typeFilter)); } else { query = query.Where(x => x.Type == typeFilter); } }

    Read the article

  • Run Windows XP on a usb drive virtually on Windows XP?

    - by Russell
    I am sick of not being able to run and install certain applications on my work computer due to admin restrictions (eg: Adobe AIR) . I have heard of smaller versions of Windows running on a usb thumb drive and have looked into it but can't find anything on running windows virtually from a usb drive. I would like to be able to login to this particular computer, insert my usb drive and then open up another version of windows installed on the thumb drive while still being able to use the windows I logged in on (literally be able to alt+tab between the main desktop and the virtual desktop from the usb drive). Is this even possible? For further clarification: The version of windows has to be Windows XP and there is no other option available for what I want to do. Looking forward to a response.

    Read the article

  • Algorithm To Select Most Popular Places from Database

    - by Russell C.
    We have a website that contains a database of places. For each place our users are able to take one of the follow actions which we record: VIEW - View it's profile RATING - Rate it on a scale of 1-5 stars REVIEW - Review it COMPLETED - Mark that they've been there WISH LIST - Mark that they want to go there FAVORITE - Mark that it's one of their favorites In our database table of places each place contains a count of the number of times each action above was taken as well as the average rating given by users. views ratings avg_rating completed wishlist favorite What we want to be able to do is generate lists of the top places using the above information. Ideally, we would want to be able to generate this list using a relatively simple SQL query without needing to do any legwork to calculate additional fields or stack rank places against one another. That being said, since we only have about 50,000 places we could run a nightly cron job to calculate some fields such as rankings on different categories if it would make a meaningful difference in the overall results of our top places. I'd appreciate if you could make some suggestions on how we should think about bubbling the best places to the top, which criteria we should weight more heavily, and given that information - suggest what the MySQL query would need to look like in order to select the top 10 places. One thing to note is that at this time we are less concerned with the recency of a place being popular - meaning that looking at the aggregate information is fine and that more recent data doesn't need to be weighted more heavily. Thanks in advance for your help & advice!

    Read the article

  • Sending binary data from ASP to .net component

    - by john
    The ASP application allows uploading of image files (jpg, gif, tif). These files are sent to a .net component registered in the GAC of the server. In the component file is encoded using System.Text.Unicode to byte[] array. This encoding is done with some data loss. The byte array has values 253 and 255 in consequetive elements. What could be the problem ? I'm sending the binary data as a string. Please help me... Thanks in advance, John

    Read the article

  • beginner's ruby question: how to use erb to output file after binding

    - by john
    Hi, I got the following example: require 'erb' names = [] names.push( { 'first' => "Jack", 'last' => "Herrington" } ) names.push( { 'first' => "LoriLi", 'last' => "Herrington" } ) names.push( { 'first' => "Megan", 'last' => "Herrington" } ) myname = "John Smith" File.open( ARGV[0] ) { |fh| erb = ERB.new( fh.read ) print erb.result( binding ) accompanied by text.txt <% name = "Jack" %> Hello <%= name %> <% names.each { |name| %> Hello <%= name[ 'first' ] %> <%= name[ 'last' ] %> <% } %> hi, my name is <%= myname %> } it prints nicely to screen. what is the simplest way to output another file: "text2.txt"? thank you!!!

    Read the article

  • Where do interfaces belong in a multitier application

    - by Russell Steen
    So say you have a three tier application with the tiers UI, Services, and Repository for a simple application, let's say saving addresses. If AddressService has an interface IAddressService, where does that interface belong? I know that "in the address service" may seem like an obvious answer, but if it's in the address service it would seem to defeat the point of having the interface such that any service library could be swapped in as long as it implemented IAddressService. (specifically this is in a .net problem space, but it's probably more general so it's tagged architecture)

    Read the article

  • JQuery animate div "like" a Zoom

    - by Russell Parrott
    I can never get these to work - sorry - but I I am trying to animate on a mouse over then "re-animate" on a mouse out. I can never get $('#xyz').hover(function(){'something',function(){'somethingelse'}); to work. Hope you guys can help. What I am trying to do is animate + and - 20px (top and left) on some absolutely positioned divs and then add 40px to the width height returning to the original position/width/height on mouse out. I haven't even got to the css widths/heights yet .... Here is my code (which is wrong - well it must be as it doesn't work :-) ) $('.box').hover(function(){ $(this).animate({'top':'-20','left':'-20'},function(){ $(this).animate({'top':'20','left':'20' }); }); Help really appreciated. Thanks in advance

    Read the article

  • Customising event delegates in the jQuery validation plug-in

    - by Russell
    I am currently setting up the jQuery validation plug-in for use in our project. By default, there are some events automatically set up for handling. I.e. focus in/out, key up events on all inputs fire validation. I want it to only fire when the submit button is clicked. This functionality seems to be in-built into the plug-in, which is making it difficult to do this (without modifying the plug-in code, Not What I Want To Do). I have found the eventDelegate function calls in the plugin code prototype method: $(this.currentForm) .validateDelegate(":text, :password, :file, select, textarea", "focusin focusout keyup", delegate) .validateDelegate(":radio, :checkbox, select, option", "click", delegate); When I remove these lines from the plug-in I get my result, however I would much rather do something Outside the plug-in to achieve this. Can anybody please help me? If you need any more details, please let me know. I have searched google with little success. Thanks

    Read the article

< Previous Page | 18 19 20 21 22 23 24 25 26 27 28 29  | Next Page >