C Runtime Library & variable parameters

Just starting out? Need help? Post your questions and find answers here.
User avatar
skywalk
Addict
Addict
Posts: 3972
Joined: Wed Dec 23, 2009 10:14 pm
Location: Boston, MA

Re: C Runtime Library & variable parameters

Post by skywalk »

What is the harm of replying to older posts?
1. They show up in searches.
Why allow old mistakes or questions to persist?
There are no time limits on discovery!!
2. PB's syntax has changed many times and Fred encourages users to update snippets to the latest version.
3. Older posts and their resolutions are still relevant to users who must sustain older OS and/or PB versions.
The nice thing about standards is there are so many to choose from. ~ Andrew Tanenbaum
User avatar
netmaestro
PureBasic Bullfrog
PureBasic Bullfrog
Posts: 8425
Joined: Wed Jul 06, 2005 5:42 am
Location: Fort Nelson, BC, Canada

Re: C Runtime Library & variable parameters

Post by netmaestro »

My leaky brain and pathetic filing system make it necessary for me to revisit the answers to questions I asked here 12 years ago. Although if a user is going to actually reply to something this old, a narrative somewhat more illuminating might be preferred over the mere posting of some cryptic code alone. That said, it's not an offense worthy of the poster receiving a stomping at the hands of his new colleagues imho.
BERESHEIT
User avatar
Fluid Byte
Addict
Addict
Posts: 2336
Joined: Fri Jul 21, 2006 4:41 am
Location: Berlin, Germany

Re: C Runtime Library & variable parameters

Post by Fluid Byte »

freak wrote:@Fluid Byte:
Whats up with you today? Take it down a notch and stop antagonizing people.
First it was "triggered" and now I'm "antagonizing" people. Why are you siding with necro-posters who can't use code-tags? What is up with you today?
freak wrote:If you continue acting like you're in kindergarden, I'll have to give you a time out.
Having a valid point isn't kindergarden, you need to stop smoking weed. By the way, don't threaten me and shove that "time out" up your ass.
freak wrote:Have a beer and relax a bit dude.
I will have a beer but I am not your fucking "dude".

@skywalk & @netmaestro
Necroposting
Any post or comment made on a forum thread that is very old, e.g. a thread with the last comment being several months old. This type of posting is often done by those who may have stumbled across a thread using search without realizing no one has been actively talking in the thread. Necroposting is looked down upon among the forum community because it is bad forum etiquette to reply to a discussion that has already ended.
Come the fuck on guys, we are talking about 11 years here. Everyone in this thread has moved on. Don't tell me that you really need THIS code for a project you are working on right now. Just don't sell me that horseshit and try to act offended. Half the people left, the others are passive lurkers. The IDE and syntax have changed dramatically. Don't gimme that "update the example" bullshit. There was never a solution here. He just posted coded without any context and without codetags in a dead thread.

If you really, really need this and want to tell the world about it make a new post but not anywhere, in the "Tips & Tricks" forum.
Windows 10 Pro, 64-Bit / Whose Hoff is it anyway?
freak
PureBasic Team
PureBasic Team
Posts: 5929
Joined: Fri Apr 25, 2003 5:21 pm
Location: Germany

Re: C Runtime Library & variable parameters

Post by freak »

This has nothing to do with whether your points are valid or not. That is irrelevant at this point. If you can't form a single sentence without using a swear word or insulting someone then you don't belong in this forum. It's as simple as that.

You are banned for a week. Come back when you have cooled down.
quidquid Latine dictum sit altum videtur
Little John
Addict
Addict
Posts: 4519
Joined: Thu Jun 07, 2007 3:25 pm
Location: Berlin, Germany

Re: C Runtime Library & variable parameters

Post by Little John »

freak wrote:This has nothing to do with whether your points are valid or not. That is irrelevant at this point. If you can't form a single sentence without using a swear word or insulting someone then you don't belong in this forum. It's as simple as that.
I agree.
freak wrote:You are banned for a week.
Thanks for doing so. Unfortunately, that seems to be the only "language" which he understands.
User avatar
luis
Addict
Addict
Posts: 3876
Joined: Wed Aug 31, 2005 11:09 pm
Location: Italy

Re: C Runtime Library & variable parameters

Post by luis »

You can't keep an elite hacker down. Fluid Byte is too powerful to be banned.
I mean FluidByte without the space.
I mean before being deleted, spammer style.
"Have you tried turning it off and on again ?"
A little PureBasic review
DarkDragon
Addict
Addict
Posts: 2218
Joined: Mon Jun 02, 2003 9:16 am
Location: Germany
Contact:

Re: C Runtime Library & variable parameters

Post by DarkDragon »

skywalk wrote:What is the harm of replying to older posts?
1. They show up in searches.
Why allow old mistakes or questions to persist?
There are no time limits on discovery!!
2. PB's syntax has changed many times and Fred encourages users to update snippets to the latest version.
3. Older posts and their resolutions are still relevant to users who must sustain older OS and/or PB versions.
4. The main reason why this is forbidden in communities: the database can become slower.
bye,
Daniel
User avatar
Fluid Byte
Addict
Addict
Posts: 2336
Joined: Fri Jul 21, 2006 4:41 am
Location: Berlin, Germany

Re: C Runtime Library & variable parameters

Post by Fluid Byte »

DarkDragon wrote:4. The main reason why this is forbidden in communities: the database can become slower.
I can't tell if you are serious or being sarcastic
Windows 10 Pro, 64-Bit / Whose Hoff is it anyway?
User avatar
skywalk
Addict
Addict
Posts: 3972
Joined: Wed Dec 23, 2009 10:14 pm
Location: Boston, MA

Re: C Runtime Library & variable parameters

Post by skywalk »

Yeah, pretty sure modern servers & databases are not stressed by forum postings from 10 or 20 years. It's what databases do. :idea:
The nice thing about standards is there are so many to choose from. ~ Andrew Tanenbaum
Poplar
User
User
Posts: 16
Joined: Sun Apr 30, 2017 12:27 pm

Re: C Runtime Library & variable parameters

Post by Poplar »

Code: Select all

Prototype sprintf(*a.p-Ascii, *b.p-Ascii, c.i, d.i, e.i)
OpenLibrary(0, "msvcrt.dll")
Global sprintf.sprintf = GetFunction(0, "sprintf")
CloseLibrary(0)

Global *Buffer = AllocateMemory(100)
Global *Format = Ascii("The sum of %i and %i is %i.")
sprintf(*Buffer, *Format, 5, 3, 5+3)
MessageBox_(#Null, PeekS(*Buffer, -1, #PB_Ascii), "The sum", 0)
[/color]
User avatar
chi
Addict
Addict
Posts: 1028
Joined: Sat May 05, 2007 5:31 pm
Location: Linz, Austria

Re: C Runtime Library & variable parameters

Post by chi »

Code: Select all

ImportC ""
  sprintf(*buffer.p-Ascii, format.p-Ascii, arg1.i, arg2.i, arg3.i)
EndImport

out${50}
sprintf(@out$, "The sum of %i and %i is %i.", 5, 3, 5+3)
Debug PeekS(@out$, -1, #PB_Ascii)
Et cetera is my worst enemy
Post Reply