Raised This Month: $ Target: $400
 0% 

replace string with number


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
gamer99
Senior Member
Join Date: Jul 2011
Old 07-16-2011 , 01:26   replace string with number
Reply With Quote #1

Hi all ,

I am trying to code a custom ban ..there i want to replace %bantime% with bantime .

So i used

replace_all(str, 127, "%bantime%", dBanTime)

But as its a number i think because of it I am getting the below error.

Quote:
error 035: argument type mismatch
Any idea how to replace that ?
gamer99 is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 07-16-2011 , 01:36   Re: replace string with number
Reply With Quote #2

Turn the number into a string using num_to_str().
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] is offline
gamer99
Senior Member
Join Date: Jul 2011
Old 07-16-2011 , 01:53   Re: replace string with number
Reply With Quote #3

it worked like a charm ... thank you
gamer99 is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 00:54.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode