Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
 
  HOME    TRACKER    Visual Basic




Char 13


How can i convert chr(13) to vbCrLf on file input?

-JimHell




View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread
Acces To String Char To Char
sorry for my newbie. how do i acces to a string gettin just a char of it?
I just dont how, it must be easy!

Strings - Running Through Them Char By Char
How do you go about selecting each individual character from a string.

For example, I only want the value of the four right hand characters on a string I will not know the length of. It sounds like an easy thing to answer, but I just can't figure it out.

Thanks for all help, in advance.



Knows a little about a lot

Moving Char-by-char In A Given String
can anyone knows how to move char-by-char in a given string, this i figured so far

For i = 1 To Len(strTest)

Next i

inside this loop should be a statement to access the first char, anyone knows it??

How To Read A String Value Char By Char
Hi,

Please guide that how I can read a string value char by char ?

Does Anyone Here Understand Char 10 And Char 13 Vb Chars?
in order to unlock a password for something? it is 9 lines and i am wondering if anyone knows how to figure out what it is.. since they don't show up in html or e-mails.. i also know that if you made all possiblities with char10 and char13 vb characters for a 9 letter pw it has to be one of them.

does anyone understand these or can help me?

Can I Read Line Char By Char
Can I take a line of input and read each character withou assigning whole line to a string? If so can you give an example?
Thanks

Txt Reading In VB Char By Char
how do you read the "number" of letters rather than the number of words?


Open "C: est.txt" For Input As #1

Dim a(0 To 100) As String

b = 0

Do Until EOF(1)
b = b + 1
Line Input #1, a(b)
Loop
Close 1

Char To Byte To Char
I have to change a Byte type array into a String.

dim carddata(16) as byte
dim blockbuffer as string

For i = 0 To 15
Blockbuffer = Blockbuffer + Chr(sData(i))
Next i

Then I try to get it back via

For i = 0 To 15
sData(i) = Asc(Mid(Blockbuffer, i + 1, 1))
Next i

I found that I cannot get it back if some of the sData(i) value is greater than 128.

Can someone tell me how should I correct the problem?

Line By Line Search, Instead Of Char By Char.. (Resolved)
I have a file I'm trying to parse through. It's an ASX-style (although not exactly ASX) file.

I'm "plucking" entries out of it.. <entry> blah blah </entry>

Currently, I read the file into a textbox or string (textbox simply because it's visual, but a string works just as well) and then do a single char by char search through the entire string. Obviousl this can take a LONG time on larger files. Very, very ineffecient.

Is there a way to automatically chunk each line from a multiline textbox (or string using vbcrlf's)?

An example of how i'm currently doing it..


VB Code:
Text1.Text = ReadFile(FileName) Dim xX As Long For xX = 1 To Len(Text1.Text)If LCase(Mid(Text1.Text, xX, 7)) = "<entry>" Then(Do something)End Ifnext xX


Just wondering if anyone can make a suggestion on how to do this properly, as compared to my backwards-assed way.

Thanks.

(Yes, i'm aware thre's some form of ASX API or functionality. Not interested, as learning how to do this will apply to other file read functions, not just ASX stuff.)

How To Only Get That Last Char
hello, can you suggest me how to only get that last char "<" to ">".

is right$

example:

Return-Path:
Text1: Return to><peter go> <peter company > <your@hotmail.com>


I only get in Text2.Text = <your@hotmail.com>


any suggest , please!

Looking For Char
Is there a way too see how many times a char occurs in a string?

, And Other Char's In VB
oki, here is my question

when entering caption of some control, i have to type alt+154 to get character like . but there are characters that i need, and they can't be typed trough alt+some number, like , ... how can i get this font's in my program?

Char By Char
Can some1 help me out with this?
I want to read the data from a textfile, the data in the file is stored like this: blablabla;bliblibli;bbbbb. it uses the ; as a seperator. Now i want to read the data until the ; char is found, then sore that data to a var. now it has to continue reading till the ; and store tht data in another var etc. etc.
Can some1 help me with this?

Thnx Fatal M

Get Char From Str
Hello Gurus,

How to get half of char in string and place those char into another string?

Example:
get 'abcdefgh' from strInput and add half of char into strOutput='abcdef'
or
strInput='abcdefgh' ==> strOutput='abcdef'

Thanks

Char
i am trying to replace anywhere there is a " in a string with a space.
Basically i ant to remove all "s in the string however when i do
replace(string,""","") it throws an error because there are three quotation marks.

i was thinking mayb i could use char instead like char32 for space.

but i dont know where to find the char number for a quotation mark???

Char$(13) And Using Char(13)
Hello

What is the difference between using Char$(13) and using Char(13). What does the doller sign do? Any examples.

Char$()
Char()
Do these do the same things

Many thanks in advance

SQL Char Set
Hi there,
can any body help me in solving this,
how do i store arabic char set in SQL server ....
enn the char set is ISO 8559-6

TIA
Kittu

Char(1)
Im not sure how but I need the code to
see if char one is a "," ..

Thanks!

Char's
hi all, 1 question i have
i have txt box on my form, and o have a code that check's what has user entered in that txt box, but i have a problems, i want that i can type in that text box EVERY CHAR (numbers + other characters) exept aphabet leters (a-z A-Z)... if someone can point me in right direction i would be gratefull

Char
i am trying to replace anywhere there is a " in a string with a space.
Basically i ant to remove all "s in the string however when i do
replace(string,""","") it throws an error because there are three quotation marks.

i was thinking mayb i could use char instead like char32 for space.

but i dont know where to find the char number for a quotation mark???

Char$(18)?
Hi guys...

Can anybody help me with the output of char$(18)

Char
i am trying to replace anywhere there is a " in a string with a space.
Basically i ant to remove all "s in the string however when i do
replace(string,""","") it throws an error because there are three quotation marks.

i was thinking mayb i could use char instead like char32 for space.

but i dont know where to find the char number for a quotation mark???

Removing A Certain Char
i'm just wondering if there is a way to an efficent way remove a certain char in all instances in a text file, without going through it iteratively.

i'm wondering if you could accomplish this with bitshifts.

Add Char At The End Of Line?
Hi ppl,
how can i add a character at the start and at the end of a line?

Tnx in advance

Char Stats?
Im making the "New Character" form now.
and i have made 5 textboxes that the user can write his name, nick etc.
but how to read the data? like i have a Stats form and in it i want the characters name and nick..
Thx for help.

Direct 3d With Char's
i have been studing how to make a height map in 3d max studio, and just recently found examples of how to make a heght map in direct 3d. does anyone have any more examples of direct 3d heightmaps, and also how to put characters on a heightmap.

also the examples that i was able to find in direct3d only supported 180 x 180 pixel heightmaps. is this a limitation of direct 3d or a limitation of the programmers skills?

MSComm - NUL Char
Hello,

I need to send NUL char which is 00h using mscomm.
I tried:

mscomm1.output=chr(0)

... and it doesn't work.

Anyone knows how to send a NUL char value with mscomm?

Oncomm With An End Char
Hi again could you tell me please how could I do this, I do not have a fixed chars just a chr(13).
Private Sub MSComm1_OnComm()
Dim buffer As Variant
Dim tempbuffer As String
If MSComm1.Input <> Chr(13) Then
tempbuffer = MSComm1.Input
Globalbuffer = Globalbuffer & tempbuffer
Else
MSComm1.PortOpen = False

Text5.Text = Globalbuffer
End If
End Sub

Showing Up Char
I'm trying to display a second character for a DX game editing the copy and paste code for the sub to show the main character. Allthought i relly can't figure how to display the character @ the right x and y. I've been working on it for 3 hours and a half stair and can't figure out so I'm posting here, here the code:
Code:

Public Sub DrawPlayerData()
'line to display character
BltPlayer Body, BodyRECT, DDBLTFAST_SRCCOLORKEY Or DDBLTFAST_WAIT 'puts the body image at the players x and y coords
BltPlayer Head, HeadRECT, DDBLTFAST_SRCCOLORKEY Or DDBLTFAST_WAIT, 3, -21 'places the head a little about the x and y coords
End Sub
Public Sub BltPlayer(ByRef surf As DirectDrawSurface7, ByRef SrcRect As RECT, _
ByVal trans As CONST_DDBLTFASTFLAGS, Optional xOffset As Single, Optional yOffset As Single)
Dim x As Single, y As Single
Dim temprect As RECT

Call GetPlayerPosReMap(x, y)
x = x + xOffset: y = y + yOffset
temprect = SrcRect 'because we can't pass rects byval _
we need to store it to reset it later on

'Here we check if the persons too far left and adjust
If x <= 0 Then SrcRect.left = SrcRect.left - x
If (x + SrcRect.Right - SrcRect.left) >= 640 Then _
SrcRect.Right = SrcRect.left + (640 - x)
x = IIf(x < 0, 0, x)

'Here we check if the persons too far right and adjust
If y <= 0 Then SrcRect.top = SrcRect.top - y
If (y + SrcRect.Bottom - SrcRect.top) >= 480 Then _
SrcRect.Bottom = SrcRect.top + (480 - y)
y = IIf(y < 0, 0, y)

'Blt the whole thing
ddsBackBuffer.BltFast x, y, surf, SrcRect, trans

'Then copy rect rect back over
SrcRect = temprect
End Sub
Any help is greatly appresiated

GetFoucus Len(char)?
hello, any suggest how to imm. show me type what chars give me Len(char) ?

Text1.Text, Label1.Caption

In Text1.Text type "ABCD" automatic show me use 4 chars in Label1.

In Text1.Text type "ABCDEFG" automatic show me use 7 chars in Label1.
...

This is no equal Command1. to run, is background detect..

Please!

Parenthesis Char Value
Does anyone know how I can do this:


Code:
OpenParPosition = InStr(0, MyString, "(")
CloseParPosition = InStr(0, MyString, ")")

vba (though I assume vb6 would to) freaks... presumably because of the parenthesis. Can i search for the char values, and if so is there a link to a list of char values.

Thanks so much in advance

Edit:
UPDATE: only get error when there is a "(" in the string. Even more confussed. Just want to go home and see santa.

Remove Last Char
I want to remove the last character of a string, I had the code but can't find it anywhre on my PC. Sorry but can someone please tell me it again?

Non-Printable Char
Hey guys,
I was sent a flat text file filled with data I have to read into a database.
I am using the standard open statment with a line-input.
Problem is, about half-way through the file, there is an odd character, ascii value 26, that causes it to stop reading from file. I only get the data up to that point in the file, I cant get the rest. If I could only read the data out I would replace any odd characters, but, it wont even let me read past the point of that non-printable character.

Any ideas? I am really stuck.

Thanks,
B.F.

Backspace Char
Hello,
I just wanted to see if anyone could help me figure out what to use to tell when the backspace key is hit. Sort of like a vbenter but for backspce.
thanks

Password Char
I have 2 snapshots of MS Outlook Express, exactly the same version, but the first one in Win98 and the second one in WinXP.
You see a special Password Charatcer for the password field in WinXP.
I wanna this! What's the name and details of that character?
And is it only available in XP?
What I should do?
Thanks.

A Letter To A Char
i need the code for the entire alphabet to l33t letters... using an option button or check button neone help me???

Ascii &lt;-&gt; Char
Hi...Can anyone tell me how to convert a character to an ascii value and vice-versa?

Chinese Char
why all this Combobox, Listbox, DBcombo, DBList cannot show Chinese char? any solution.. 10q

Finding A Char
how can i find if a character is being used in a text box??

e.g: if someone type "Hi>" how can i "extract" the > char???

Convert Char To Int
Problem:
Can't convert char to an int, it does work on databases that was created on SQL 2000 but not when they are created in SQL 7.
I am running SQL 2000, imported a db from SQL 7

Field in db: personnr char (10)
I would like to do this(extract from a sql query):

...
left(person_nr,2) between 19 and 20

Error message:
Syntax error converting the varchar value 'DE' to a column of data type int.

Tried cast(ltrim(left(person_nr,2)), as int)
and also convert(int, ltrim(left(person_nr,2)))

But no luck

/Jerry

Char In VB And String In VB
Hi everybody !
I've create dll use Visual C.
.h file :
#include "string.h"
void __stdcall GS84( char inStr[100], int j, char outStr[100] );
.cpp Flie :
void __stdcall GS84( char inStr[100], int j, char outStr[100] )
{
strcpy(outStr,inStr);
}
.def Flie:
EXPORTS
GS84 @1
build : str.dll
I call it by VB6 :
Public Declare Sub GS84 Lib "d:str.dll" (ByVal instr As String, outstr As String)
Private Sub Command1_Click()
Dim outstr As String
Call GS84("Hello word", outstr)
End Sub
but can not run VB program.
Message is:
The instruction at "0x046f10f1" referenced memory at "0x0000000". The memory could not be "Written".
Please help me.

Getting Char Typed
Hi,
For my application I need to trap the previous character typed while typing the next character.Is there any win32api to do this (not using VB).

regards,
Anand.

What Char Is Thise?
Looking tru a text file which im loading im getting some strange character feedback.

I wanted to see what char it is and have i could get the acutal value.

So have could i get thise char.

tried whit chr, but that dosent seem right

The char, look like a square

Help On Some Char Not Displaying
why some of the char im using is not displaying properly on my listbox???
im only getting this rectangle looking char??



im using this code...

List3.AddItem ""
List3.AddItem ""
List3.AddItem ""
List3.AddItem ""
List3.AddItem "a"
List3.AddItem "b"
List3.AddItem "c"

Strings First Char
Hello,

Thanks for all the help I've been receiving and for the fast responses!

I've another question:

How do I find what the first character of a string is. Example,

If the String = "Hello"

The procedure would find the letter "H", because the first letter of "Hello" is "H"

Thanks in Advance!

Password Char
Hi everyone.

I've been trying to make an validation form, and i've reached a problem.

I'd like to have a * as a password char, and that's ok with TextBoxes, but i wanted to have a #### mask on the TextBox.

So i used a MskEdBox, that belong to the Microsoft MaskEditor component. But then i didn't now how to make password chars!


What i wanted to know is how to make masks on a normal TextBox, or how to make password chars on a MaskEdBox.


And by the way, a naive question.

How do i check the lenght of the text on a textbox? Kinda forgot.


Thanks for the atention.

Splitting After A Certain Last Char.
Okay, I have a browse button, and the person browses for a song, and pushes ok. The direct link to the music file is put inside a textbox. E.g.


C:Documents and SettingsMyUsernameMy DocumentsMy MusicSecondhand Jive - Lucky.mp3

I want to split off the Secondhand Jive - Lucky.mp3 part using the last splitter in that file name, ... So in otherwords, i want my split command to split the text using the last in the file name (text is located in the text box), leaving me just the Secondhand Jive - Lucky.mp3 in a new text box.


IDEA: Split text with the last "".

Thanks for any help. Sources and/or codes are VERY appreciated.. thanks.

Adding Char At The End
Hi friends,
I have a text file and there are hundreds of words listed.I need to add a full-stop(.) or any other character at the end of all those words....as in :
book
pencil
door
window
school
pink
sunday
....................should look like:
book.
pencil.
door.
window.
school.
pink.
sunday.

any idea ?
Thanks

Password Char
hi everyone

i have a textfield which takes password as input so i changed the passwordchar to "*" but windows login uses a different password char ,i have attached a pic of how it looks like ...i tried looking up the character map but found nothing like that ....

any ideas how that can be acheived??

Copyright 2005-08 www.BigResource.com, All rights reserved