Hi,
Is there any way to completely ignore link break and tab characters etc. in RegEx?
For instance, the line break and tab characters could be found anywhere and in any order in the content string.
... [CustomToken \t \r\n Type="" \t \r\n Property="" \n /] ... [CT ...
The is the RegularExpression that I am currently using:
(\[CustomToken).*?(\/\])
.NET API
Regex.Matches(string input, string pattern)
Thanks for your suggestion.
Hi
I need to be able to take EPS and PDF's and convert them to JPEG/PNG on the fly to display on a website - using .net code.
I used ADC PDF from WebSupergoo for this like 3 years ago, and it worked fine - but some other and better options could easily have surfaced since then.
I am trying to write a file to a network drive from my asp.Net application and i get this error - Logon failure: unknown user name or bad password. Any ideas?
I am able to write to a local drive line C:/temp
But when I try to save the file to a network drive such as \Server\Folder, I get the error mentioned above.
Any ideas people?
I am using xVal in a ASP.NET MVC project. One of the forms has two buttons and i want to disable the client side validation when one of the buttons is clicked. Is there a way to conditionally disable client side validation in xVal?
i have this querystring that shall open up my page.
http://www.a1-one.com/[email protected]&stuid=123456
Now when this page loads, on page_load, I want to pick up email and stuid in two different variables. So I can use them to insert into my database (sql server)
how can this be done in vb.net
I have seen plugins for VS 2005 and also for C# environment in VS2008 but not able to find for VB.NET environment in VS 2008.I want it to sort for each file, is there any addin for this?
Does anyone know how to copy a VB.Net list of structures to an Excel range? It's not hard to do with an array, but I can't get a list of structures to work.
Example:
Structure MyStruct
Dim MyField1 as String
Dim MyField2 as Integer
End Structure
Dim MyList As New List(Of MyStruct)
...populate list of structures...
Dim rng as Excel.Range = MySheet.Range("A1","B9")
rng.??? = MyList '*** This is where I get stuck. ***
DataContractJsonSerializer this is nice class added in the .net framework which can be used to serialize/desirealize object into JSON.
Now following is the example i am trying
[Serializable] class User { public string name; public string userId; }
Now following is the output generated
Output : Notice structure where only "name" is expected instead of k__BackingField
Now this is the problem after digging so much i am not sure from where < and _BackingField is coming ?
{
"<name>k__BackingField":"test user",
"<userId>k__BackingField":100001}
I am using VS2010, CrystalReport13 & MVC3. My problem is unable to add an external assembly in Crystal Report using "Database Expert" Option.
I have a class named WeeklyReportModel in an external assembly. In my web project, data retrieving from DB as IEnumerable collection of WeeklyReportModel.
I tried ProjectData - .NetObjects in Crystal Report for adding the WeeklyReportModel. But this external assembly is not showing under ".NetObjects".
Then I tried other option as
Create New Connection - ADO.Net – Make New Connection and pointed this External Assembly. It has been added under Ado.Net node, but while expanding displays as "...no items found..."
Totally frustrated. Please help.
External Assembly Class:
namespace SMS.Domain
{
public class WeeklyReportModel
{
public int StoreId { get; set; }
public string StoreName{ get; set; }
public decimal Saturday { get; set; }
public decimal Sunday { get; set; }
public decimal Monday { get; set; }
public decimal Tuesday { get; set; }
public decimal Wednesday { get; set; }
public decimal Thurday { get; set; }
public decimal Friday { get; set; }
public decimal Average { get; set; }
public string DateRange { get; set; }
}
}
In Controller-action[Data retrieving as Collection Of WeeklyReportModel]
namespace SMS.UI.Controllers
{
public class ReportController : Controller
{
public ActionResult StoreWeeklyReport(string id)
{
DateTime weekStart, weekClose;
string[] dateArray = id.Split('_');
weekStart = Convert.ToDateTime(dateArray[0].ToString());
weekClose = Convert.ToDateTime(dateArray[1].ToString());
SMS.Infrastructure.Report.AuditReport weeklyReport
= new SMS.Infrastructure.Report.AuditReport();
IEnumerable<SMS.Domain.WeeklyReportModel> weeklyRpt =
weeklyReport.ReportByStore().WeeklyReport(weekStart, weekClose);
Session["WeeklyData"] = weeklyRpt;
Response.Redirect("~/Reports/Weekly/StoreWeekly.aspx");
return View();
}
}
}
Thanks in advance.
I have windows forms application with multiple forms and controls in them. I want if user has selected some text in any control of any form of my application and click on cut/copy/paste button on toolbar operation get performed accordingly.
i m using C#.net's sendkeys.send("^c") on click of copy button but it doesn't work...
OR any 1 can tell if is there any way to get selected text (despite of knowing, which form/control of my application).
Thanks in advance...
I am using jquery.load() to load a page on click of a button.
The page that will be loaded contains a captcha.
When that page is getting loaded due to the captcha it is making the page to reload again and it is not showing anything.
If i am removing the captcha from the load page it is working fine.
I am using ASP.NET.
Can anyone help me?
any one know how to use vertical tabs with jquery.
In my web site i want to use partial views i implemented it with jquery horizontal tabs but i want it with vertical tab as my links are in right side. so any one know the solution plz tel me. I am using asp.net mvc application
thanks in advance..
Hello,
We have an .NET client app working against SQL Server 2005 (clustered), do I need to do something special in the client app to make it cluster aware?
Thanks.
Session[Constant] vs Session["String Literal"] Performance
I'm retrieving user-specific data like ViewData["CartItems"] = Session["CartItems"]; with a string literal for keys on every request. Should I be using constants for this?
If yes, how should I go about implementing frequently used string literals and will it significantly affect performance on a high-traffic site?
Related question does not address ASP.NET MVC or Session.
I noticed that the DLLs in the bin folder for asp.net websites do not seem to be getting saved. When I goto a new computer and get latest I am missing the DLLs.
What is the correct way to fix this ? Should I create a seperate folder to contains all DLLs ? And then can I somehow tell my bin references to goto that folder to get the DLLs?
We're using the MS Chart for .net, but encountering the "image not found" problem for which there doesn't seem to be a solution.
Are there any alternatives for generating simple charts?
Hi
I am using asp.net 2.0
I set a hidden text box from javascript and on postback, i want to check the value stored on the text box in page init event. Here is what i tried
string t = Request.Form["currentMode"].ToString();
but i get an error saying " Object reference not set to an instance of an object."
Any idea?asp.
I would like to get the Employee-ID for the currently logged in user. Is that easily available in some .Net class or do I need to do some sort of LDAP query?
Any tips welcome
When i request a page using browser / AJAX request i see lot of spaces and newlines which i think must be adding some overhead for retrieving the response as they too belong to characters means bytes and size. right ?
Is there some way it can be removed while sending from the server ? how ?
(I am using IIS and asp.net for development)
Hi All,
I have a combo box column in vb.net datagridview . i want to perform some validation like to put some values in another text column of Grid on selectionindexchanged event of a combo box in datagridview. but unable to do so. Any Help appreciated. Thanks in Advance.
I've been looking around for a simple solution to this, trying my best to lean towards something like NHibernate, but so far everything I've found seems to be trying to solve a slightly different problem. Here's what I'm looking at in my current project:
We have an IBM iSeries database as a primary repository for a third party software suite used for our core business (a financial institution). Part of what my team does is write applications that report on or key off of a lot of this data in some way. In the past, we've been manually creating ADO .NET connections (we're using .NET 3.5 and Visual Studio 2008, by the way) and manually writing queries, etc.
Moving forward, I'd like to simplify the process of getting data from there for the development team. Rather than creating connections and queries and all that each time, I'd much rather a developer be able to simply do something like this:
var something = (from t in TableName select t);
And, ideally, they'd just get some IQueryable or IEnumerable of generated entities. This would be done inside a new domain core that I'm building where these entities would live and the applications would interface with it through a request/response service layer.
A few things to note are:
The entities that correspond to the database tables should be generated once and we'd prefer to manually keep them updated over time. That is, if columns/tables are added to the database then we shouldn't have to do anything. (If some are deleted, of course, it will break, but that's fine.) But if we need to use a new column, we should be able to just add it to the necessary class(es) without having to re-gen the whole thing.
The whole thing should be SELECT-only. We're not doing a full DAL here because we don't want to be able to break anything in the database (even accidentally).
We don't need any kind of mapping between our domain objects and the generated entity types. The domain barely covers a fraction of the data that's in there, most of it we'll never need, and we would rather just create re-usable maps manually over time. I already have a logical separation for the DAL where my "repository" classes return domain objects, I'm just looking for a better alternative to manual ADO to be used inside the repository classes.
Any suggestions? It seems like what I'm doing is just enough outside the normal demand for DAL/ORM tools/tutorials online that I haven't been able to find anything. Or maybe I'm just overlooking something obvious?
I am trying to get the html for this link http://slashdot.org/firehose.pl?op=rss&content_type=rss&orderby=createtime&fhfilter="home:vamsivanka"
Dim myRequest As WebRequest
Dim myResponse As WebResponse
Try
myRequest = System.Net.WebRequest.Create(url)
myRequest.Timeout = 10000
myResponse = myRequest.GetResponse()
Dim rssStream As Stream = myResponse.GetResponseStream()
Dim rssDoc As New XmlDocument()
rssDoc.Load(rssStream)
Catch ex As Exception
End Try
But the rssDoc.Load is giving me an error '--' is an unexpected token. The expected token is ''. Line 81, position 5.
Please Let me know your suggestions.