Hi Guys,
Just giving an update, i am so far able to combine the uploadify plugin with my ftp connection class (wrote it recently)to make the ftp plugin. I am not quite finish will test some more and upload the solution shortly.
Hi Guys,
Just giving an update, i am so far able to combine the uploadify plugin with my ftp connection class (wrote it recently)to make the ftp plugin. I am not quite finish will test some more and upload the solution shortly.
It not a semester project i like to challenge myself and in order not to reinvent the wheel before i being a project i would post it online. Thank you
When i complete it i will share it right here...totally rude of you to make such an outlandish statement .....foolish
I have a task and a half that i am sure i can do, just want to be pushed in the right direction:
i have a web page (asp.net c#), on it has a button that when clicked should launch the file dialog window, users must be able to select multiple files at once. Those files selected must then be placed in a structure (listview, array or something) An file that is over 10MB or is not an image file the user must see that file and be able to remove it.
once all the files have passed the requirement those files must now be stored to another location (another server) outside of the actual server that has the web application. The external location has a particular folder that the images must be saved to, if that folder does not exist it must be created and then the images be saved in a prescribed format eg( IMG + DateTimeStamp >> IMG_1202200512:45PM.jpg) to the folder. Any error during the upload to the external sever should prevent all remaining files from being saved to the external location and the user notified.
The client browser is IE9
I will be researching on how to do this but if someone has done this before feel free to post your solution.
Hi Guys,
I have a asp.net web form that takes in a local user email address, on page onload i want to query active directory using that email address, and a specific group in active directory. if the user is found in the group i show the remaining controls on the page or else i prevent the user from seeing the remainder of the controls.
Any idea how i can accomplish this?
Hi Guys,
I have a dropdownlist that is being populated with entries from an sql database, the dropdownlist has about 50 entries already. What i aim to do is allow the users to type within the dropdownlist and it generates from that list a smaller subset of items based on what was typed by the user.
I need this because to scroll through a dropdownlist has become a pain staking task for users.
If anyone has a simple solution i would welcome it thank you.
Hi Guys,
I know the asp.net file upload control only allows users to select one file at a time, however i am looking for another way using asp.net to allow the users to select multiple files?
Has anyone done this before?
I did some research and used FTP however i have an issue.
The files are transferred successfully if i run my application from my system. when the application is placed in IIS7 it transfers the files however the files arrive on the server empty.
i am attaching the code that actually does the upload from a local user system to the file server.
public bool upload(string remoteFile, string localFile)
{
bool statval = true;
try
{
/* Create an FTP Request
*/
FtpWebRequest ftpRequest = (FtpWebRequest)FtpWebRequest.Create(remoteFile);
ftpRequest.UseBinary = true;
/* Log in to the FTP Server with the User Name and Password Provided */
ftpRequest.Credentials = new NetworkCredential(_username, _password);
/* When in doubt, use these options */
ftpRequest.UseBinary = true;
//ftpRequest.Proxy = null;
//ftpRequest.UsePassive = true;
//ftpRequest.KeepAlive = true;
/* Specify the Type of FTP Request */
ftpRequest.Method = WebRequestMethods.Ftp.UploadFile;
/* Establish Return Communication with the FTP Server */
Stream ftpStream = ftpRequest.GetRequestStream();
/* Open a File Stream to Read the File for Upload */
FileStream localFileStream = new FileStream(localFile, FileMode.Open);
/* Buffer for the Downloaded Data */
byte[] byteBuffer = new byte[bufferSize];
int bytesSent = localFileStream.Read(byteBuffer, 0, bufferSize);
/* Upload the File by Sending the Buffered Data Until the Transfer is Complete */
try
{
while (bytesSent != 0)
{
ftpStream.Write(byteBuffer, 0, bytesSent);
bytesSent = localFileStream.Read(byteBuffer, 0, bufferSize);
}
}
catch (Exception ex)
{
// Console.WriteLine(ex.ToString());
statval = false;
}
/* Resource Cleanup */
localFileStream.Close();
ftpStream.Close();
ftpRequest = null;
}
catch (Exception ex)
{
//Console.WriteLine(ex.ToString());
statval = false;
}
return statval;
}
Hi guys,
I am attempting to build a asp.net page that will allow users to upload multiple photos, view them in a gallery and remove them if necessary.
Details
Photo Upload Part >> Users will be able to select multiple images of varying types (png, gif,jpg) from any location on there machine, mobile device or flash drive. Those images must be stored on an external server but renamed before transfer to this server. The new image paths will be housed in a sql database.
Image View >> To view those images on the external server the users must specify a code, once the code is correct the system will grab all the image paths and display the images in a gallery format where users can scroll through the images and double click to see an image larger if necessary
Image Removal>> The top left of every image will have a checkbox to allow the users the felexibility of selecting a image . There will be a removal button that will collect all the selected images and delete there entires from the database as well as delete the actual image from the external location.
I don't know if this can be done in asp.net however if you have any suggestions on how i can accomplish this it would be nice.
awaiting your feedback
Hi Guys,
I am attempting to write an application that copies any file from the user's local machine to another server on the same network.
The Catch
The server that will house the application is separate from the server that will receive the files from the local user's machine. In other words, to do the file copy the user will have to access the application on one server via IIS and within the application it must place that file on another server. Further, these servers while on the same network cannot physically see each other.
If anyone has anythoughts on how to accomplish this i would be grateful.
i have a database with several paths looking like the one below
C:\S&M Site Project\NEWSMAA\SitePhotos\2\GUY093\GUY093-Tulips.jpg
what i aim to do is load the images into a gallery control (if one exist)
the users viewing the images should be able to do either of the following:
1.Double click on an image to see it bigger or some large predefined size.(thats the viewing part of it)
2.Select those images the want and then extract it as a single PDF file to any location on the user machine.
3.print all selected images.
4.Remove all selected images from the gallery as well as the image path from the database.
if anyone has an idea on how i can go about doing this task i would be very grateful for a tutorial video or link .
Hi guys, let me get to the point:
I want have a button that when clicked allows the user to browse to any folder in any location whether it is a flash or the c-drive.
Depending on the location and folder selected the user must see all image files in that location whether jpg, bmp, png etc. these images must be visible to the user for selection. In other words the user must see the image and if he/she desires that image, then the user should be able to click on a check box next to the image or click a select all check box which would select all the images in the location.
after selecting all the images the user should be able to click a button to save these images with a time stamp appended in the path, to a specific location on a drive, then the image path is stored in a sql database.
If any error the user should be notified that the images were not saved and not stored.
i would be grateful for tutorials, videos or even plugins that can help me achieve my task...thank you!!
its not felxible enough to accomplish my goal
Hi Guys, i am working on a application that requires users to answer questions....what i want to do, because of the fact that the page has a lot of questions is to have some paging system on the form as well as keep page state whenever the user moves to another page....has anyone done something like this before...
Clarifying,
if you have a table with 7 entries
you want the name of those entries to be on 7 panels.
if the table grows in size the number of panels on the page grows also
hi guys,
i want to create a database driven panel, that is whenever the page loads how much ever entries in the database thats the amount of panels which must be created.
any suggestions....tutorials would be welcomed
i also would like to have each panel have the ajax collapsible extender attached to it.
my plot just got a bit thicker, i have 2 tables now table 1 has all the categories and table 2 has data but it is connection to table 1 through the category id. The task now is to make those categories as the headings for the collapsible panel. and the data that would fall under them should match but at the same time be housed in a listview of which will have to allow for editing if the user so desires......
HELP....DIRECTION
HAS any one done anything close to this before....
THe collapsible panel would have to be launched dynamically though? due to the fact that the headings are coming from a sql database. any ideas?
http://sports.yahoo.com/olympics/cycling/womens-cross-country-cmw021.html
the link above is from yahoo where if you click on final: you see the results.
what i want to do is to have that same effect the only thing is that the word final will be coming from a db and when it is clicked the details below will be editable.
Can you recommend a tutorial......because i know what i want to do just no sure how to do it.
hi guys,
i am looking for a control which has several headings from a database, regardless of the heading when clicked it should it expands to reveal a list view which can be edited.
the filteredTextBoxExtender might not work because the first three characters must be strings, which must be entered by the user. Following the 3 characters must be any number of digits.
eg : YUP9999, KIL091, KIQ222
Hi Guys,
i have three textboxes the first 2 should only allow users to enter numeric values (0-9) and decimal eg (5.2 , 5.5)
the third textbox should allow the first three characters entered to be YUP followed by numeric values only. eg YUP453 or YUP439.
Can anyone provide me a reference on how to do this? or what i should be looking to do this?
hi guys was able to solve my issue using this url
http://www.dotnetspider.com/resources/40659-Edit-Update-Delete-Insert-ListView.aspx
thanks alot!!
Hi guys i was able to fixed the issue so i am attaching the events for future reference.
protected void ListView1_ItemEditing(object sender, ListViewEditEventArgs e)
{
if (rdbid.Checked == true) {
ListView1.EditIndex = e.NewEditIndex;
GetDataFromUserSelection(1, "", long.Parse(Helper.temp.ToString()));
}
else if (rdbarea.Checked == true)
{
ListView1.EditIndex = e.NewEditIndex;
GetDataFromUserSelection(2, Helper.temp.ToString(), 0);
}
else {
ListView1.EditIndex = e.NewEditIndex;
GetDataFromUserSelection(0, "", 1); //loads the full zones list
}
}
protected void ListView1_ItemCanceling(object sender, ListViewCancelEventArgs e)
{
if (rdbid.Checked == true)
{
ListView1.EditIndex = -1;
GetDataFromUserSelection(1, "", long.Parse(Helper.temp));
}
else if (rdbarea.Checked == true)
{
ListView1.EditIndex = -1;
GetDataFromUserSelection(2, Helper.temp.ToString(), 0);
}
else
{
ListView1.EditIndex =-1;
GetDataFromUserSelection(0, "", 1); //loads the full zones list
}
}
protected void ListView1_ItemUpdating(object sender, ListViewUpdateEventArgs e)
{
string tempstr;
Label lbl = (ListView1.Items[e.ItemIndex].FindControl("IDLabel1")) as Label;
TextBox txt2 = (ListView1.Items[e.ItemIndex].FindControl("txtareaname")) as TextBox;
if (txt2.Text.Length <= 0)
{
AEERR.Visible = true;
AEERR.Text = "Site Area Name Cannot be left blank";
}
else
{
tempstr = Helper.IsAreaExists(txt2.Text.ToUpper()).ToUpper();
if (tempstr == txt2.Text.ToUpper())
{
AEERR.Visible = true;
AEERR.Text = "Area Name cannot be changed because it already exists";
ListView1.EditIndex = -1;
tempstr = null;
}
else if (tempstr == "")
{
tempstr = null;
Response.Clear();
Response.Write("connection failed, database error, please contact your administrator immediately");
Response.End();
return;
}
else {
if (UpdateRecordQuery(long.Parse(lbl.Text), txt2.Text.ToUpper()) == false)
{
AEERR.Visible = true;
AEERR.Text = "Error occurred in the database, the record was not changed. Please try again or contact your administrator";
}
else
{
AEERR.Visible = true;
AEERR.Text = "Area Name Successfully Updated";
Helper.AppRecord(Convert.ToInt64(Helper.base64Decode(Request.Cookies["SMAAUserId"].Value)), "Edit Area: The …
i am setting the code from behind....i have my list view up now but i cannot figure out how to edit and update it.
private void GetDataFromUserSelection(int opt, string areaname, long areaid) {
AEERR.Visible = false;
try
{
DBCON dbcon = new DBCON("masterConnectionString");
if (dbcon.startup() == false)
{
AEERR.Visible = true;
AEERR.Text = "Error occured at the database level, connection failed. Please try again or contact your administrator";
}
else {
localsqlconnect = dbcon.getConection();
dbcon.initStoredProcedure("GetZones");
localsqlcmd = dbcon.getCommand();
localsqlcmd.Parameters.Add("@idnum", SqlDbType.BigInt).Value = areaid;
localsqlcmd.Parameters.Add("@areaname", SqlDbType.NVarChar).Value = areaname;
localsqlcmd.Parameters.Add("@option", SqlDbType.Int).Value = opt;
localsqlreader = localsqlcmd.ExecuteReader();
if (localsqlreader.HasRows == false)
{
AEERR.Visible = true;
AEERR.Text = "The table which houses the data appears to be empty. Please try again or contact your administrator";
}
else {
dt.Load(localsqlreader);
ListView1.DataSource = dt;
ListView1.DataBind();
//while (localsqlreader.Read() == true)
// {
// dt.Load(localsqlreader, 0);
// ListView1.DataSource = dt;
// ListView1.DataBind();
// }
localsqlreader.Close();
dbcon.CloseConnection();
}
}
}
catch (Exception ex) {
AEERR.Visible = true;
AEERR.Text = "Error occured at the database level, connection failed. Please try again or contact your administrator";
}
}
I developed the code above to display the data in the list view instead of a gridveiw my challenge is whenere the use clicks edit....i am having a ton of errors....Can you provide some gudiance on the editing maybe a tutorial reference
I have a form that has a dropdown list with all the ID's of a particualr table in my database what i want to do is whenever the user selects a particular ID the remaining fields along with the id selected are loaded in a listview.
and
this dynamic list view must also allow the user to edit any filed execpt the ID field.
if anyone can point in the direction of a tutorial or a video reference i would be grateful......any other suggestions would be welcomed
Can you recommend a tutorial that i can reference?
my issue with the gridview how would you set it up so that the user only puts in numeric or string values when editing and i am using visual studio 2010. and i prefer to display the data programmatically.
hi guys i have a table in a database with data of which i want to display in a tabular format. In addition i want also to be able to edit a particular column of the displayed tabular data but the editing will only allow for the rentering of numbers, strings and -, / foreign characters.
i heard about a list view but not too sure!!!!
Hi Guys is me again!! I Have a question, if i have 2 asp.net pages (web forms) and form 1 (page 1) has a link that when clicked will generate form 2 (page 2). The trick is that form 2 (page 2) has a label that must load with a random number whenever page 2 is called.
I am lost as to how to accomplish this...any ideas???
Would it be appropiate to display errors (customer user) via a alert? The reason for this question; in windows development if a user makes a mistake with there login details you would flag a notication using a messagebox in web development what is the custom?
hi guys,
i have a database with a bunch of start and end dates for various users what i envision to do is depending on the user logged on that user only sees calendar values for the start and end range example:
User Travis
Start 21/06/2012
End 21/09/2012
Hence on Travis's Calendar he will only see the months june to september start from the 21st and ending on the 21st respectively.
any help or material would be welcomed
Hi Guys,
I am extremely new to ASP.net using C# the task i have at hand is as follows:
Page Load Tasks
Ensure that the LDAP is online first and if it is not provide the user with a message plus send a outlook mail to the administrator. Once the LDAP is online i would proceed to step 2.
Get all the users from a particular group and store there details in a cookie
User Button Click Tasks
I am looking for a tutorial or video which would assist me to achieve this taks
Hi guys,
i am new to asp.net and the little i know so far the one challenge for me has been site design. i am looking for a book, video, tutorial etc whereby i can produce a simple site design that is flexible regardless of the web browser used, and is also liquid which means that if the browser maximizes the site can adjust.
hi Guys,
i am planning to teach myself ASP.net using vb and c# via the visual studio 2010 ide. my issue is that many books keep recommeding visual web developer as the tool to use but i want to use Visual Studio 2010 and hence can somebody point me in the direction of a good asp.net book which will cater for my needs.
I have derived another challenge for myself, I created a package on an sql server (sql server 2000) this package populates a table in a particular database with data from a datasource. Every time i wanted the table to be updated i would go to data transformation services>> local packages and excecute that package. What i aim to do is write an application that would allow users to select the various packages they want to execute providing they have access to the particular database on the server. If anybody wants to attempt this venture feel free if and when i arrive at a solution i will post it.
Function StringCheck(ByVal str As String) As Boolean
Dim staticstr As String = "^[a-zA-Z]*[a-zA-Z]$"
Dim enfstr As Match = Regex.Match(str, staticstr)
If enfstr.Success Then
Return True
Else
Return False
End If
End Function
this is the function i wrote sorry about the previous post
Function StringCheck(ByVal str As String) As Boolean
Dim staticstr As String = "^[a-zA-Z]*[a-zA-Z]$"
Dim enfstr As Match = Regex.Match(str, staticstr)
If enfstr.Success Then
return True
Else
return False
End If
End Function
NB I imported the Regular expressions namespace.
The issue I am having is that I can only prevent the users from entering numbers. Special characters giving me headache
In my spare time i give myself programming stuff to do. Today i want to write a function that goes through a string, if the string contains any numeric value the function must return false, if the string has any special characters it must also return false else return true. For example the following strings would return as follows:
String Return Value
Travis True
78* False
44Travis False
(Travis) False
Any ideas on how to achieve this would be fine.
hi Guys,
i have several clients on a LAN network, these clients all have access to a particular sql server. i want to write an application that allows any client on the network to send one or more messages to another client on the network providing that both clients have access to the specified sql server.
i don't know what class or component i should read on, if anyone has information on how to achieve this i would be grateful.
Regards
my application works like this: if the user double clicks on a node in a tree view the report loads. this issue i am having is that all users have access to the database via windows authentication, hence i did this
rpviewer.LogOnInfo.Item(0).ConnectionInfo.ServerName = GServer
rpviewer.LogOnInfo.Item(0).ConnectionInfo.DatabaseName = GDatabase
rpviewer.LogOnInfo.Item(0).ConnectionInfo.IntegratedSecurity = True
but i am getting a error.
i was wondering if you would take a look. regards
Imports CrystalDecisions
Imports CrystalDecisions.Shared
Imports CrystalDecisions.CrystalReports
Imports CrystalDecisions.CrystalReports.Engine
Imports CrystalDecisions.ReportSource
Imports System.IO.Ports
'@@@@@@@@@@@@ Designed by: Travis Ferreira @@@@@@@@@@
'@@@@@@@@@@@@ Purpose:The purpose of this class is to house those
'@@@@@@@@@@@@ functions and subroutines which will aid in report generation
'@@@@@@@@@@@@
Public Class ReportingClass
Dim repath As String = ""
Dim rpviewer As New Windows.Forms.CrystalReportViewer
Public Sub ReportControl(ByVal tellernum As Byte, ByVal rpnode As String)
Select Case tellernum
Case 0
'doing nothing
Case 1
Case 2
Case 3
Case 4
Case 5
Case 6
'###################################################################################
Case 7
If rpnode = "Transaction by Type\Receipts from Currency" Then
repath = INI.ReadString("REPORTS", "Teller7_Currencyreceipts")
If ValidatePath(repath) = True Then
Call LoadReport(repath, "Receipts from Currency")
Else
'message
End If
' MsgBox(FrmTellersMDI.TreeViewREP.SelectedNode.FullPath())
ElseIf rpnode = "Transaction by Type\Cheque Encashment" Then
repath = INI.ReadString("REPORTS", "Teller7_Cheque_Encashment")
If ValidatePath(repath) = True Then
Call LoadReport(repath, "Cheque Encashment")
Else
'message
End If
' MsgBox(FrmTellersMDI.TreeViewREP.SelectedNode.FullPath())
ElseIf rpnode = "Transaction by Type\Cash Deposits" Then
repath = INI.ReadString("REPORTS", "Teller7_CashDeposits")
If ValidatePath(repath) = True Then
Call LoadReport(repath, "Cash Deposits")
Else
'message
End If
' MsgBox(FrmTellersMDI.TreeViewREP.SelectedNode.FullPath())
Else
End If
'###################################################################################
Case 8
End Select
End Sub
Public Sub LoadReport(ByVal …
i did some modifications but the core concept provided worked. However when it reports loads it is requesting a Database login i am looking for a way to not bring that up maybe by supplying the user windows login details....
any ideas would be greatful
I found it interesting so worked on it.
fill it with your report paths and see the result...
its working here..lemme knowImports CrystalDecisions Public Class Form1 'assuming you have three reports medical,science and chemistry Private mediflag As Boolean = False Private sciflag As Boolean = False Private chemflag As Boolean = False Private Sub create_tab(name As String) ' this is for creting new tabs TabControl1.TabPages.Add(name, name) TabControl1.SelectedIndex = (Convert.ToInt16(TabControl1.TabPages.Count - 1)) 'placing report viewer in the selected tab and setting repoert viewer properties Dim repoertviewer As New Windows.Forms.CrystalReportViewer repoertviewer.ShowGroupTreeButton = False repoertviewer.Dock = DockStyle.Fill TabControl1.SelectedTab.Controls.Add(repoertviewer) Select Case name 'placing report viewer in thetab Case "Medical Report" 'repoertviewer.ReportSource= report path here Case "Science Report" 'repoertviewer.ReportSource= report path here Case "Chemistry Report" 'repoertviewer.ReportSource= report path here End Select End Sub Private Sub place_report_viewer() End Sub 'this is for closeing active tab/report Private Sub close_report_Click(sender As System.Object, e As System.EventArgs) Handles Btn_close_report.Click If TabControl1.TabPages.Count <> 0 Then Dim tabname As String = TabControl1.SelectedTab.Name.ToString Select Case tabname Case "Medical Report" mediflag = False Case "Science Report" sciflag = False Case "Chemistry Report" chemflag = False End Select TabControl1.TabPages.Remove(TabControl1.SelectedTab) End If End Sub Private Sub focus_tab(name As String) ' this will switch to …
I have four crystal reports already created. I want to incorporate those reports into an application whereby when a user clicks on a menu item the report opens in a new tab providing that it is not opended already.
i would be grateful if i can have some insight from someone thanks in advance.
Hi Guys,
I am having a little programming jam at the moment. i have a datagridview set up whenever the user selects a row i am able to capture the necessary details but what i really want is the next row providing that the user selects the previous row.
example
users selects row 5
i want to capture row six details providing that there is a row six.
enclosed is the code snippet used to capture the selected row.
For Each rowd As DataGridViewRow In DataGridViewTransactions.SelectedRows
Call GlobalFunctions.DeleteTransactionControl(rowd.Cells(0).Value, rowd.Cells(1).Value, rowd.Cells(4).Value, rowd.Cells(7).Value, "Delete")
Next rowd
hi guys,
upon form load my datagridview is populated with data from an sql table. The datagridview has 3 columns Name, Amount and Cost. The Cost and Amount fields are have Zero as their default values. Whenever the user enters new values in those 2 fields i am using the row leave event of the datagridview to do a modulus on the amount against the cost.
The problem i am having is that the default values are being passed to the function and not the actual values entered by the user. I have enclosed my function and how i am getting the datagridview values. Any assistance would be grateful.
'below indicates how it is called
VerifyQuantity(DataGridViewRCC(1, i).Value, DataGridViewRCC(3, i).Value)
Function VerifyQuantity(ByVal a As Int64, ByVal b As Int16) As Boolean
'@@@@@@@@@@@@ Designed by: Travis Ferreira @@@@@@@@@@
'@@@@@@@@@@@@ Inputs:int64 and int16 @@@@@@@@@@
'@@@@@@@@@@@@Return:Boolean @@@@@@@@
'@@@@@@@@@@@@Purpose:Verifies that the quantities are of standard bundle sizes @@@@@@@
Dim tempval As Int64
tempval = a Mod b
If tempval > 0 Then
Return False
Else
Return True
End If
End Function
Hi Everyone,
I have MICR cheque Reader which scans the cheque and picks up data from the cheque like amount, account number etc. I want to interface this device in a vb.net application, however i have very little knowledge on how this can be done and i am seeking any assistance posibble.
Thanks in advance
Just dropping in to say thanks i was able to accomplish my task utilizing the site you recommended. i have enclosed code snippets
Imports System.Globalization
Dim culglobal As New CultureInfo("en-US")
Dim culclone As CultureInfo = CType(culglobal.Clone, CultureInfo)
If culclone.DateTimeFormat.ShortDatePattern <> "dd/MM/yyyy" Then
MessageBox.Show("Access has been denied, your system's regional settings is incorrect. Please contact your Administrator ", "Regional Settings Error", MessageBoxButtons.OK, MessageBoxIcon.Warning)
Me.Dispose()
Hi Guys,
i am looking for a little direction on an issue that is poundering on my mind. I want to prevent a form from loading if the systems regional datetime settings format for the date is not in the form of dd/MM/yyyy.
any suggestions will be welcome.