Search Results

Search found 1062 results on 43 pages for 'shah al'.

Page 12/43 | < Previous Page | 8 9 10 11 12 13 14 15 16 17 18 19  | Next Page >

  • Override a resource from standard assembly in ASP.NET

    - by wRAR
    I want to override a string from a System.ComponentModel.DataAnnotations for an ASP.NET project. Do I need to make a satellite assembly, messing with custom build tasks, al.exe etc.? Even if yes, I couldn't find how to convert .resx to .resources to feed it to al.exe. And if no, where to put the .resx. and how to name it?

    Read the article

  • How to develop JSP/Servlets Web App using MVC pattern?

    - by A.S al-shammari
    I'm developing a JSP/Servlets web app (no frameworks). I want to use MVC pattern. I designed my project like this : Controller :a servlet that reads a request, extracts the values,communicates with model objects and gives information to a JSP page. View : JSP Pages. Model : Java Classes / Java Beans .. etc . The problem : Index.jsp is the starting point (default page) in my web site. So, the Index.jsp becomes the controller to parse the request! .For example , the following request : index.jsp?section=article&id=10 parsed in index.jsp as following : <div class="midcol"> <!-- Which section? --> <%String fileName = request.getParameter("section"); if (fileName == null) { fileName = "WEB-INF/jspf/frontpage.jsp"; } else { fileName = "WEB-INF/jspf/" + fileName + ".jsp"; } %> <jsp:include page='<%= fileName%>' /> </div> Here, I can't force the servlet to be a controller .. because the index.jsp is the controller here since it's the starting point! Is there any solution to forward the request from index.jsp to the servlet and then go back to index.jsp ? Or any solution that achieves the MVC goal - the servlet should be the controller - ? I'm thinking of making a FrontPageController servlet as default page instead of index.jsp ! but I don't know if it's a perfect idea ?!

    Read the article

  • How to use NUnit GUI with a C#/ASP.NET website?

    - by Amber Shah
    I have a C#/ASP.NET website that has some code (*.cs) files in the App_Code directory. I would like to test them using NUnit. I have written a test file with the proper [TestFixture] and [Test] annotations and have put it here: App_Code/Test/TestClassName.cs. I load up the NUnit GUI to run it but it wants me to select a .exe or .dll file. There is none in the bin folder of my project. My project does successfully run and is built and everything, but still no exe or dll file. How can I get the NUnit Gui to just run the test in that class?

    Read the article

  • Messaging pattern question

    - by Al Bundy
    Process A is calculating values for objects a1, a2, a3 etc. and is sending results to the middleware queue (RabbitMQ). Consumers read the queue and process these results further. Periodically process A has to send a snapshot of these values, so consumers could do some other calculations. Values for these objects might change independently. The queue might look like this a1, a1, a2, a1, a2, a2, a3... Consumers process each item in the queue. The snapshot has to contain all objects and consumers will process this message for all objects in one go. So the requirement is to have a queue like this: a1, a1, a3, a2, a2, [snapshot, a1, a2, a3], a3, a1 ... The problem is that these items are of different types: one type for objects like a1, a2 and other for a snapshot. This means that they should be processed in a diferent queues, but in that case there is a race condition: consumers might process objects before processing a snapshot. Is there any pattern to solve this (quite common) problem? We are using RabbitMQ for message queueing.

    Read the article

  • variables in assembler

    - by stupid_idiot
    hi, i know this is kinda retarded but I just can't figure it out. I'm debugging this: xor eax,eax mov ah,[var1] mov al,[var2] call addition stop: jmp stop var1: db 5 var2: db 6 addition: add ah,al ret the numbers that I find on addresses var1 and var2 are 0x0E and 0x07. I know it's not segmented, but that ain't reason for it to do such escapades, because the addition call works just fine. Could you please explain to me where is my mistake?

    Read the article

  • calculate period between two monthcalender in C#

    - by Hashim Al-Arab
    I have two monthcalender in C# win application , and I need to calculate the period between then. I need how many day between two or three month or also years I need how many month between tow different years. When I use : monthcalender.selectstart.month; this command just calculate the different between months in same year, but when move to next year the value be negative. and same for days, I use : monthcalender.selectstart.dayofyear;

    Read the article

  • multi-part identifier could not be bound error

    - by vishal Shah
    Here is my query: IF OBJECT_ID('NPWAS1513.dbo.usp_MSPEX_QLK_Billing_Fact_Load') IS NOT NULL DROP PROCEDURE dbo.usp_MSPEX_QLK_Billing_Fact_Load; GO CREATE PROCEDURE usp_MSPEX_QLK_Billing_Fact_Load @create_timestamp datetime, @update_timestamp datetime, @create_user varchar(50), @update_user varchar(50), @dbProdServ varchar(50) AS print 'dbProdServ is:'+ @dbProdServ; print 'current_user is:' +@current_user; DECLARE @sSQL AS VARCHAR(MAX); SET @sSQL = '' SET @sSQL = 'set identity_insert ' + @dbProdServ + '.mspex_qlk_billing_fact ON' EXEC(@sSQL); SET @sSQL = 'INSERT INTO ' + @dbProdServ +'.mspex_qlk_billing_fact (project_id, billing_year, billing_month, billing_month_desc, billing_date_id, projected_bill_amount, billed_year_to_date_amount, billed_inception_to_date_amount, remaining_bill_amount, actual_billed_amount, current_billing_percent, previous_billing_percent, billing_pct_diff, billing_type, final_bill_ind, last_in_progress_date, current_record_ind, load_time_stamp, total_contract_period, contract_period_current_year, partial_bill, create_timestamp, create_user, update_timestamp, update_user) SELECT project_dim.project_id, billing_final_data.billingyear, billing_final_data.billingmonth, billing_final_data.billingmonthdesc, Time_Dim.Time_ID, billing_final_data.projected_bill_amount, billing_final_data.billed_year_todate_amount, billing_final_data.billed_inception_todate_amount, billing_final_data.remaining_bill_amount, billing_final_data.actual_billed_amount, billing_final_data.current_billing_percent, billing_final_data.previous_billing_percent, billing_final_data.billing_pct_diff, billing_final_data.billing_type, billing_final_data.final_bill_ind, billing_final_data.last_in_progress_date, billing_final_data.current_record_ind, billing_final_data.load_time_stamp, billing_final_data.[Total Contract Period], billing_final_data.[Contract Period Current Year], billing_final_data.[Partial Bill],'''+ CAST(@create_timestamp as varchar(max)) + ''',''' + @create_user + ''','''+ CAST(@update_timestamp as varchar(50)) +''','''+ @update_user + ''' FROM '+ @dbProdServ +'.mspex_qlk_project_dim project_dim,'+ @dbProdServ +'.mspex_rpt_billing_final_data billing_final_data,'+ @dbProdServ + '.MSPEX_QLK_Time_Dim Time_Dim WHERE project_dim.myproject_project_uid = billing_final_data.projectuid AND'''+ convert(datetime, cast(billing_final_data.[BillingMonth] as nvarchar(2)) + '''/01/''' + cast(billing_final_data.[billingyear] as nvarchar(4)), 101) +''' + = Time_Dim.Time_Date'; BEGIN TRANSACTION EXEC(@sSQL) COMMIT TRANSACTION I get the error msg: Msg 4104, Level 16, State 1, Procedure usp_MSPEX_QLK_Billing_Fact_Load, Line 23 The multi-part identifier "mspex_rpt_billing_final_data.BillingMonth" could not be bound. Msg 4104, Level 16, State 1, Procedure usp_MSPEX_QLK_Billing_Fact_Load, Line 23 The multi-part identifier "billing_final_data.billingyear" could not be bound. Msg 207, Level 16, State 1, Procedure usp_MSPEX_QLK_Billing_Fact_Load, Line 83 Invalid column name 'BillingMonth'. Msg 207, Level 16, State 1, Procedure usp_MSPEX_QLK_Billing_Fact_Load, Line 84 Invalid column name 'billingyear'. I checked the column names, etc. and things are fine. In fact, I directly dragged the table name and column name to ensure that it is correct. Please help ASAP. Calling me at cell at 630-338-9427 would be great. But an URGENT response is absolutely necessary. Thanks guys.

    Read the article

  • How ca I return a value from a function

    - by Shadi Al Mahallawy
    I used a function to calculate information about certain instructions I intialized in a map,like this void get_objectcode(char*&token1,const int &y) { map<string,int> operations; operations["ADD"] = 18; operations["AND"] = 40; operations["COMP"] = 28; operations["DIV"] = 24; operations["J"] = 0X3c; operations["JEQ"] =30; operations["JGT"] =34; operations["JLT"] =38; operations["JSUB"] =48; operations["LDA"] =00; operations["LDCH"] =50; operations["LDL"] =55; operations["LDX"] =04; operations["MUL"] =20; operations["OR"] =44; operations["RD"] =0xd8; operations["RSUB"] =0x4c; operations["STA"] =0x0c; operations["STCH"] =54; operations["STL"] =14; operations["STSW"] =0xe8; operations["STX"] =10; operations["SUB"] =0x1c; operations["TD"] =0xe0; operations["TIX"] =0x2c; operations["WD"] =0xdc; if ((operations.find("ADD")->first==token1)||(operations.find("AND")->first==token1)||(operations.find("COMP")->first==token1) ||(operations.find("DIV")->first==token1)||(operations.find("J")->first==token1)||(operations.find("JEQ")->first==token1) ||(operations.find("JGT")->first==token1)||(operations.find("JLT")->first==token1)||(operations.find("JSUB")->first==token1) ||(operations.find("LDA")->first==token1)||(operations.find("LDCH")->first==token1)||(operations.find("LDL")->first==token1) ||(operations.find("LDX")->first==token1)||(operations.find("MUL")->first==token1)||(operations.find("OR")->first==token1) ||(operations.find("RD")->first==token1)||(operations.find("RSUB")->first==token1)||(operations.find("STA")->first==token1)||(operations.find("STCH")->first==token1)||(operations.find("STCH")->first==token1)||(operations.find("STL")->first==token1) ||(operations.find("STSW")->first==token1)||(operations.find("STX")->first==token1)||(operations.find("SUB")->first==token1) ||(operations.find("TD")->first==token1)||(operations.find("TIX")->first==token1)||(operations.find("WD")->first==token1)) { int y=operations.find(token1)->second; //cout<<hex<<y<<endl; } return ; } which if I cout y in the function gives me an answer just fine which is what i need but there is a problem tring to return the value from the function so that I could use it outside the function , it gives a whole different answer, what is the problem

    Read the article

  • iTextSharp Conversion from Table to pdfPTable

    - by Al.
    I have an old ASP.NET project originally done in ASP.NET 1.1 w/ iText.NET and converted to .NET 2.0 and iTextSharp 4.1.6.0. It uses lots of Table (I'm assuming pdfptable wasn't an option at the time it was created.) I am trying to convert this code to use the latest iTextSharp 5.0.0 dll and now see Table and cell have been removed. I started converting it anyway and soon found there is no equivalent to a lot of the functionality that Table offered. Mainly AddCell no longer allows a col,row setting. There are literally thousands of these calls in this code and the posibility of changing it to generate linearly row by row looks hopeless at the moment. The current code looks something like: Dim myTable As New Table(NumReq + 2, IngDS.Tables(0).Rows.Count + 3) myTable.SetWidths(Width) myTable.Width = 100 myTable.Padding = 2 myCell = New Cell(New Phrase("Some Text", New iTextSharp.text.Font(iTextSharp.text.Font.HELVETICA, 8, iTextSharp.text.Font.NORMAL, iTextSharp.text.Color.BLACK))) myCell.SetHorizontalAlignment(Element.ALIGN_RIGHT) myCell.GrayFill = 0.75 myTable.AddCell(myCell, Row, Col) myCell = New Cell(New Phrase("Other Text",New iTextSharp.text.Font(iTextSharp.text.Font.HELVETICA, 8, iTextSharp.text.Font.NORMAL, iTextSharp.text.Color.BLACK))) myCell.GrayFill = 0.75 myTable.AddCell(myCell, Row, Col+1) Before I embark down that road I was hoping someone would be able to point me in a direction that I'm just totally missing that will make this conversion much more simple. Any ideas? Thanks.

    Read the article

  • Sort by values from hash table - Ruby

    - by Adnan
    Hello, I have the following hash of countries; COUNTRIES = { 'Albania' => 'AL', 'Austria' => 'AT', 'Belgium' => 'BE', 'Bulgaria' => 'BG', ..... } Now when I output the hash the values are not ordered alphabetically AL, AT, BE, BG ....but rather in a nonsense order (at least for me) How can I output the hash having the values ordered alphabetically?

    Read the article

  • Can i upload my apk to SD Card instead of internal storage?

    - by Ahmed Al Khashab
    My APK is big, 70 MB. I don't have any problems when I install it in external storage, but when I upload it to phone before installing, the APK goes to internal storage and my testing phone doesn't have enough space in internal storage and a lot of android phones don't have enough internal space for 70 MB... Can I upload my APK straight to the SD Card instead of internal storage first? upload mean "upload from my eclipse while runnig , or download from market, apk will go to internal storage but i want apk go to external and start install from external"

    Read the article

  • SQL Server 2008: CASE vs IF-ELSE-IF vs GOTO

    - by Saharsh Shah
    I have some rules in my application and I have written the business logic of that rules in my procedure. At the time of creation of procedure I came to know that CASE statement won't work in my scenario. So I have tried two ways to perform same operations (using IF-ELSE-IF or GOTO) shown as below. Method 1 Using IF-ELSE-IF conditions: DECLARE @V_RuleId SMALLINT; IF (@V_RuleId = 1) BEGIN /*My business logic*/ END ELSE IF (@V_RuleId = 2) BEGIN /*My business logic*/ END ELSE IF (@V_RuleId = 3) BEGIN /*My business logic*/ END /* ... ... ... ...*/ ELSE IF (@V_RuleId = 19) BEGIN /*My business logic*/ END ELSE IF (@V_RuleId = 20) BEGIN /*My business logic*/ END Method 2 Using GOTO statement: DECLARE @V_RuleId SMALLINT, @V_Temp VARCHAR(100); SET @V_Temp = 'GOTO RULE' + CONVERT(VARCHAR, @V_RuleId); EXECUTE sp_executesql @V_Temp; RULE1: BEGIN /*My business logic*/ END RULE2: BEGIN /*My business logic*/ END RULE3: BEGIN /*My business logic*/ END /* ... ... ... ...*/ RULE19: BEGIN /*My business logic*/ END RULE20: BEGIN /*My business logic*/ END Today I have 20 rules. It can be increase to any number in future. If I can able to use CASE statement then I have not any problem with performance, but I can't do that so I am worried about the performance of my procedure. Also one thing to be noticed that this procedure will execute very frequently by application. My questions are: Is there any way to use CASE statement in my procedure? If not, which method is best to use in my procedure to improve the performance of my code? Thanks in advance...

    Read the article

  • How to find a programmer for my project?

    - by Al
    I'm building a web application to generate monthly subscription fees, but I've quickly realised I'm going to need some help with the project to finish it this century. I don't have any money upfront for a freelancer and every website I've found takes bids for project work. The tasks that need doing are flexible too because I can do whatever the other coder doesn't want to. I'm also happy to guide the developer and offer tips for performance/security/etc etc. My question is; how do I go about finding someone to work with on a profit-share basis? I'm sure there are a billion people like me with the "next killer app" but I genuinely believe in it. Can anyone offer some advice? Thanks in advance! EDIT: I guess the trick is to find someone passionate enough about the subject as I am. Where would I find someone? Are there websites that broker profit-share deals on programming work?

    Read the article

  • Find IP address in iphone

    - by Ruchir Shah
    Hi, I want to find IP address in an application. I am able to find it. But, problem is, it works fins in iphone os 2.0 or so. But, in iphone os 3.0 it is giving me a warning: warning: no '+currentHost' method found warning: (Messages without a matching method signature) I am using this code, and it works fine with os version 2.0. -(NSString*)getAddress { char iphone_ip[255]; strcpy(iphone_ip,"127.0.0.1"); // if everything fails NSHost* myhost = [NSHost currentHost]; if (myhost) { NSString *ad = [myhost address]; if (ad) strcpy(iphone_ip,[ad cStringUsingEncoding: NSISOLatin1StringEncoding]); } return [NSString stringWithFormat:@"%s",iphone_ip]; } How to find IP address in iphone os 3.0 or greater os version? Thanks in advance.

    Read the article

  • how to specify set of files to be copied in lib while creating war

    - by Jigar Shah
    This is my build target <target name="build-war" depends="build-java"> <war destfile="${dist.dir}/${std.war.file}" webxml="${resources.dir}/WEB-INF/web.xml"> <fileset dir="${jsp.dir}" /> <lib dir="${lib.dir}"/> <classes dir="${build.classes.dir}" /> </war> </target> Here for <lib> can i specify some how a fileset / pattern set ? Basically i want to copy different jar from different places. (Not in one directlry) And That fileset or patternset i want to be defined in another build file which actually imports this build file. <lib refid="${patternset.id}"/>

    Read the article

  • Help making userscript work in chrome

    - by Vishal Shah
    I've written a userscript for Gmail Pimp.my.Gmail & i'd like it to be compatible with Google Chrome too. Now i have tried a couple of things, to the best of my Javascript knowledge (which is very weak) & have been successful up-to a certain extent, though im not sure if it's the right way. Here's what i tried, to make it work in Chrome: The very first thing i found is that contentWindow.document doesn't work in chrome, so i tried contentDocument, which works. BUT i noticed one thing, checking the console messages in Firefox and Chrome, i saw that the script gets executed multiple times in Firefox whereas in Chrome it just executes once! So i had to abandon the window.addEventListener('load', init, false); line and replace it with window.setTimeout(init, 5000); and i'm not sure if this is a good idea. The other thing i tried is keeping the window.addEventListener('load', init, false); line and using window.setTimeout(init, 1000); inside init() in case the canvasframe is not found. So please do lemme know what would be the best way to make this script cross-browser compatible. Oh and im all ears for making this script better/efficient code wise (which is sure there is)

    Read the article

  • Replace into equivalent for postgresql and then autoincrementing an int

    - by Mohamed Ikal Al-Jabir
    Okay no seriously, if a postgresql guru can help out I'm just getting started. Basically what I want is a simple table like such: CREATE TABLE schema.searches ( search_id serial NOT NULL, search_query character varying(255), search_count integer DEFAULT 1, CONSTRAINT pkey_search_id PRIMARY KEY (search_id) ) WITH ( OIDS=FALSE ); I need something like REPLACE INTO for mysql. I don't know if I have to write my own procedure or something? Basically: check if the query already exists if so, just add 1 to the count it not, add it to the db I can do this in my php code but I'd rather all that be done in postgres C engine Thanks for helping

    Read the article

  • iphone sqlite3_column_text issue

    - by Ruchir Shah
    I have a column in sqlite3 table. Column has values like 1 ½” 1 ¾” 2 ½” etc. Column has VARCHAR datatype. I am using this code. pref_HoseDiameter = [NSString stringWithUTF8String:(char *)sqlite3_column_text(compiledStatement, 2)]; Now, when I am fetching these values from database, I am getting pref_HoseDiameter string values like this: 1 1/2" 1 3/4" 2 1/2" How to fetch those values as they are in database or how to convert them that look like database values. Help would be appreciated. Thanks in advance.

    Read the article

  • Defining an implementation independent version of the global object in JavaScript

    - by Aadit M Shah
    I'm trying to define the global object in JavaScript in a single line as follows: var global = this.global || this; The above statement is in the global scope. Hence in browsers the this pointer is an alias for the window object. Assuming that it's the first line of JavaScript to be executed in the context of the current web page, the value of global will always be the same as that of the this pointer or the window object. In CommonJS implementations, such as RingoJS and node.js the this pointer points to the current ModuleScope. However, we can access the global object through the property global defined on the ModuleScope. Hence we can access it via the this.global property. Hence this code snippet works in all browsers and in at least RingoJS and node.js, but I have not tested other CommomJS implementations. Thus I would like to know if this code will not yield correct results when run on any other CommonJS implementation, and if so how I may fix it. Eventually, I intend to use it in a lambda expression for my implementation independent JavaScript framework as follows (idea from jQuery): (function (global) { // javascript framework })(this.global || this);

    Read the article

  • Silverlight Player Blank When Changing ism file

    - by Al Katawazi
    I am trying to get silverlight smooth streaming going on a site I am bilding and it works fine with the big buck bunny sample code which looks like this: <object data="data:application/x-silverlight-2," type="application/x-silverlight-2" width="100%" height="100%" id="Object2"> <param name="source" value="SmoothStreamingBlackGlass.xap"/> <param name="onerror" value="onSilverlightError" /> <param name="initparams"value='autoplay=False,muted=False,stretchmode=0,displaytimecode=False, playlist=<playList><playListItems><playListItem title="Big%20Buck%20Bunny" description="" mediaSource="Big%20Buck%20Bunny.ism/Manifest" adaptiveStreaming="True" thumbSource="Big%20Buck%20Bunny_Thumb.jpg" frameRate="24.0000384000614" ></playListItem></playListItems></playList>' /> <a href="http://go2.microsoft.com/fwlink/?LinkID=124807" style="text-decoration: none;"><img src="http://go2.microsoft.com/fwlink/?LinkId=108181" alt="Get Microsoft Silverlight" style="border-style: none" /></a> </object> <iframe style="visibility:hidden;height:0;width:0;border:0px"></iframe> but if i change the code like this i only get a blank area when the page is rendered instead of the movie clip. <object data="data:application/x-silverlight-2," type="application/x-silverlight-2" width="100%" height="100%" id="Object2"> <param name="source" value="SmoothStreamingBlackGlass.xap"/> <param name="onerror" value="onSilverlightError" /> <param name="initparams"value='autoplay=False,muted=False,stretchmode=0,displaytimecode=False, playlist=<playList><playListItems><playListItem title="Robotica_1080" description="" mediaSource="Robotica_1080.ism/Manifest" adaptiveStreaming="True" thumbSource="Robotica_1080_Thumb.jpg" frameRate="24.0000384000614" ></playListItem></playListItems></playList>' /> <a href="http://go2.microsoft.com/fwlink/?LinkID=124807" style="text-decoration: none;"><img src="http://go2.microsoft.com/fwlink/?LinkId=108181" alt="Get Microsoft Silverlight" style="border-style: none" /></a> </object> <iframe style="visibility:hidden;height:0;width:0;border:0px"></iframe> Any ideas? I am using Encoder 3 to do the encoding set on microsoft smooth streaming for 720p with all the default settings.

    Read the article

  • addEventListener gone after appending innerHTML

    - by Vishal Shah
    Okay, so i have the following html added to a site using javascript/greasemonkey. (just sample) *a id='abc'*HEllo*/a* *a id='xyz'*Hello*/a* (excuse me, i've had to replace the '<' '' with * since hyperlinks for new users aren't allowed!) and i've also added a click event listener for the elements. All works fine up to this point, the click event gets fired when i click the element. But... i have another function in the script, which upon a certain condition, modifies that html, ie it appends it, so it looks like: *a id='abc'*HEllo*/a* *a id='xyz'*Hello*/a* *a id='123'*Hello*/a* but when this is done, it breaks the listeners i added for the first two elements... nothing happens when i click them. if i comment out the call to the function which does the appending, it all starts working again! help please...

    Read the article

< Previous Page | 8 9 10 11 12 13 14 15 16 17 18 19  | Next Page >