Badges

Types

Formats

Show Only

SOAP and PHP
https://mreschke.com/278/soap-and-php
<p>Learn how to connect to an an PHP/SOAP or ASP.NET/SOAP web service with PHP and how to create a PHP SOAP web service (server)</p>
|
post #278 by mreschke Nov 16th 2011 (6798 views)
Regular Expressions
https://mreschke.com/238/regular-expressions
http:msdn.microsoft.com/en-us/library/ms972966.aspx http:www.4guysfromrolla.com/articles/022603-1.aspx I have a large html file, I want to remove anything between the tags, even if the contents is on multiple lines. There is a regex option called RegexOptions.MultiLine which I though would work, but its actually the RegexOptions.Singleline below what makes it span multiple lines, see http:msdn.microsoft.com/en-us/library/ms972966.aspx for details on RegexOptions.Singleline. Dim reg As New Regex...
|
post #238 by mreschke Mar 8th 2011 (3087 views)
Recursive File Search or List in .NET
https://mreschke.com/153/recursive-file-search-or-list-in-net
I am sure you all have your functions for a recursive directory/file listing, or file searching by wildcard function for .net, but here is another one, works great. I use it to get a list of all *.aspx pages in a project like this. Dim baseDirectory As System.IO.DirectoryInfo = New System.IO.DirectoryInfo(“c:\projects\SSO\”) Dim x As New DSF.SSO.Other.FileSearch(baseDirectory, "*.aspx") Dim pageName As String = "" x.Search(, "*.aspx") lblMessage.Text = "" For Each f As System.IO.FileInfo In...
|
post #153 by mreschke Sep 10th 2009 (2893 views)
Concat Strings and Variables in ASPX Page
https://mreschke.com/150/concat-strings-and-variables-in-aspx-page
Lets say you have a datagrid with a hyperlink on each row that points to somewhere.com?id=xxxx, where the ID is part of the dataset. Usually what I would do is add in the hyperlink NavigationURL in the .vb codebehind in the grid_ItemDataBound function like 'Tracker Copies Grid Protected Sub grdCopies_ItemDataBound(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.DataGridItemEventArgs) Handles grdCopies.ItemDataBound Select Case e.Item.ItemType Case ListItemType.AlternatingItem, ListI...
|
post #150 by mreschke Jul 7th 2009 (7115 views)
DevExpress ASPxGridView
https://mreschke.com/145/devexpress-aspxgridview
DevExpress ASPxGridView In this example, the GridView has 4 columns, a column with a checkbox, and 3 columns of data. I want to loop through all grid columns and get which checkboxes are selected. (Note the same column with the checkbox also has a hiddel ASPxLabel called lblID that holds the OPC_ID of the database row to be deleted). And in the GetCurrentPageRowValues("Confirm"), confirm is the header name (not caption, but name=) of a column in the grid (column display headers are 'Confirm,Op...
|
post #145 by mreschke May 18th 2009 (9643 views)
Loop Datagrid and get Forms
https://mreschke.com/112/loop-datagrid-and-get-forms
Say I have a datagrid with just one column, several rows, with a checkbox in each row. I want to build a save function that saves each checked item to the database. I also want to be able to click anywhere on the datagrid row and have that check/uncheck the box for me, which I will achieve with javascript and html events. First, the datagrid is named grdUserGroups I have one datagrid column, wich a TemplateColumn in it. That template column's item has 2 forms, a check box named chkUserGroup with...
|
post #112 by mreschke Oct 1st 2008 (3004 views)
ASP.NET DataSet or DataTable to Excel
https://mreschke.com/84/aspnet-dataset-or-datatable-to-excel
Export a dataset or datatable to excel .csv then stream (prompt for download) the file. This code uses a datatable, if you have a dataset, just convert to datatable like so Dim dt as new DataTable dt = ds.Tables(0) Dim sw As New System.IO.StreamWriter(Server.MapPath("~/data.csv"), false); Dim ds As New DataSet Dim dt As New DataTable ds = Session("trkDsResults") dt = ds.Tables(0) Dim iCol As Int16 = dt.Columns.Count Dim i As Int16 For i = 0 To iCol - 1 sw.Write(dt.Columns(i)) If i < iCol - 1 The...
|
post #84 by mreschke Jul 16th 2008 (3472 views)
ASP.NET Datagrid to HTML
https://mreschke.com/85/aspnet-datagrid-to-html
Export an ASP.NET datagrid to HTML Then you could stream the file to their browser with
|
post #85 by mreschke Jul 16th 2008 (3391 views)
ASP.NET Alternate POST Method
https://mreschke.com/78/aspnet-alternate-post-method
When you click a button in ASP.NET, it POSTS to itself and calls the btnXXX_click function. One way to make it go to another .aspx page on click is to call Server.Transfer or Response.Redirect from within that btnXXX_click function, but no form variables will be passed along. I want to goto a btnXXX_Click function when the button is clicked, then do some stuff, then redirect to another page along with the form variables Doing a Server.Transfer or Response.Redirect will NOT transfer the form var...
|
post #78 by mreschke Jun 11th 2008 (3249 views)
ASP.NET Datagrid Date Formatting with NULLS
https://mreschke.com/77/aspnet-datagrid-date-formatting-with-nulls
When displaying a formated date string in an ASP.NET datagrid, you get an error if the dataset field is NULL If closeDate is not NULL, this works fine, otherwise it errors. This works if closeDate is not NULL, otherwise it displays MM/dd/yyyy (in that format, not date format, does not display date) This works if closeDate is null (displays nothing), or contains a date. This is what you want to use.
|
post #77 by mreschke Jun 11th 2008 (3742 views)
.NET Directory to DataGrid
https://mreschke.com/74/net-directory-to-datagrid
Add a directory of files to a datagrid For greater control, you can , then bind the dataset to the datagrid.
|
post #74 by mreschke Jun 5th 2008 (3293 views)
.NET Directory to Dataset
https://mreschke.com/71/net-directory-to-dataset
This article adds the files in a directory (with wildcards) into a datatable, then to a dataset. With slight modifications to this function you can return the file list as a dataset, datatable or string array. See Private Sub TabArchivesEvents() Dim archivePath As String Dim dirInfo As DirectoryInfo archivePath = System.Configuration.ConfigurationSettings.AppSettings("ExecutiveAnalysisArchivesFolder") & Me.DLR_ID & "\" If Directory.Exists(archivePath) Then dirInfo = New DirectoryInfo(archivePath...
|
post #71 by mreschke May 22nd 2008 (5438 views)
.NET Listbox
https://mreschke.com/62/net-listbox
For i = 0 To lstRecipients.Items.Count - 1 If lstRecipients.Items(i).Selected Then tmp = lstRecipients.Items(i).Value 'This is the selected users ID from tblLogin (not email) lstRecipients.Items(i).Selected = False End If Next
|
post #62 by mreschke May 16th 2008 (2280 views)
Impersonation in ASP.NET
https://mreschke.com/29/impersonation-in-aspnet
<p>Impersonation is the concept whereby an application executes under the context of the identity of the client that is accessing the application. This is achieved by using the access token provided by IIS.</p> <p>Can impersonate entire website by editing the web.config or impersonate chunks of code in the codebehind.<br /> <strong>Very usefull when accessing folders on a remote server that has no domain</strong></p>
|
post #29 by mreschke Feb 29th 2008 (3228 views)
Showing 1 to 14 of 14 results