|
I think that you have to provide more information.
Where are you trying to upload the file? To your own application?
Is the error message generated by the application, or are there any more information in the error message?
Is this a VB application, or would this question be better off in some web development related forum, like ASP.NET or Web Development?
---
b { font-weight: normal; }
|
|
|
|
|
Please give file creation permission to the relevant client.
raj
|
|
|
|
|
Hi
How do you write the content of a text box to a file, appending new content and reading back that file into the text box showing the last written content at the top of the file?
Many thanks for any assistence.
newtWales
|
|
|
|
|
Dim reader As New IO.StreamReader(Server.MapPath("MyTextfile.txt"))
Textbox.text = reader.ReadToEnd()
same like write also
raj
|
|
|
|
|
Hi Raj
Many thanks for this it works well...Jim
|
|
|
|
|
hai
you can try this out.........
dim a as string
a=textbox1.text
File.AppendAllText("g:\text.text", a)
File.AppendAllText("g:\text.text", Now.Date)
File.AppendAllText("g:\text.text", " )
File.AppendAllText("g:\text.text", Now.DayOfWeek.ToString)
plz reply if this solve your problem
|
|
|
|
|
Sorry but I could not get this to work, but thank anyway. I got an error mesg saying " .AppendAllText" is not a member of Text. And I could not find a workaround. Jim
|
|
|
|
|
Hey All!,
Ia have a project iam currently working on in VB.Net. Its about a travel company that provides world wide flight routes for travellers. It as proposed that each traveller will be represanted by a linked list.
Now my aim is to produce a prototype of a software to demostrate to the travell company by designing, implementing and testing a linked list class and this class must include the properties and methods : Forward link, Node text add/insert node and remove node. Then implement a procedure that will traverse a linked list generating a graphical represantation of a linked list using label controls.
How can i solve this problem, PLEASE HELP!
Mwale
|
|
|
|
|
What is it that you have a problem with, then?
---
b { font-weight: normal; }
|
|
|
|
|
If you search the articles here you wil find 10's of results showing linked list implementations.
If you expanded the same search to Google that number would probably be 1000's
Current blacklist
svmilky - Extremely rude | FeRtoll - Rude personal emails | ironstrike1 - Rude & Obnoxious behaviour
|
|
|
|
|
Hi I need help on how to embed or save an image and not the path of the image in a SQL2000 at 600dpi and retrieve it at the same 600dpi to display.
|
|
|
|
|
Dim Adapter As New OleDb.OleDbDataAdapter(lSql, ConnectionString)
Dim CommandBuilder As New OleDb.OleDbCommandBuilder(Adapter)
Dim memstImg As New MemoryStream
picturebox.Image.Save(memstImg, picturebox.Image.RawFormat)
Adapter.Fill(dataset, "image_bank")
Datarow = dsImg.Tables("image_bank").NewRow()
Datarow.Item("image_file") = memstImg.GetBuffer()
dataset.Tables("image_bank").Rows.Add(lRow)
Adapter.Update(dataset, "image_bank")
raj
|
|
|
|
|
how to fit the window size to the fit size an din teh middle of the screen, and i would like the window be in the middle whenever it appears on the screen.also, whenever user click on the maximize the size,the size of teh form will be full scree,i dont know how to set it.sir, plz help me.tq
|
|
|
|
|
Simple,
set form’s StartPosition property to CenterScreen
For your second question
Set form’s FormBoderStyle property to None and WindowState property to Maximized
Regards,
Chatura Dilan
|
|
|
|
|
Hi all !
I am new in program for Crystalreport. In my Report, I have two Group By : School ID, and then Class ID. I want use GroupNUmber in order to Order NUmber the Group School ID ( 1,2,3, ...) But I allway recieve the Order Number of Group Class ID.
pls help me How to resolve the problem !
Thank alot !
Example : I want the result the fowllow
1 School1 1 Class1
2 Class2
3 Class3
2 School2 1 Class1
2 Class2
3 School3 1 Class1
But Reruslt :
1 School1 1 Class1
2 Class2
3 Class3
4 School2 4 Class1
5 Class2
6 School3 6 Class1
|
|
|
|
|
Original String:
Ki KiE:สวัสดีค่ะ โปรแกรม โอเอ็มเอส โดย บริษัท เอ็มเอสแอล ซอฟต์แวร์
Problems Facing:
1. The missing '00' in the begining and trailing part of the generated string
2. The white spaces within the original string (in THAI) show up junk characters instead of SPACE.
Please check this by pasting the source code attached and help me out in generating Correct output.
thanks in advance.
Correct Output which i am expecting to generate
004B00690020004B00690045003A00200E2A0E270E310E2A0E140E350E040E480E3000200E420E1B0E230E410E010E230E2100200E420E2D0E400E2D0E470E2100200E400E2D0E2A00200E420E140E2200200E1A0E230E340E290E310E1700200E400E2D0E470E2100200E400E2D0E2A00200E410E2D0E2500200E0B0E2D0E1F0E150E4C0E410E270E230E4C
Present Output which is wrong
4B00690014004B00690045003A0014002A0E270E310E2A0E140E350E040E480E300E1400420E1B0E230E410E010E230E210E1400420E2D0E400E2D0E470E210E400E2D0E2A0E1400420E140E220E14001A0E230E340E290E310E170E1400400E2D0E470E210E400E2D0E2A0E410E2D0E250E14000B0E2D0E1F0E150E4C0E410E270E230E4C0E
Code responsible for conversion:
'-------FUNCTION CALLS -----------
Dim bytes() As Byte = ConvertStringToByteArray1(msg)
Dim str As String = bytetohexa(bytes)
'------ FUNCTION DEFINITIONS ---------
Public Shared Function ConvertStringToByteArray1(ByVal stringToConvert As String) As Byte()
Return (New System.Text.UnicodeEncoding).GetBytes(stringToConvert)
End Function
Private Function bytetohexa(ByVal bytes() As Byte) As String
Try
Dim sHex As New System.Text.StringBuilder(2 * bytes.Length)
Dim i As Integer
For i = 0 To bytes.Length - 1 Step 1
sHex.AppendFormat("{0:X2}", bytes(i))
Next
Return sHex.ToString().Replace(" ", String.Empty)
Catch ex As Exception
Return (vbNull)
End Try
End Function
One who is in search of knowledge.. should give up pleasure . visualliser -2006 A.D.
|
|
|
|
|
Some XP user use the XP form style, some of them disable the style to use the classic one.
However, this style really affect the look of my form.
How can I know what is this setting in user computer?
|
|
|
|
|
You can P/Invoke UxTheme.dll which controls the window styles in XP like this...
<DllImport("UxTheme.dll", _
CallingConvention:=CallingConvention.Winapi, _
CharSet:=CharSet.Auto)> _
Private Shared Function IsThemeActive() As Boolean
End Function If this function returns true, the user is running a theme, if it returns false then the user is running 'Windows Classic Style' - no themes.
Hope this helps
Cheers,
Will H
|
|
|
|
|
Thank you so much and It is really a great hint for me,
but it does not work by copy and paste.
Where should I place it in my module ?
Thank you~
|
|
|
|
|
To add it to a module you'll have to do two things...
1) Change the line
Private Shared Function IsThemeActive() As Boolean to
Public Function IsThemeActive() As Boolean (i.e. remove the word Shared and change the functions visibility to Public )
2) Add
Imports System.Runtime.InteropServices to the top of your file.
I havent done any VB.Net in a while so I hope that works
Cheers,
Will H
|
|
|
|
|
hi, i would like to insert a picture,(logo) of da company as a background and insert button ENTER on that.but i dont know how,sir, could u pls help me on doing that..thanx a lot.
|
|
|
|
|
You can specify a BackgroundImage for a form and place your buttons and other controls on the form as normal.
Other things that might be better for what you want are placing a PictureBox on the form with the logo in it. To make sure it stays behind the other controls, from the Format menu, choose Order > Send to back.
Or, place a Panel control on the form and set the Background image of it to your logo. You can then place controls on the Panel control itself (panels are container controls)
Hope that helps!
|
|
|
|
|
Hello!
This sample procedure extracts email addresses and adds to database. However, it is successfully adding the first address and creating empty records for the others. I decided to test the procedure with vb.net and took out adding the database section. It worked perfectly. So I would like to know what is causing not to add other emails except the first one.
Thank You
Sub AddEmails()
Dim GetEmails
Dim SrchKey
Dim xPos
Dim x1, x2
Dim xAddr
GetEmails = Request.Form("emails")
xPos = 1
x1=Instr(xpos,GetEmails,VbCrLf)
DO WHILE xpos <= len(Getemails)
x1=Instr(xPos,GetEmails,vbCrLf)
x2=Instr(xPos+1 ,GetEmails,vbCrLf)
If x1 = 0 or x2 = 0 Then Exit Do
If xPos = 1 Then
xAddr = Mid(GetEmails,1,x1-1)
Elseif xpos > 1 Then
xAddr = Mid(GetEmails, x1, x2 - x1)
End If
If len(xAddr) > 4 Then
'check here if email address is not exist in the database
SrchKey = "SELECT * FROM emails WHERE email="& "'" & xAddr & "';"
Call InitializeConnection()
Call Establish_Recording(SrchKey)
If ObjectRecord.RecordCount <= 0 Then
ObjectRecord.Close
ObjectConnection.Close
Set ObjectRecord = Nothing
Call InitializeConnection()
Call InitializeRecordSet("Emails")
'PROBLEM IS CAUSED BY THE FOLLOWING STATEMENTS
'IT IS ADDING THE FIRST ADDRESS BUT NOT THE OTHERS
ObjectRecord.AddNew
ObjectRecord("email") = xAddr
ObjectRecord("Accept") = True
ObjectRecord.update
ObjectRecord.Close
ObjectConnection.Close
Set ObjectRecord = Nothing
Else
ObjectConnection.Close
End If
xAddr = ""
xpos = x2
End If
LOOP
Response.Write ("Email have been added!")
Response.End
End Sub
|
|
|
|
|
This is just a guess. Wouldn't the ( xAddr="" ) set a blank each time the program made a loop?
|
|
|
|
|
Hello!
Thanks for your respond. Xaddr returns a value eact time in the loop. I have tested the code with vb.net. I think having connection to database or recordset inseide the loop is causing the problem even though connection is getting closed and object record set to nothing.
|
|
|
|