You can write your topic however you want, but you need to answer these questions:
What do you want to achieve? Keep it simple and clear!
i want to make it so that when i enter the code the letters in the textbox automatically becomes upper case letters
What is the issue? Include screenshots / videos if possible!
nothing just need help with that
What solutions have you tried so far? Did you look for solutions on the Developer Hub?
i didnt find any solutions
After that, you should include more details if you have any. Try to make your topic as descriptive as possible, so that it’s easier for people to help you!
here is the local script inside the gui
local RedeemFrame = script.Parent.RedeemFrame
local CodeBox = RedeemFrame.CodeBox
local RedeemButton = RedeemFrame.RedeemButton
local ToggleButton = script.Parent.TwitterButton
local deb = false
ToggleButton.MouseButton1Click:Connect(function()
if not deb then
deb = true
script.Parent.RedeemFrame:TweenPosition(UDim2.new(0.499, 0,0.471, 0),"Out","Bounce",0.75,false)
elseif deb then
deb = false
script.Parent.RedeemFrame:TweenPosition(UDim2.new(0.499, 0,-0.471, 0),"Out","Bounce",0.75,false)
end
end)
RedeemButton.MouseButton1Click:Connect(function()
local Code = CodeBox.Text
local Redeemed = game.ReplicatedStorage.RedeemCode:InvokeServer(Code)
if Redeemed == true then
CodeBox.Text = ""
CodeBox.PlaceholderText = "Redeemed Code!"
wait(1)
CodeBox.PlaceholderText = "Twitter Code Here"
else
CodeBox.Text = ""
CodeBox.PlaceholderText = "Invalid Code or Already Redeemed!"
wait(1)
CodeBox.PlaceholderText = "Twitter Code Here"
end
end)
RedeemFrame.ExitButton.MouseButton1Click:Connect(function()
if deb then
deb = false
script.Parent.RedeemFrame:TweenPosition(UDim2.new(0.499, 0,-0.471, 0),"Out","Bounce",0.75,false)
end
end)
if you need the server script please ask me, thanks!
If you want to upper case the textbox text when the redeem button is pressed or any other condition is met you can just change the line that gets the text, aka
local Code = CodeBox.Text
To
local Code = string.upper(CodeBox.Text)
Or
local Code = CodeBox.Text:upper()
Unless you are referring to another thing you want to uppercase, but generally the thing you need to do is to use string.upper
hi it worked just now but now it says malformed string here is the updated script
local RedeemFrame = script.Parent.RedeemFrame
local CodeBox = RedeemFrame.CodeBox
local RedeemButton = RedeemFrame.RedeemButton
local ToggleButton = script.Parent.TwitterButton
local deb = false
ToggleButton.MouseButton1Click:Connect(function()
if not deb then
deb = true
script.Parent.RedeemFrame:TweenPosition(UDim2.new(0.499, 0,0.471, 0),"Out","Bounce",0.75,false)
elseif deb then
deb = false
script.Parent.RedeemFrame:TweenPosition(UDim2.new(0.499, 0,-0.471, 0),"Out","Bounce",0.75,false)
end
end)
RedeemButton.MouseButton1Click:Connect(function()
local Code = CodeBox.Text:upper()
local Redeemed = game.ReplicatedStorage.RedeemCode:InvokeServer(Code)
if Redeemed == true then
CodeBox.Text = "
CodeBox.PlaceholderText = "Redeemed Code!"
wait(1)
CodeBox.PlaceholderText = "Twitter Code Here"
else
CodeBox.Text = ""
CodeBox.PlaceholderText = "Invalid Code or Already Redeemed!"
wait(1)
CodeBox.PlaceholderText = "Twitter Code Here"
end
end)
RedeemFrame.ExitButton.MouseButton1Click:Connect(function()
if deb then
deb = false
script.Parent.RedeemFrame:TweenPosition(UDim2.new(0.499, 0,-0.471, 0),"Out","Bounce",0.75,false)
end
end)
ok now i fixed the typo but it doesnt uppercase also i forgot to mention that i want to make the text to uppercase when the player stops edditing it and i dont know how sorry for late reply