Im working on a number to text conversion in ASP, just like this : 456 = four hundred fifty six. If you have any cool function, In case you don't, how can I analyze the caracters of a number one by one, and know how much caracters a string has?
Ej = "1234" has 4 caracters
I have a string as "123.45" and want to convert it to 123.45 so that I can do some multiplication calculation. How do I do this so that it could work> I am really lost.
In my main 'submit news' admin for a site I am doing, I want to be able to offer the person submitting the news the ability to reference other files within their text without the need to use HTML. My proposal is to use [square brackets] within the text that will then be parsed when the page is rendered from the database. At present I have this - e.g.
To download the file [file.exe, click here]. Which I want to render with the words 'click here' as being a link to file.exe. I'm very familiar with instr, replace and split (all of which I think I would need to use) but I cannot figure out how to parse the above text in the way I want.
I need to insert some number into database as text. My problem is if I insert the number (ie. 4.0), the value in the database only show (4). So, is it possible to convert a real number into text number using ASP?
I am making a check writing page and was wondering how to convert a variable in the form of $1234.56 to One Thousand Two Hundred Thirty Four Dollars and Fifty Six Cents (Or something like that).
I need to modify some code written by someone else that sends out an automated email based on a form submittal. In the form, values are set to 1 or 0 for "yes" or "no". I need to modify it so that the email changes the 1 or 0 to their text equivalents (yes/no).
I CANNOT modify the form itself to change the variables, so i assume i need an IF stmt to that converts the string to text before it sends. Can someone point me in the right direction for how to do this?
i have several fields in the database that the format is number. then, i have a report page that allow user to open it the ms excel. my problem is, when all data transfered to ms excel, all data that is in number format, they are located at the right of the cells and there is 1 data named noIC, suppose this data is a 12 digits number but in the ms excel, it became something like this 780945+E12....
to solve this problem, i have to change the cell's format everytime all data have been transferred to ms excel. i have to set to left indent for all fields that contain numbers and for the noIC i have to set from General to Number.
I have a text field in a web page I am working on that seems to be calculating phone numbers before inserting them into an Access database. i.e., 867-5309 will result as -4442 in the Access text field. My guess is that the webserver or client is processing it before inserting it. Is there any way to stop this other than using a validation script?
in master batch table i have various master batch like 200701-0001 200701-0002 200701-0003
Now each master batch can have multiple final mixed batch like
200701-0001-01 200701-0001-02 200701-0001-03
and this record is inserted in to fmix table.
so i have a form in which i have a dropdown menu in which all the master batch is listed, i select 200701-0001 and that value is passed to next page where i will enter other fields data and insertion to my fmix_no will be done automatic like 200701-0001-01, 200701-0001-02 and so on,
how to achieve this
so in short each master batch will have more than one final mixed batch.
pls help, also if u have any online contact in yahoo or msn pls send me, i am so confused and badly struck deadline is just couple of hours away. my yahoo id is(E-Mail address blocked: See forum rules) you can PM me i am online right now.
I want To handel the error messages by myself in one part in my script. I know that in VB I can Use the statment - On error resume next And I also know that I can retrive the Error Number In VB with Err.Number.
How can I handel the errors by myself in ASP? I heard about the ASPErr Object, Is it the same thing like the err object in VB?
The following code gets me the day of the month which I use in a query to give me all employees' birthdays for this period. But I have a bug: day variable used in the query must give me todays date(19),it gives me 21 (2 more than I want)
I could really do with some guidance. I am currently hosting my website on a Windows Server, and use ASP pages for accessing MS Access database data and also CDONTS for forms to email.I was just wondering if I were to swap to Linux hosting, how easy or hard ( would it be to change these pages from ASP to PHP with the exact same functionality.
I created a form to allow a visitor to add a new record to a database with the recordset object. Is there any conversion that needs to take place from the form input fields the user gives me to the recordset object? One of my form fields that I have is going to contain a money datatype in my SQL database and so far it's giving a 500 error.
My code in short looks like: strCurrentPrice=Request("currentPrice")
then upon adding to the database the code looks like: rsAddCards("currentPrice")=strCurrentPrice
I am calling a recordset from sql which happens to contain one column that is a datetime in the format: DD/MM/YYYY HH:MM:SS. So when I call that column from the db, it displays in the same format within my page.
However, I would like to be able to display the datetime as part of my recordset, but in a more aesthetically pleasing format (i.e: Sunday 1st May 2000, 7.23PM)
I have tried using the formatdatetime() function along with my rs, but this causes syntax errors. I know this is probably dead simple, but I don't get it!
I keep getting a type mismatch 'cdbl' error on the line: cmd_AlloUpdateM2__incrdecr = cdbl(cmd_AlloUpdateM2__incrdecr)
What's weird is I use this in other sections of my code and it works fine...no error. I've checked and re-checked the code and can't find the why this is happening?
Anyone have any code handy to convert a binary number to decimal and a decimal to binary? I need server-side code to perform these calculations. For example, I'd like to be able to pass 129 to a function and it will return 10000001. Likewise, I'd like to pass 10000001 to a function and get 129. I can do this on paper, just not sure where to start on how to pass these numbers into a function to perform the calculation.
I am in UK using XP with date format set to dd/mm/yy. I am running an asp site from a server in USA, which is returning the date from a database field retrieved as objrec("todate") in US format mm/dd/yy. To rectify this so as not to confuse visitors to the site I am trying to get the date displayed as dd month yy , e.g. 25 January 04 by using the format function format(objrec("todate"), "d-mmmm-yy"). This returns me a VBScript runtime error "Type mismatch: 'format' " The data base field "todate" is stored in short date format, which should be OK shouldnt it?
My database is being converted from Access to MySQL. My question is how do I maintain the database once the switch has taken place? Are there freeware MySQL administration GUI's or something? I'm a little clueless here.
I currently am using a script which submits full state names to a payment processor. However, the payment processor only accepts 2 digit state names. Does anyone have a premade code for asp that converts state names into 2 digit ones. Code:
I'm currently working on a form that, upon submit, generates an RTF file. I've run into a little formatting issue. If you're typing in a text box, much like this one, and hit Enter to go down to a new line, nothing happens in the RTF coding. For me to have a text box Enter/Line translate into my RTF file, I need to replace it with /par . So, I know about the Replace() string function, but how can I make this work with a carriage return
I am basically looking to create / incorporate some form of Auto-PDF generator into a website I am developing, essentially so I can set a webpage which I want it to convert.exactly in the same way that it works when you go to a Webpage then in the Browser you hit Print > and select Adobe PDF printer.This then creates a PDF identical to the webpage you are viewing
I seem to be hitting brick walls with this as I found one option which did this, but this did not support CSS, so exported the page on the fly, but with no formatting whatsoever.I then looked into ASPPDF but this does not allow for this
I have a number of HTML documents that I want to convert to PDF using a server component accessible from ASP.Can anyone tell me which component is the best and cheapest to use? It's a jungle out there