Sunday, 15 January 2012

c# - SQL Injection filter method for ASP.NET -


I have fields that are free form text and allow about any combination of numbers / symbols. What is the best way to validate SQL injection? Can I run a simple place of tick marks? Is there a way I can plug to use?

Just use parameterized questions! Check out this article here:


delphi - How to return a record in a DataSnap method -


I want to be able to declare the data snap method with the following signature

  Type TLoginInfo = Record Username: string; Password: string; Lastlog: Datetime; End; GetLoginInfo function (CONSTORE UserID: integer): TLoginInfo;  

When I try to call it, it says that TloginInfo is not well known

If you are using the "new" datenet then look here:


encryption - iPhone SDK - CCATS required if using Keychain Access? -


Am I planning to use the key in an iPhone app to store some username / password information Do I still need to file for a CCATS?

If you use the already available crypto libraries in the iPhone SDK, If not, you will not need a CCATS The technically exporting of any encryption will be an encryption code for Apple and therefore you should be free and clear.

For more information, see this topic.


asp.net - Intermittent PolicyException: Execution permission cannot be acquired -


Text after "

We intermittently see the following exceptions shortly after an application pool recycle in ASP.NET applications: < / P>

  System.Configuration.ConfigurationErrorsException: The file or assembly could not load Microsoft.Web.Mvc, version = 1.0.0.0, culture = neutral, publicKeyToken = null 'or one of your dependencies. Failed to allow execution. (Exception with HRESULT: 0x80131418) --- & gt; System.IO.FileLoadException: Failed to allow file or assembly to execute 'Microsoft.Web.Mvc, version = 1.0.0.0, culture = neutral, public keypoint = faucet' or one of its dependencies could not be loaded. (Exception from HRESULT: 0x80131418) Name File: 'Microsoft.Web.Mvc, Version = 1.0.0.0, Culture = Neutral, PublicKeyToken = Nulled' --- & gt; System.Security.Policy.PolicyException: Permission can not be obtained for execution. On System.Security.SecurityManager.ResolvePolicy (proof proof, permission asset reqdPset, PermissionSet optPset, PermissionSet denyPset, PermissionSet & False, Boolean Check Exclusion Promotion) (Proof proof, permission Asset reqdPset, PermissionSet on System.Security.SecurityManager.ResolvePolicy OptPset, PermissionSet denyPset, PermissionSet & amp; on System Disclaimed, Int 32 and Security Special Flags, Boolean Check Execution Promotion). Reflections.exabilities._update (assembly name filename, string codebase, proof assembly security, assembly placeholder, stack crawl mark and stack marker, boolean throwoverflow knotfound, boolean for introspection). AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark & ​​amp; stackMark, Boolean forIntrospection) System.Reflection.Assembly.InternalLoad (string assemblyString, evidence assemblySecurity, on StackCrawlMark & ​​amp; stackMark on System.Reflection.Assembly.Load, Boolean forIntrospection) (S System.Web.Configuration.CompilationSection.LoadAssemblyHelper on Tring assemblyString) (string AssemblyName, Boolean starDirective)  

specific DLL fails to load varies for this event from the event, but always refers to a main assembly .

We are running on ASP.NET 3.5 on Windows Server 2008. It seems that this does not happen in batches affecting some sites on the same app pool. We have a large number of sites running the same code.

Once a site fails to load the DLL, it throws a yellow screen off death until the next app pool recycle. We have not been able to reproduce this behavior and sites work fine for days or weeks before the failure (and recycle multiple app pools).

Has anyone else seen such behavior?

Update:

We tried to reproduce a script written failure to hit the set of a few hundred sites and times Couple of minutes and even a few others were unable to complete the loading of the server's CPU straight for a few days.

We Aspi.ankti.al.al.al with copies to try to play the (locking of DLLs, the file is changed to allow). Does and succeeds in reproducing similar behaviors but not the only exception.

Does anyone have any idea how to adjust the security policy? is to throw the System.Security policy Ethics: Permission can not be obtained for execution. While loading a specific DLL? In

load

"process IIS application pool settings under the model" user right profile.

to


crystal reports : substring error -


I have developed a workaround because crystal reports do not have a substring function with the following formula:

P> What am I trying to do , Searches for the duration (".") In a string, and changes it with a comma. Then get the status of the comma in the Stram and print all the letters after the comma. Only 1 period in the string will be in the entire string.

Now when I try to do this, I get some weird letters that look like wings. any idea?

Thanks in advance

I do not know the whole issue that you have to complete Trying, but only for this question, the steps to replace the period with a comma seem unnecessary. If you know that there is only one string in it and you only want the characters of that period, then you should be able to do something (this is @first_formula):

  right ({_ V_hardware.groupname}, len ({_v_hardware.groupname}) - instr ({_ v_hardware.groupname}, "."))  

If for some reason you show comma So if I want to separate the formula. If you need a full screen coma space then just do this:

Change
  ({_ v_hardware.groupname}, ".", ",")  

And if you need a comma then it may be easy to do something like this:

  "," + {@first_formula} " > 

Hope it helps.


javascript - How to trigger Mouse-Over on iPhone? -


It may actually look like a dumb question, but I am writing an application and where I have come across my mouse over, mouse-click and mouse-hover need different events bound for them. Now all this works as expected on Internet Explorer, Firefox, and Safari

However, actions on my iPhone will not be triggered. Now my question is that when I hold my finger and trigger an event If I do, can mouse-over be compulsorily removed?

An example where this does not work is correct on this website when you hover a comment, it should display 1 or flag icon.

I am using jquery.

I think you need to reconsider your design for the iPhone (and that's what Any mobile for mobile) iPhone web interface should not be dependent on mouse over and zoom, because they make the interface very complicated.

I strongly recommend that you design a new interface that is optimized for viewing mobile, which is not required, show more options by clicking on the small and small arrows.


datagrid - wpf DataGridTextColumn refactoring -


I use a Dokgreed'm in a WPF app which a) column for each day of stay (only weeks A sample of XAML is below in its data index, which is only different.

Can I refactor in something more dry?

Cheers, Berryl

Sample XAML (Seven columns from either):

  & lt; DG: DataGridTextColumn header = "{Binding Source = {StaticResource detective} path = DataContext [0] .EventDate, Converter = {StaticResource DateConv}}" CellStyle = '{StaticResource DataEntryCellStyle} "width =" 60 "CanUserResize =" false " Binding = "{binding allocation [0] .mount, converter = {StaticResource amtConv}}" /> & Lt; DG: DataGridTextColumn header = "{Source = {StaticResource detective} path = DataContext [1] .EventDate, Converter = {StaticResource dateConv} Binding}" CellStyle = '{StaticResource DataEntryCellStyle} "width =" 60 "CanUserResize =" false " binding = "{binding allocation [1]. The amount, Converter = {static resource Amticonw}}" />  

edit == add'l info @ JALFP ===

The compiler complains that the goal type is not a framework element when creating

   & Lt; Setter Property = "CanUserSort" value = "wrong" /> & Lt; Setter property = "width" value = "60" /> & Lt; Setter property = "cell style" value = "{static resource data intergridcloth style}" /> & Lt; / Style & gt;  

I do not see anything that looks like a column style What property would I set this style to DataGridTextColumn in XAML?

Maybe you can create your own class that inherits from DataGridTextColumn and Add a new dependency Property Day Index (up to 0 to 6). And in this category, you can initialize are Aksamel ...

But I'm not sure that it will actually be better and more suitable solutions ...